1. 15

  2. 4

    Some notes:

    • #!/bin/sh would probably be even more reliable than #!/usr/bin/env sh
    • pipefail in set -euf pipefail is useless; it simply sets the first parameter ($1) to “pipefail”. pipefail is a Bashism that is set with -o pipefail.
    • You inconsistently switch between $HOME and ~
    • tail -1 is obsolete and no longer specified by POSIX; use tail -n 1 instead
    • You can use cat 1 2 3 instead of cat 1 2 | cat - 3
    • sed 's/$/<br>/' doesn’t remove newlines as far as I know; it just prepends <br> before every newline

    Subjective notes:

    • You can use printf '\nDone!\n' instead of echo; echo "Done!"
    • You can use a single command for the help output (and lines 23-25 in install.sh) instead of echoing each line individually; if you want to keep the indentation, you can use cat <<-EOF
    • You can also combine several cp invocations into one, but it looks fine the current way, I guess
    • You can use tail -c 1 file instead of tail -c 1 <file
    1. 2

      Hm, this reminds me of my git repository for ADOM save files that I use to track my character’s story. I’ve long used a Sublime Text file as a log but have been worried it could get lost under certain catastrophic conditions. It looks like thoughts may allow me to ship off the logs to an offsite location. I’m still trying to get into the habits of using the Apple Notes app and finding it difficult for some reason.

      1. 2

        I’ve actually been thinking about something that could be between Twitter (which can be intimidating in how public it is) and a blog post (which can also be intimidating in how much effort needs to go into it to be “high quality”). thoughts seems to fill this space well! Being integrated with Git is also nice; enabling GH Pages on my thoughts repo automatically adds it to my GH Pages site.

        1. 1

          Are PRs welcome? I have a little tweak to the random file generation that I think would make it better.

          1. 1

            This is so great! I always feel like putting my thoughts out but posting it on twitter or any social media always gives me some bad feeling about what if this hurts someone, what if someone judges me etc. Putting notes in ~/todo.txt l does not always suffice and I can’t check it with my phone. I am planning to modify this a bit to directly write things to my wiki. I really like the minimalist approach. Thanks for sharing this :)