Bash
Bash scripting, shell fundamentals, automation patterns, and common pitfalls.
Bash while Loop: Syntax and Examples
Bash while loop syntax and examples: infinite loops, reading files line by line, arithmetic conditions, and the break and continue statements.

pwd Command in Linux: Print the Current Working Directory
The pwd command prints the current working directory in Linux. This guide covers pwd syntax, the -L and -P options, $PWD and $(pwd) in scripts, and how symlinks affect the output.

Bash For Loop: Syntax and Examples
A complete guide to the Bash for loop: standard syntax, C-style loops, arrays, ranges, break and continue, and real-world scripting examples.

Bash source Command: Load Scripts and Variables
Use source (or its dot shorthand) to run a file in your current shell, reload .bashrc, share functions between scripts, and load variables from a config file.

What Is .bashrc? When It Runs and What to Put in It
~/.bashrc controls aliases, functions, prompts, and other interactive Bash settings. See when it runs, what belongs inside it, and how to reload changes.

How to Create Bash Aliases
Bash aliases let you shorten long commands into short, memorable shortcuts. This guide covers alias syntax, persistent aliases in .bashrc, and bash functions for shortcuts that take arguments.

How to Add a Directory to PATH in Linux
Add a directory to the PATH variable in Linux, temporarily or permanently, covering ~/.local/bin, custom binaries, and system-wide changes for all users.

.bashrc vs .bash_profile: What is the Difference?
Understand the difference between .bashrc and .bash_profile, when each file is loaded, and where to put aliases, PATH changes, and environment variables.

How to Create a File in Linux
Create a file in Linux from the command line with touch, redirection, cat, echo, printf, or a heredoc, and build large test files with fallocate, truncate, and dd.

Bash Append to File: >>, tee, and Heredoc Examples
Append text to a file in Bash without erasing existing content. Covers >>, echo, printf, tee -a for protected files, and combining files.

Bash Best Practices: Writing Safer, Cleaner Scripts
Practical Bash best practices for writing safer and more predictable scripts, covering strict mode, quoting, error handling, and everyday patterns.

How to Redirect stderr to stdout in Bash
Redirecting stderr and stdout in Bash using 2>&1, &>, and other operators. Covers file descriptors, appending, piping errors, and discarding output with /dev/null.

How to Run a Bash Script in Linux
Run a bash script in Linux with chmod +x, the bash interpreter, or source. Step-by-step examples with common errors and fixes.

sleep Command in Linux: Pause a Bash Script
How to use the sleep command in bash to pause script execution. Examples cover seconds, minutes, sleep infinity, retry loops, countdowns, and background sleeps.

Linux basename Command: Get File Name from Path in Bash
Get just the file name from a full path in Bash. This guide covers basename options, suffix stripping, and how it compares to parameter expansion.

echo Command in Linux: Print Text and Variables
Print text, variables, script arguments, and exit codes with echo in Linux, plus escape sequences, colored output, and the quoting pitfalls to avoid.

Bash Shebang: What #!/bin/bash Means in Shell Scripts
A Bash shebang tells Linux which interpreter runs a script. See what #!/bin/bash means, how /usr/bin/env bash differs, and what happens without #!.



