Code Self Study Forum

Bash / shell scripting tips thread

I’m cross-posting this from the chatroom in order to start a thread about bash tips.

The post covers:

  • `` vs $()
  • globbing vs regexps
  • Exit Codes
  • if statements, [ and [[
  • set commands
  • <()
  • quoting
  • Top three shortcuts
  • startup order
  • getopts (cheapci)

Here are some more resources:

I feel like this thread should be public. Any reason to keep it behind sign in?


Good idea. I just changed it to public. :slight_smile:


Related post with a list of common bash commands

1 Like