Recent submissions

Comment · 1 year ago
Actually thinking about it - why not have everything encased in sand all the time, you'd just have to be a kid playing in a sandbox when doing maintenance
Comment · 1 year ago
If you don't have a bottom layer the sand will immediately fall
Comment · 2 years ago
You could do that, and it'd still be POSIX-shell comptible:

    loadenv() {
        case "$-" in
            *a*) source ./.env ;;
            *) set -a; source ./.env; set +a ;;
        esac
    }
Although I have yet to see a long shellscript utilise `set -a` globally :)
Comment · 2 years ago
That will break if there's comments in the file, or if any one of the variables' values contain spaces. You can use `set -a` to load .env into an existing shell instance instead:

    loadenv() {
        set -a
        source ./.env
        set +a
    }
Comment · 2 years ago
You'd need to `set -a` or pass the `-a` as a flag to have them auto-exported though, so:

    sh -ac '. ./.env; ./prog'
Also if you use the `.` builtin it's a good idea to specify the path with a slash in it, so that `.` doesn't search $PATH first.
Comment · 3 years ago
This video is about motorcycles, not cars. Also, the data on this is in the linked video - the author demonstrates you can do a controlled stoppie to decelerate faster without ABS, because that's its main feature - preventing you from flying off the bike.
Comment · 3 years ago
It's an option you can use when invoking `make` - so no need to specify extra cmake options, just during `make` invocation after `cmake` is already done
Comment · 3 years ago
That's crazy. Where do you live? In Poland I just skipped the insurance system to get ADHD meds and went to a psychiatrist specialising in ADHD privately - $70 for a 20 minute visit seems a bit steep but it's better than waiting years.

Could you possibly do something similar?

Comment · 4 years ago
>"ip addr show" lists interfaces and their stats. It's harder to read than ifconfig -a but gives you the same information in a similar format.

It's worth noting that `-br` gives you a brief version of the output, and `-c` colors it, so that it's possible to do something like this:

  ip -br -c addr
to get a very readable and colorful table-like output.

There's also `-j` for JSON, and `-j -p` for pretty JSON.

Live from the official Hacker News API

A modern reader for Hacker News · SvelteKit + Skeleton