• 0 Posts
  • 165 Comments
Joined 5 years ago
cake
Cake day: May 31st, 2020

help-circle
  • Ephera@lemmy.mltomemes@lemmy.worldai dev vs chad dev
    link
    fedilink
    English
    arrow-up
    8
    ·
    edit-2
    1 day ago

    Kind of felt like that last week. Our web-UI would automatically reload when you switched tabs, clearing out what the user had entered into a form. I started debugging, but the build times of our web-UI have been abysmal, making it extremely tedious to sprinkle log statements over the code for narrowing down what triggers the reload.

    So, I decided to fix the build times first. The solution wasn’t complex, basically just pull out a module into a separate library to benefit from incremental compilation, but with all the import changes and some additional restructuring, it still ended up being around 2000 lines of code changed.

    Then I went back to debugging the reload problem, looked at it for 10 minutes, maybe rebuilt 3 times or so, and then made a lucky guess where I just changed one word for another and that fixed it. 🫠





  • Ephera@lemmy.mltomemes@lemmy.worldsorry for the commercial
    link
    fedilink
    English
    arrow-up
    3
    ·
    edit-2
    6 days ago

    The thing is, producing another copy doesn’t cost you money. So, if you price it at $20 and 4 people buy it, when only one person would have bought it at $80, then you’ve made the same money.

    They only decide to put the price as high as they do, because they hope to extract as much money as possible from the fools that buy on release. Then they later put it on sale in hopes of also collecting the money from those not willing to pay $80.
    On some level, I assume they know how to make as much money as possible, but the same time, I do feel like the hype around Silksong would be a fraction of its size, if the game cost $80.


  • Ephera@lemmy.mltolinuxmemes@lemmy.worldFish rules
    link
    fedilink
    English
    arrow-up
    4
    ·
    9 days ago

    Fish is not the worst in this regard, because:

    • The defaults are pretty good, so you don’t typically need a config file for it to be usable.
    • As of version 4.0, Fish is (experimentally) available as a single executable for download from their GitHub page. So, even on hosts where you can’t install anything, you may still be able to copy that executable file onto there and use it.

    But there may still be situations where it’s annoying, like if you’re working in a container, then you likely don’t want to mount your fish executable every time.

    But I also have to say I don’t find it too big of a deal.
    I still use Bash for scripting (just throw a #!/bin/sh or #!/bin/bash at the top of your script, like you should anyways), and then for interactive use, not that much of the shell syntax comes into play anyways.
    And if I ever do need to copy a complex Bash command into an interactive shell, I can just run bash, then run the command in there and then exit back out.


  • Eh, as much as there’s obviously folks who use certain distros for the fun of it, the vast majority of distros get created to cover a specific use-case. If you have that use-case, then deploying the respective distro brings you so much closer to your target setup than the easy installation of a noob distro could save you time.

    I also have to say, many stereotypical noob distros make extremely conservative choices, which makes them harder or scarier to use in various ways, like for example not having filesystem rollback. I cannot imagine going back to that, specifically because I have shit to do.


  • Probably the very same thing that the post talks about, which is extracting the first word of a line of text.

    The output of md5sum looks like this:

    > md5sum test.txt
    a3cca2b2aa1e3b5b3b5aad99a8529074 test.txt
    

    So, it lists the checksum and then the file name, but you wanted just the checksum.


  • It’s a Linux command-line program (awk). It’s pre-installed practically everywhere, it’s very powerful for string processing, but it also uses a fairly complex syntax.

    As a result, not many people know how to really make use of it, but awk '{print $1}' is something you encounter fairly quickly when you need to get the first word in each line.


  • Ephera@lemmy.mltomemes@lemmy.worldthis is fine
    link
    fedilink
    English
    arrow-up
    1
    arrow-down
    14
    ·
    13 days ago

    Yeah, good luck with that definition. “Kid” is often used as the umbrella term for someone’s offspring, which includes babies and teenagers. Some slangs even use it to refer to just a guy, even if that guy is very much adult.
    You’ll inevitably talk to plenty people that don’t have your specific textbook definition in mind for when a baby turns into a toddler preschooler kid.


  • Ephera@lemmy.mltomemes@lemmy.worldIt used to be fun
    link
    fedilink
    English
    arrow-up
    16
    ·
    edit-2
    20 days ago

    They had to throw out lots of customization options, because Google made a ton of changes to Android/AOSP and it wasn’t compatible anymore.

    Like, LineageOS is still a more feature-rich and cleaner OS than what comes preinstalled on most phones. But yeah, even relatively simple stuff like setting a system font never got a real replacement.

    No idea, if it is still easily possible to implement that. You can fake it by replacing the Roboto font file with a different font, but you get weird font issues in various apps then.





  • Honestly, I have no idea, if the cashiers are allowed to take extra change here, at least in the supermarkets.

    I still want to try that at the town market, where I’ve always been too stupid to think of that so far, so I once got told that I could’ve kept that 1ct coin and one time, the guy actually gave me extra change, because he did not want to deal with those small coins. 🥴


  • No, no, you’re mathing correct. I did receive 12ct back. But 12cts is a 2ct coin + a 10ct coin. If I would have given 51.00€, it would have been a 2ct coin + a 5ct coin back. I didn’t mention the 2ct coin, because it’s always involved.

    And I didn’t have 3cts myself, otherwise I would have made it 51.03€, yeah.


  • To be honest, I’m always a bit amazed that this doesn’t happen more often. Yesterday, I had to pay 50.93€ and handed the cashier 51.05€, because I’d rather have a 10ct coin and the cashier typically needs smaller coins more often.

    In this case, it was obvious that I didn’t hand them the 5ct by accident, but that’s the sort of mind games I’ll play and so far, the cashiers were always a step ahead of me…



  • Ephera@lemmy.mltolinuxmemes@lemmy.worldsiempre lo hago
    link
    fedilink
    English
    arrow-up
    5
    ·
    23 days ago

    With script files, you can (and should regardless of Fish usage) put a shebang at the top, like #!/bin/sh or #!/bin/bash. Then it will run with Bash as you’d expect.

    I also recommend not setting Fish as your system-wide default shell (since then a missing shebang will cause it to run in Fish), but rather just have your terminal emulator start fish by default.

    And yeah, outside of scripting, if I notice a command requires Bash syntax (which you can often tell from Fish’s syntax highlighting turning red), then I just run bash, execute the Bash command in there and then exit back out of there.

    Having said all that, I’m not trying to take away from your point. If I wasn’t just joking around, I would caveat a Fish recommendation just as much.


  • Ephera@lemmy.mltomemes@lemmy.world#stopclimatechange2030
    link
    fedilink
    English
    arrow-up
    13
    ·
    23 days ago

    My favorite is that there’s still institutions talking about the +1.5°C goal. We’re already seeing average temperatures beyond that and we haven’t even started slowing down how much it heats up. For that, we’d need to bring CO2 emissions close to 0, not increase them year after year.