This slide presentation was created by B6Plus. The audio accompanying this presentation is AI-generated.
Module Outline
Introduction
Write Simple Bash Scripts
Loops and Conditional Constructs in Scripts
Match Text in Command Output with Regular Expressions
Guided Exercise
Graded Lab
Summary
Resources
Graded Lab
.
Learning Objectives
After completing the work in this module you will be able to:
Use the features of the Bash shell to run commands more efficiently.
Use a for loop to run repeatative commands.
Evaluate exit codes.
Create conditional structures with if statements.
Create regular expressions to match data.
Use the grep command to apply regular expressions to text files.
Introduction
Improve Command-line Productivity
Write Simple Bash Scripts
Execute a Bash Shell Script
Guided Exercise
Write Simple Bash Scripts
️
Loops and Conditional Constructs in Scripts
Create and Execute Bash Shell Scripts
Specify the Command Interpreter
Execute a Bash Shell Script
Quote Special Characters
Provide Output from a Shell Script
Guided Exercise
Write Simple Bash Scripts
Use Loops to Iterate Commands
Bash Script Exit Codes
Test Logic for Strings and Directories, and to Compare Values
Conditional Structures
Loops and Conditional Constructs in Scripts
Use Loops to Iterate Commands
Process Items from the Command Line
Process Items from the Command Line
Conditional Structures
Use the If/Then Construct
Use the If/Then Construct
Use the If/Then/Elif/Then/Else Construct
Guided Exercise
Loops and Conditional Constructs in Scripts
Match Text in Command Output with Regular Expressions
Write Regular Expressions
Describe a Simple Regular Expression
Match the Start and End of a Line
Guided Exercise
Match Text in Command Output with Regular Expressions
Guided Exercise
Loops and Conditional Constructs in Scripts
Create regular expressions to match data, apply regular expressions to text files with the grep command, and use grep to search files and data from piped commands.
Match Text in Command Output with Regular Expressions
Write Regular Expressions
Describe a Simple Regular Expression
Match the Start and End of a Line
Basic and Extended Regular Expression
Wildcard and Multiplier Usage in Regular Expressions
Match Regular Expressions from the Command Line
Isolating Data with the grep Command
The grep Command Options
Examples of the grep Command
Guided Exercise
Match Text in Command Output with Regular Expressions
Create a Bash script that can filter and get relevant information from different hosts.
Thanks for Watching
Thank you for your attention and participation. If you have questions, please ask now or follow up via the course platform. See you in the next module!
Created on 17 February 2025 by Dennis Kibbe. Last modified on 2 September by DNK.
Keyboard Shortcuts
This slide presentation was created by B6Plus. The audio accompanying this presentation is AI-generated.