Bash Tutorials
A full Bash scripting course: variables, quoting, functions, strict mode, and scheduling peeks.
This course includes 15 lessons grouped from first steps to more capable workflows. Work through a group in order, or jump to the task you need today. Every lesson includes explanations, copyable examples, and tips written for beginners.
Cheatsheet · Search this course · Operating systems category · All categories
Getting started
Topic page- What Is Bash Scripting?See how Bash scripting differs from everyday interactive shell use.
- Shebang and Running ScriptsStart scripts with a shebang, mark them executable, and run them safely.
- VariablesAssign, expand, and default variables with safe habits.
- QuotingControl word-splitting and globbing with single quotes, double quotes, and escapes.
Control flow
Topic pageScripts that behave
Topic page- FunctionsGroup logic into functions with local variables and clear return status.
- Exit CodesUse exit statuses so scripts and callers know success from failure.
- Pipes and Redirects in ScriptsWire commands together and manage stdout/stderr inside scripts.
- set -euo pipefailTurn on safer Bash defaults that catch common scripting mistakes.