Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  • a command-line interpreter (a.k.a. Read-Eval-Print loop, or REPL)
  • a rich set of built-in commands for file system navigation & data manipulation
  • advanced utility programs (e.g. cut, join, paste, sort, grep, sed, awk, perl)
    • some of which are full-featured programming languages of their own (awk, perl)
  • many programming language features
    • variables, variable types, control structures, functions
  • a lot of weird but powerful syntax (piping, redirection)
  • a highly extensible execution environment
    • enables calling of both built-in and custom scripts & programs

...

  • a lot of weird (but powerful) syntax ( (smile) )
  • a meager set of built-in data types
  • functions and scripts can only return one small integer value
    • the proxy for this is capturing output, but this can be tricky
  • no support for object oriented programming

...

The combination of piping, a large set of built-in utilities, and the ease of creating and troubleshooting long "command line one-liners" provides tremendous productivity potential over, for example, having to write a Python program to achieve equivalent results.

...

Because bash is an execution environment, it is uniquely well suited for executing a series of processing steps, often calling other programs or utilities, and integrating the results. Such scripts are sometimes termed pipeline scripts and can automate processes that consist of many sub tasks – for example, next-gen sequencing alignment pipeline scripts that go from raw reads (Fastq FASTQ files) to alignment reports (sorted, index BAM files), gathering statistics along the way.

A good 2nd choice programming language for writing pipeline scripts would be Python, since it has a rich set of built-in features and can be easily extended. The downside of this choice is that it takes discipline to separate the scripting environment from Python program environments, which can lead to the creation of large, complex but fragile systems with many hidden dependencies.

...