Project used to facilitate learning bash. Level-up your bashing weapons skills!
Source: Gfycat
docker
: Dockerfiles for the test playground.scripts
: Demonstration scripts for the commands presented. Scripts are snippets, not entirely runnable scripts!docker-compose.yml
: Configuration for the playground.
This project uses Docker containers to create a test environment to play around in.
- Ensure you have Docker and Docker Compose installed on your system.
- Run
docker-compose build
from the top of the project to build the playground. - Run
docker-compose up -d && docker-compose run ubuntu bash
to enter the playground. - To stop the running instances, run
docker-compose down
What is Bash
- Bourne Shell (sh)
- POSIX IEEE standard
- Bourne Again SHell (bash)
Why Bash
- Helpful in day-to-day tasks
- Important for understanding your OS
- Application development for containers (LXD, Docker)
- Server administration
Getting Started
- Mac / Linux: Good to Go!
- Windows: Git Bash or WSL (Windows Subsystem Linux)
- Docker: docker pull bash
- cat
- cd
- echo (bonus: scripts/progress-bar.sh)
- exit
- export / unset
- find / locate
- help
- history
- less / more / tail
- ls
- man
- mkdir
- mv
- ping
- pwd
- read
- rm
- rmdir
- touch
- type
- whereis
- which
- Variables
- Parameters
- Arithmetic
- Logical
- IO
- while, for, if/else
- Functions
- alias
- .bashrc / .profile
- Create aliases for common commands, set up environment variable values
- Use .bashrc for commands, aliases, and environment vars specific to bash
- Use .profile for non-bash environment vars, is POSIX compatible, and executed upon login
- diff
- grep
- rsync
- sed
- scp
- ssh
- xargs
What commands or bash knowledge do you find helpful?
A few from Session 1
- Matt Johnson (src-system42)
MIT (c) 2019 Cedrus, LLC