Professional Development for Teachers: BASH

What is BASH?

Here we see two bashers engaged in mortal combat in my old office at NCSSM.

Model T car

They are bashers because they know how to use BASH (both majored in Computer Science and have secured real jobs right out of college), not because of the terrifying battle you see here.

BASH is a shell, which is a means of communicating commands to the operating system, which acts on those commands. You can think of a shell as being a telephone; you type into this telephone using the keyboard, instead of speaking.

My Mac terminal looks like this. The color scheme is configurable; on some systems, the terimal will have a dark theme. All of this, of course, is configurable via your preferences.

Mac Terminal

The listener on the other end is your operating system. It hears commands from the shell and replies to them. The operating system can do a wide array of things for you. Here are a few examples.

Finally, you will have wizard-like nerd creds with your students when they see you using the command line avec panache.

Command-Line Skill

You might ask, "Why learn how to use the command line?" It seems oh-so-20th century!

Model T car

There are many excellent reasons. Here are a few.

  1. Cloud computing: This site runs on the cloud. I do not use any graphical interface to interact with it. It is essential that I know how to use a UNIX file system to create and manage files on the site. This is done through the command line interface. Many cloud services require you to work at the command line.
  2. My Way: The command line interface is highly configurable and you can tailor it to your needs and your routine chores.
  3. Programmability: Do you ever find yourself doing the same repetitive task over and over again? Wouldn't it be nice to automate it and eliminate a time-suck? The command-line interface is programmable and extensible.
  4. Programming: it is easy to run programs you write in Python, Java, or C at the command line. You can supply command-line arguments that determine program behavior.
  5. Data Mining: UNIX commands called filters have two streams: standard input and standard output. The action of filters can be chained, and can, as a result, can do very complex jobs by typing a single line of code. Input can be obtained from files and output can redirected to files. The BASH shell affords a highly efficient way of extracting and processing data from huge files. It also has search facilities that allow you to find needles in haystacks. Using the R programming language and these facilities, I personally helped to design a program trading system that traded 3 million shares a week back in the early '90s.
  6. VSCode: If you are teaching programming, I hope your students are using this, or if they are on a UNIX system, vim. When you run a program you created in VSCode, the terminal that appears in your session is a BASH shell.

Getting BASH

Here are instructions for installing the LINUX subsystem on Windoze 11. This video will take you through the entire install process and show you how to access your C drive through the BASH terminal. I recommend you use the latest Ubuntu distribution.

If you have a Mac, your terminal tool is in /Applications/Utilities. MacOSX is a UNIX-based operating system. This is the principal means I use for managing my files on my Mac.

If you are running a Linux distro, just search up Terminal and you will have a terminal window running BASH.

Learning Modules

Each of these modules has a link to a file with a more complete description. Each workshop should last about 3 hours.