
Explore the basics of Bash, the popular Linux shell scripting language, and learn to use it from Windows via the Windows Subsystem for Linux (WSL) for beginners.
Master basic commands in the terminal by using echo to display text and cat to print a file's contents, and learn Vim basics for creating and editing files in terminal.
Write your first bash script in vim, add a shebang with the full interpreter path, give execute permissions, and run the script with ./shell tests.
Learn how bash variables store long paths, enable reuse in scripts, and handle user input with read to print greetings using first and last names.
Discover how positional arguments supply the first and second inputs to a script, print them with an echo using $1 and $2, and run the script after setting permissions.
Learn to pipe command output to subsequent commands, filter with grep, and redirect output to files with > and >>; redirect input with <, <<, and <<< in bash.
Master Bash test operators by using square brackets to compare strings and numbers, inspect exit codes, and understand when commands succeed (exit code zero) or fail.
Learn how to use if, elif, and else in Bash with a login script that tests a username, handles case-insensitive comparisons, and echoes appropriate messages.
Explore how to use bash case statements to test multiple options, with a catch-all default, and bind actions to each case using esac.
Learn how to work with arrays in bash by creating lists, printing the entire array with echo, accessing items by index, and looping through array elements.
Use a for loop to iterate over an array, assigning each item to a variable and piping echo -n to wc -c to count characters.
Learn how to create reusable bash functions to simplify scripts, define functions, capture command output, use local variables to avoid global conflicts, and pass positional arguments to functions.
Learn to use exit codes in bash by building an if statement with positional arguments, returning zero for success and one for failure, then echoing outcomes.
Master awk to filter file contents and command output, printing essential fields using $1 and $2. Change field separators with -F and pipe text or csv data for flexible reformatting.
Explore using the set command to replace values in text files with regular expressions, perform global substitutions, and back up originals with the -i option, via a practical example.
In this course I will teach you how to get started with bash scripting. We will learn the fundamentals of bash scripting and create an entire bash script in the end as our end project. Join the course!
We will learn thing such as how to write a shell script, variables, functions, exit codes and more! Here is a complete overview of all the topics:
Introduction
Basic commands
Writing your first bash script
Variables
Positional arguments
Output/Input redirection
Test operators
If/Elif/Else
Case statements
Arrays
For loop
Functions
Exit codes
AWK
SED
If you are completely new to bash scripting, don't worry! The course is made so that anyone can jump in. We work with WSL, for which I have a video on my YouTube channel (link in my profile page), so the course can be easily stepped into if you are on a Windows computer! If you don't know anything about the Linux shell, on don't know your way around a terminal, there is another course on here as well that explains the basics of Linux.
If you are already well rounded in Bash, you can have a look at the final project and see if you can manage to create it yourself!
Don't forget to check out my YouTube channel for more Linux related content. Have fun and happy studying!