Welcome to the Bash Scripting Essentials Course! This course (8 modules) is designed to guide you through the core concepts and advanced techniques of Bash scripting.
Here we will take through the essentials, from basic commands and conditional statements to loops, functions, and file operations.
1. Introduction to Bash Scripting
- Meaning of Shebang in Bash Scripts
- How to Make Bash Script Executable Using Chmod
- How to Assign Variable in Bash
- Bash Backticks vs Dollar Parentheses $()
- Bash if Statement with Multiple Conditions
- How to Comment Code in Bash Script
- Special Variables in Bash Explained [With Examples]
- How to Do Bash Variable Substitution (Parameter Substitution)
- Bash Parameter Expansion with Cheat Sheet
2. Conditional Statements
- Bash If Else Statements: Examples and Syntax
- How to Use Bash if With && Operator
- Bash If Statements for String Comparison
- Bash if Options
- Bash if Statement with Multiple Conditions
- Determining if a Bash String is Empty
3. Loops and Iteration
- Using Bash For Loops to Iterate Over a List of Strings
- Bash for Loop with Array
- Bash for Each File in a Directory
- Using While Loop in Bash for Efficient Scripting
- Bash While Read Line by Line
- Bash Loop Through Lines in a File
- Counter Increment and Decrement in Bash Loops
- Bash for Loop Range Variable
- Bash Break - Using with For Loop
- Bash Continue - Using with for Loop
- Using seq With for Loop in Bash
- Case statement in Bash Shell Scripting
4. Functions and Parameters
- Bash Function Return Value
- How to Pass all Arguments in Bash Scripting
- Check Input Arguments in Bash Script
- How to Use $@ in Bash Scripting
- Bash getopts with Examples
5. Arrays and Strings
- Bash Arrays Explained
- Ways to Find Bash Array Length
- Bash Associative Arrays with Examples
- Bash readarray with Examples
- Bash Looping Through Array of Strings
- Bash Split String by Delimiter
- How to Concatenate String Variables in Bash [Join Strings]
- Bash Check Empty Array
- Trimming White Space in Bash
- How to Create Multiline Strings in Bash
6. File and Directory Operations
- How to Get Directory Path in Bash
- Get the Current Script Directory in Bash
- Bash basename Command with Examples
- How to Extract Filename from Absolute Path in Bash
- Extract Filename without Extension from Full Path in Bash
- Extract Extension from File Path in Bash
- How to Read CSV File in Bash
- How to Read JSON file in Shell Script
- Shell Script to Check if Directory Exists
- Shell Script to Check if File Exists
7. Advanced Bash Commands
- Bash eval Command with Examples
- Bash Exit Command Explained [With Examples]
- Bash Exec Command with Examples
- Bash Modulo (Division Remainder)
- Bash Division Explained
- Bash expr with Examples
- Bash let with Examples
- Bash mapfile Command Explained [With Examples]
- Bash shift Command
- Bash read Command with Examples
- Bash read password
- Using sleep Command in Bash Scripting
To gain hands-on experience, try running the provided script examples on a Linux system.