Course

Bash Scripting

Ended Jul 23, 2024
6 credits

Spots remaining: 2

Enrollment is closed
Add yourself to the wait list and you'll be auto enrolled when a spot opens

Add to Wait List

Full course description

Term: Summer 2024

Date: July 23rd, 2024

Time: 9:00am - 12:00pm & 2:00pm - 5:00pm 

Location: Online Only

Instructor: Chris Kuhlman

Presented By: Advanced Research Computing (ARC)

 

Description:

Bash is a Unix/Linux shell and its commands form a programming language just like other languages (e.g., Python, Java).  Almost all software-related projects can benefit from the use of bash scripting, and the larger the project (i.e., the larger the numbers and sizes of computations) the more value bash scripting provides.  

Bash commands can be (1) entered directly on the command line to accomplish tasks, or (2) written to files that are run just like files containing Python (or other interpreted) source code.  To put bash scripting into context, these programs are often much smaller than programs made with Python, C++, and other languages, and each script does more narrowly-scoped work.  

Bash can incorporate many other tools (we will learn them), so that small amounts of code can do big work.  Bash scripting is not suited to (large scale) number crunching.  Rather, Bash scripts often control the execution of larger codes such as ANSYS or ABAQUS, or programs that you write.  Some uses of Bash scripts include:  finding text in files, altering text in ASCII (text) files, generating new files by extracting information from existing files, automatically generating thousands or even millions of files (e.g., configuration files) that other softwares use, redirecting input into and output from your codes, altering directory structures and moving files, “chaining” together a group of individual commands in a micro-workflow (called piping), controlling large work flows, and manipulating (very large) output files.  Because of these capabilities, bash scripting is also useful for data scientists.  Bash scripting can be used on your laptop or tower, but we will focus on their use on VT’s compute clusters.

If you are an experienced linux/unix user, you can work the examples that are presented as we step through them.  Those users who have lesser familiarity with bash commands are also encouraged to attend, but we will not have time to cover prerequisite material, so your ability to execute the examples as we go may be limited.  But we strongly believe that being exposed to the examples will provide a lot of value.