Soptik's recent activity

  1. Comment on <deleted topic> in ~tech

    Soptik
    Link Parent
    Or just tell us! I have custom blog generator and didn’t have a feed because I wasn’t using it myself so I never thought of it. But some random person sent me an email that they’re missing a feed....

    Or just tell us! I have custom blog generator and didn’t have a feed because I wasn’t using it myself so I never thought of it. But some random person sent me an email that they’re missing a feed. Less than hour later, I replied to them saying that the feed is done.

    Especially if it’s someone who has small personal blog and only posts something once in a while, an email will likely make them add the feed. And it feels so good that someone actually reads my words and cares about it!

    2 votes
  2. Comment on Video Summarizer - browser extension that speeds up video depending on whether is there person talking or not in ~comp

    Soptik
    Link Parent
    Thanks, I need to look at it. But tbh, I probably won't do this anytime soon. I'm not javascript developer and hell this sounds complicated. But thanks a lot. It's true that it would solve a lot...

    Thanks, I need to look at it.

    But tbh, I probably won't do this anytime soon. I'm not javascript developer and hell this sounds complicated. But thanks a lot. It's true that it would solve a lot of my problems, notably having to run a server that downloads every video is... really not ideal.

    2 votes
  3. Comment on Video Summarizer - browser extension that speeds up video depending on whether is there person talking or not in ~comp

    Soptik
    Link
    I made a tool and browser extensions that determines if people in video are currently talking or not, and speeds up the video accordingly. Great for long lecture videos for skipping time spent...

    I made a tool and browser extensions that determines if people in video are currently talking or not, and speeds up the video accordingly. Great for long lecture videos for skipping time spent writing on a whiteboard.

    My use case are corona-time lectures. I don't want to just watch the teacher write something while saying nothing, so I speed up the video 1.5x when teacher is talking, and 4x otherwise.

    So this extension analyses sound in the video, and determines which parts are loud or silent. And depending on that, it changes playback rate of the video. Technically, this is javascript extension that downloads video information (when it's loud or silent) from server (which is btw written entirely in shell & gnu coreutils) and tells the videoplayer what to do. So only videos explicitely indexed by my server are managed by this extension. User has to click a button in the extension menu to index a video (as the data about videos are stored on my server and it has very small disk size, so I don't want to do this for every video).

    3 votes
  4. Comment on Anti-mask protesters' new weapon: Wearing masks that offer no COVID-19 protection in ~health

    Soptik
    Link
    Oh god. This has to be a joke, a prank, right? No way this can be real.

    Oh god.

    “Stylish, breathable and don't protect you from a darn thing! Masks required? No problem! Breath free while making a statement.”

    This has to be a joke, a prank, right? No way this can be real.

    8 votes
  5. Comment on Anti-mask protesters' new weapon: Wearing masks that offer no COVID-19 protection in ~health

    Soptik
    Link
    Mirror for Europeans because why should they give up user tracking just because of few european countries, right.

    Mirror for Europeans because why should they give up user tracking just because of few european countries, right.

    8 votes
  6. Comment on Fedora approves of making Nano the default terminal text editor in ~tech

    Soptik
    Link Parent
    I guess you should've added a link :)

    I guess you should've added a link :)

    1 vote
  7. Comment on What do you self host? in ~comp

    Soptik
    Link Parent
    May I ask which Bitwarden server do you use? And whether can you use premium-only features (like the TOTP generator) when you selfhost without paying for it?

    May I ask which Bitwarden server do you use? And whether can you use premium-only features (like the TOTP generator) when you selfhost without paying for it?

    4 votes
  8. Comment on What do you self host? in ~comp

    Soptik
    Link
    On my server: My personal website with some random projects, such as D&D name generator, or lorem ipsum in various languages. I have some articles there as well (but I'm not native english...

    On my server:

    • My personal website with some random projects, such as D&D name generator, or lorem ipsum in various languages. I have some articles there as well (but I'm not native english speaker, they are more like experiments) and hackme subdomain where I run some intentionally vulnerable web apps in docker.
    • Some more websites, such as one for an event I organize.
    • Minecraft server that tends to completely max out RAM btw, I never thought it would eat so much. I actually turn it off because of it's system requirements.
    • Teamspeak server for friends that don't like discord. I don't really use it tbh, but it's there.
    • Not a service, but funny DNS records. It actually works btw:
    dig TXT prenoc.cz
    ;; ANSWER SECTION:
    prenoc.cz.		1799	IN	TXT	"<script src=\"https://soptik.tech/xss.js\"></script>"
    
    • Funny bootable ISO that you just have to try out! (Warning: direct download link. If you want to lose the fun figuring out what it does, here's github link. You'll want to switch bios to legacy mode to properly boot btw).
    • Again, not really a service, but it's rather fun to do. You know, when you host a server, you start getting lot of traffic hitting at places like /admin.php even if you never installed php in the first place. So I setup a small funny python script that takes care of those things. Try running sqlmap or gobuster or something like that :-) Or just go here and watch your RAM usage. Some browsers tend to protect users against it, but it works well enough for me. I never see most of the bots afterwards :)
    • Syncthing! It's awesome! One of the best things I've ever done. I have cluster of my two laptops, server, and two raspberry pis and I couldn't be happier. Even if you have just two devices (android phones work too btw), go ahead and install it. It's the best synchronization service I've ever seen in my life. I can edit something on one device, and by the time I'm moving across the room to another, it's already synced to all devices in my cluster. I abandoned ssh because of it on my server. I used to write articles with ssh+vim, but now, I just synchronize /var/www/html to my laptop. So I edit a file, open web browser and it's there! Everything works so flawlessly. I use it for backup as well. It's theoretically just a synchronization program, but there is now way five different devices are going to fail at once. This is great post about Syncthing.
    • I host my mail in there. Well, partially. I just forward all the mail to my email provider, who takes care of things like proper imap configuration and sending replies. But I can use my own domain name (and I have catch-all setup) and it looks pretty cool and works surprisingly well. And I didn't pay a cent for it!

    Currently I'm thinking about hosting my own Matrix instance and Bitwarden server. But I don't know if it's wise putting so much of my communication channels and everything into one machine that might fail every moment. I'm scared of my setup as it is, and I have just my email there. I actually had my email server down for few days before I noticed because I changed the way firewall works and forgot to allow email ports. I should probably setup some monitoring of some kind.

    But yeah, I quite like the setup. I thought I won't use a personal server, but I couldn't be happier. Btw, if you're a student, you can get server and domainname for free from github for few months.

    10 votes
  9. Comment on Quickref is an experimental search engine for developers in ~tech

    Soptik
    Link
    Works really well with Rust! I'm surprised by how good it actually is.

    Works really well with Rust! I'm surprised by how good it actually is.

    2 votes
  10. Comment on Has DuckDuckGo recently started giving you significantly worse results? in ~tech

    Soptik
    Link Parent
    Hm, it looks like it works just fine now? I guess maybe there was some messed up a/b test. It had troubles even finding xkcds. The only thing it doesn't handle now is !i i made their lives return...

    Hm, it looks like it works just fine now? I guess maybe there was some messed up a/b test. It had troubles even finding xkcds.

    The only thing it doesn't handle now is !i i made their lives return null, which is not something I can blame them for, and it probably didn't find it even before. The search looks perfectly normal now. Thanks!

    1 vote
  11. Comment on Has DuckDuckGo recently started giving you significantly worse results? in ~tech

    Soptik
    Link
    Definitely, over the last two or three weeks, I’m simply not able to use ddg at all. I am a linux user, but the results are almost always regarding windows, no matter how many times do I repeat...

    Definitely, over the last two or three weeks, I’m simply not able to use ddg at all. I am a linux user, but the results are almost always regarding windows, no matter how many times do I repeat “linux” in the query.

    force mount as writeable used to yield actually useful results, mainly from stack overflow and friends, but lately all I get is results from microsoft documentation or various tech news sites with ad-ridden tutorial how to open flash drive on Windows 10, even if I mention linux in the query.

    And it keeps ignoring keywords in quotes as well.

    It used to be legitimately better than google, what has happened?

    6 votes
  12. Comment on Reddit introduces new "Start Chatting" feature across many subreddits, AskHistorians goes dark for 1 hour in protest to broken promises in ~tech

    Soptik
    Link Parent
    I just casually mention it and link something interesting from time to time when it's relevant to discussion. For example when I shared my program on reddit, I linked u/mironimous 's comment where...

    I just casually mention it and link something interesting from time to time when it's relevant to discussion. For example when I shared my program on reddit, I linked u/mironimous 's comment where he made something very relevant to my program. Someone asked about tildes and in few minutes I was sending invites.

    I don't really really promote it in a way where I would have prepared monologue about how great website this is. I wonder if there is someone doing some campaigns or something like that.

    4 votes
  13. Comment on <deleted topic> in ~tech

    Soptik
    Link Parent
    I don't use a virtual keyboard unfortunately, I trigger it with laptop keyboard, but it theoretically should work with it just fine. I just use it to rotate screen when I'm reading something long,...

    I don't use a virtual keyboard unfortunately, I trigger it with laptop keyboard, but it theoretically should work with it just fine. I just use it to rotate screen when I'm reading something long, so I can put my laptop on side and have essentially 90-degrees rotated monitor :) The experience when reading something that is tall but not wide is really much better, but I don't use it often enough to really make something like this properly.

    2 votes
  14. Comment on <deleted topic> in ~tech

    Soptik
    Link Parent
    Btw I have scripted a solution for screen (and touchpad!) rotation. It doesn't work automatically when I tilt laptop, but if you end up writing your own solution it might help. It took a while to...

    Btw I have scripted a solution for screen (and touchpad!) rotation. It doesn't work automatically when I tilt laptop, but if you end up writing your own solution it might help. It took a while to get touchpad rotation working.

    Script, example usage

    4 votes
  15. Comment on <deleted topic> in ~tech

    Soptik
    Link Parent
    Gnome is DE like anything else. It can be customized to look really good. It's the middle ground between nice and polished KDE and minimal DEs like XFCE. It is intuitive and works pretty well....

    Gnome is DE like anything else. It can be customized to look really good. It's the middle ground between nice and polished KDE and minimal DEs like XFCE. It is intuitive and works pretty well. Gnome these days isn't bad. It has all the features you would ever need and is reasonably useful out of the box.

    Note, I abandoned Ubuntu for Arch because I wanted stability - major updates always broke something. And I ditched Gnome for i3 even before because I wanted something more lightweight on my 8 year old machine. So I'm not gnome propagator. But it's not bad DE.

    6 votes
  16. Comment on Desed: a debugger for sed in ~comp

    Soptik
    Link Parent
    Yay thanks! Btw the first link is actually what prompted me to write this in the first place. I wanted to understand how does the monstrosity work. And the second one, eehhhhh. I'm kind of scared...

    Yay thanks!

    Btw the first link is actually what prompted me to write this in the first place. I wanted to understand how does the monstrosity work.
    And the second one, eehhhhh. I'm kind of scared of someone who comes up with a problem like this, let alone a solution. Outstanding work right there.

    2 votes
  17. Comment on What programming/technical projects have you been working on? in ~comp

    Soptik
    Link Parent
    Thanks! I've been using mainly awk as well, sed was just too much for me to handle. This was actually written to force myself to learn sed properly :-) Btw this tutorial actually helped me a lot....

    Thanks! I've been using mainly awk as well, sed was just too much for me to handle. This was actually written to force myself to learn sed properly :-)

    Btw this tutorial actually helped me a lot. I still don't quite understand all the newline mess, but I can now write my own divide-by-two.sed, so I'm happy :-)

    3 votes
  18. Comment on What programming/technical projects have you been working on? in ~comp

    Soptik
    Link
    I've made a debugger for sed! It's called desed (heh) and it's made in Rust. I was trying to get how this works for like fifth time and tried to mentally follow what sed does and what is in hold...

    I've made a debugger for sed! It's called desed (heh) and it's made in Rust.

    I was trying to get how this works for like fifth time and tried to mentally follow what sed does and what is in hold buffer and... I looked if there is a sed debugger out there. And it turned out there isn't (actually is, I can't search, but it's quite old). So I decided to brush up my Rust skills which have been getting quite rusty :) in the last few months.

    It turns out sed has a --debug flag which actually annotates what sed does in a nice way. But I wanted something a little bit more intuitive, so I hacked together TUI debugger in two days (and nights). It works by just parsing output of sed --debug, which is quite intuitive. Here's annotation of a simple sed program that decrements a positive number:

    decrement.sed
    SED PROGRAM:
      :decrement
      s/$/-;-90123456789/
      :decrement_inner_loop
      s/(.)-((-?.)*\\1)/\3\2/
      t decrement_inner_loop
      s/;.*//
    INPUT:   'number.txt' line 1
    PATTERN: 30
    COMMAND: :decrement
    COMMAND: s/$/-;-90123456789/
    MATCHED REGEX REGISTERS
      regex[0] = 2-2 ''
    PATTERN: 30-;-90123456789
    COMMAND: :decrement_inner_loop
    COMMAND: s/(.)-((-?.)*\\1)/\3\2/
    MATCHED REGEX REGISTERS
      regex[0] = 1-7 '0-;-90'
      regex[1] = 1-2 '0'
      regex[2] = 3-7 ';-90'
      regex[3] = 4-6 '-9'
    PATTERN: 3-9;-90123456789
    COMMAND: t decrement_inner_loop
    COMMAND: :decrement_inner_loop
    COMMAND: s/(.)-((-?.)*\\1)/\3\2/
    MATCHED REGEX REGISTERS
      regex[0] = 0-10 '3-9;-90123'
      regex[1] = 0-1 '3'
      regex[2] = 2-10 '9;-90123'
      regex[3] = 8-9 '2'
    PATTERN: 29;-90123456789
    COMMAND: t decrement_inner_loop
    COMMAND: :decrement_inner_loop
    COMMAND: s/(.)-((-?.)*\\1)/\3\2/
    PATTERN: 29;-90123456789
    COMMAND: t decrement_inner_loop
    COMMAND: s/;.*//
    MATCHED REGEX REGISTERS
      regex[0] = 2-15 ';-90123456789'
    PATTERN: 29
    END-OF-CYCLE:
    29
    

    So it turns out I can just parse it and load all states sed has ever been in into memory and then show them. This has a big advantage, besides that it's actually quite easy to do it, user can step the code both forwards and backwards. So you can setup breakpoint and then go back and see how did the code get to that breakpoint.

    The disadvantage is that sed doesn't tell me which line is it actually processing. So I had to implement a subset of sed in Rust (which wasn't without bugs, and I've only implemented like three commands), that I run in parallel while parsing the sed output, and pair each sed state with line number from source code.

    After I was done, I posted it to HN and Lobsters. I didn't expect anything, but I've actually gotten this to front page of Lobsters (which isn't any big achievement, if it isn't spam, everything makes it there) and, which I'm quite proud of, to the front page of HN! It was at the 10th place. So my git repo has over three hundred internet points. But most importantly, I've seen few people on twitter actually sharing it and they seemed to like it. It looks like I've actually made something that someone besides me will actually use sometimes. And that's the biggest achievement to me.

    11 votes
  19. Comment on Desed: a debugger for sed in ~comp

    Soptik
    (edited )
    Link
    I’ve written a debugger for sed in Rust. This was not only to learn rust, but to actually have a solid debugger for sed. I’ve started learning sed recently and decided to start writing various...

    I’ve written a debugger for sed in Rust. This was not only to learn rust, but to actually have a solid debugger for sed. I’ve started learning sed recently and decided to start writing various algorithms in it. And as sed doesn’t have numbers and can just filter/transform text, this is a challenge even for something like comparing two numbers. I’ve seen people (@mironimous actually) do amazing things with it.

    I’d be glad for any comments regarding code quality or the debugger itself.

    Edit: I've written a bit about how it was built.

    6 votes