[–] 6 points 1 week ago* (last edited 1 week ago) (1 child)

At some point, I programmed a little 2D gravity simulation. So, I even had one less dimension in which objects could fly past one another, and I was still surprised how rarely they actually collide, despite literally being attracted to each other.

But the thing is, they generally get pulled by more than one gravity well or have previous momentum, so they rarely approach each other head-on. And if you've got a near-miss, that means all the speed they built up approaching each other is now slingshotting them far away from each other.

  • source
  • [–] 5 points 1 month ago* (last edited 1 month ago)
    • a lot of default usernames take the form adjective-noun, but I don't know where they get their wordlist

    I collected such a word list a while ago, by using my brain to think of words, well, and occasionally removing ones I don't like: https://codeberg.org/trem/fantastic_snail/

    The nouns are animal names. They are not the blandest word combinations possible, because I found those difficult to memorize. Instead I went for evoking funny images, sort of anthropomorphizing the animals.

    I cannot guarantee that there's not some word combination that could be interpreted offensively, because humans are very creative in offensive language, especially with racism, but I've been regularly generating word combinations for a few years now and remove offensive combinations when I come across them.

    It's a Rust library, but the specific word lists are here:

    I could also place these lists into the repo as just newline-separated words, if that helps you. Probably makes sense to offer in general...

  • source
  • [–] 5 points 1 month ago

    I set up my PC, so I have a single shortcut that opens up my editor with a notes file that I can just type into.

    I always marvel when I see folks using OneNote or whatever, which takes like 10 seconds to boot, then you have to select a category/folder to create the note in, and I believe, you even have to give the note a name, all before you can start typing your thoughts. Just how does that work for you?

  • source
  • [–] 6 points 1 month ago

    I really wouldn't be so sure that you're not lactose-intolerant.
    Something to be aware of is that it's not a disease, it's actually the default for an adult mammal to lose the ability to digest lactose, because evolution doesn't expect us to continue drinking boob juice forever.

    It's mostly just Northern Europe that doesn't typically have it + of course, the regions that got colonized from there: https://en.wikipedia.org/wiki/Lactose_intolerance#Epidemiology

    If you can find some pre-mixed chocolate oat milk somewhere, I can recommend trying that. For, uh, science reasons, I happen to know that I can consume a liter of it at once.

    At that point, some parts of my body do want me to calm down, just because it's a huge amount of liquid to consume in one go.
    So, maybe you're hitting the same after just two glasses, but your description also seriously just sounds like a light lactose-intolerance to me.

  • source
  • parent
  • context
  • [–] 2 points 1 month ago

    About two years or so ago, I automated the build of a sheet music project (don't ask 😅). It was working fine.

    Then a few weeks ago at $DAYJOB, we considered using Makefiles to automate something and I decided, I'd just play around how you might automate that same sheet music build with Makefiles.

    Then I realized they're a much better match for that build and decided to rewrite the whole build in them.

    Then I realized that, actually, it should be possible to define general rules to build any similar sheet music project. So, now I'm trying to build a flexible, user-friendly build system based on a Makefile.

    The original build was working fine.

    Send help... 🫠

    (Actually don't; it's great fun. 🙃)

  • source
  • [–] 1 point 1 month ago

    Regarding the interview layout, I do always like it when web design elements are used in articles themselves. We often treat articles just as rich text, even though we have this arsenal of HTML+JS+CSS underneath.

    Interactive visualizations can be really valuable for explaining concepts, see e.g.:

    But I've also been really wanting something like <map/>, just less of a pain in the butt.
    For example, at some point, I put together this overview of how logging works in your typical application:

    It's a fairly self-explanatory picture (assuming some programming experience), but if you're not sure what a 'producer' is, then I'd like you to be able to click on the box to get an explanation.
    Instead, I have a bunch of prose underneath the picture, as if I was presenting it at a science fair. 🫠

  • source
  • [–] 5 points 2 months ago (3 children)

    In programming, we use a tool called "Git" to keep track of changes we make to a piece of software, well, and also to collaborate with other devs.

    I've been using Git to have a history of how my text-based creative projects evolve (not just writing 😅). And then I'm publishing those like an open-source code repository. So, others can go through the history and look at the first draft, or the final edits, or everything in between.

    Obviously, though, this does mean that your final result is public as well, unless you find a way to only give access to paying customers, I guess.

    To give an example, here's a short tech explainer thingy I wrote: https://trem.codeberg.page/rust/macro_rules.html
    And here's the complete change history: https://codeberg.org/trem/pages_src/commits/commit/830718aaa788ac00fb7ba9635c405f7c18cc76fb/src/rust/macro_rules.md

  • source
  • [–] [S] 4 points 2 months ago*

    You can still move your folder from .config/librewolf/ to .librewolf/ and it will use it from there. At least, it works like that in Firefox (potentially to be removed in the future, but there's no real reason to remove it any time soon).

    But yeah, I don't know how that works together with KeePassXC. I mean, if it worked on LibreWolf before, then presumably moving the folder back to .librewolf/ should fix it until KeePassXC is updated...

    (And yes, the .config/ directory is specified by the XDG standard.)

    (Also, good shout about the directory being relevant. I guess, that's also why the extension is currently broken for me, because I was a bit too eager to switch to the .config/ dir. 🙃)

  • source
  • parent
  • context
  •  

    Somewhat of a PSA for Qt users:

    On Linux, Firefox will now default to the XDG portal file picker if available, rather than the GTK3 one, which is usually better integrated with the user's desktop environment, and more powerful. https://www.firefox.com/en-US/firefox/149.0/releasenotes/

    Edit: I talk about a patched version below, but it was an about:config toggle in more recent times.

    Always needed a patched version of Firefox before for that. Presumably most distros will transparently throw that patch out of their Firefox package, so likely don't have to do anything.

    But well, you don't specifically need a patched version anymore for that, so if that's a separate package on your distro, you could consider using the normal package again. Although, I believe there's also still patches floating about for using the KDE mimetype system...

     

    Hello, I built a CLI that gives you web links for stuff in your repo you might want to link to.

    You know the situation. Your coworker checked in some real garbage and you want to politely ask what they were thinking. But now you gotta describe where the code snippet is and they have to open it in their text editor and so on. Alternatively, you could open up your Git forge's webpage and navigate to the file, copy a permalink and send it to them. Also takes quite a bit of time.

    With the CLI, you can instead just paste the local file path and it gives you the permalink right away.
    Similarly, you can also get a direct link to an issue or PR, which's number you might've found in a commit message.

    There's a release available for download for Linux x86_64: https://codeberg.org/trem/forge/releases
    And if you've got the Rust toolchain on your system, then you can also install it like so: cargo install --git https://codeberg.org/trem/forge

    P.S.: The implementation is somewhat hacky, because a Git repository doesn't really know what webpage it was cloned from. So, please do let me know, if you run into any issues.

     

    Hello, I built a CLI that gives you web links for stuff in your repo you might want to link to.

    You know the situation. Your coworker checked in some real garbage and you want to politely ask what they were thinking. But now you gotta describe where the code snippet is and they have to open it in their text editor and so on. Alternatively, you could open up your Git forge's webpage and navigate to the file, copy a permalink and send it to them. Also takes quite a bit of time.

    With the CLI, you can instead just paste the local file path and it gives you the permalink right away.
    Similarly, you can also get a direct link to an issue or PR, which's number you might've found in a commit message.

    There's a release available for download for Linux x86_64: https://codeberg.org/trem/forge/releases
    And if you've got the Rust toolchain on your system, then you can also install it like so: cargo install --git https://codeberg.org/trem/forge

    P.S.: The implementation is somewhat hacky, because a Git repository doesn't really know what webpage it was cloned from. So, please do let me know, if you run into any issues.

    view more: next ›