New project: bash boilerplate generator on

I like to automate. I like it so much that I will not hesitate to spend 8+ hours on writing a script that replaces 5 minutes of work every month. Most of my automation is for CLI (command line interfaces). On Windows, that means CMD, but for most other platforms (Linux, MacOS, Busybox) the best tool for it is bash or shell. I’ve created my own self-contained bash boilerplate script (a good scripting starting point, with a lot of regularly recurring functionality already built in.)

But I still needed to git clone the repository, or copy/paste from the github page, and customise it every time (using different options, parameters). So I went 1 step further: here is now the fully interactive, always up-to-date BASH BOILERPLATE GENERATOR

With just one click, you can get the boilerplate code for CLI scripts like:

  • [action] [outputfile] [inputfile(s)]
  • [inputfile]
  • --from [from] [destination] [subject] [body]
  • --test --method [method} [zipfile] [file(s)]

The boilerplate code takes care of

  • option parsing: use flags (e.g. -v for verbose), options (e.g. --steps 20) with short and long name (e.g. -v = --verbose)
  • different output commands for verbose/normal/error messages
  • confirmation yes/no …

The only things you still need to add is the actual code that does all that stuff that you wanted to automate.

2 thoughts on “New project: bash boilerplate generator on”

Leave a Reply

Your email address will not be published. Required fields are marked *

This site uses Akismet to reduce spam. Learn how your comment data is processed.