💻 Shell Scripting Notes

Handy syntax, structures, and real-life script examples

🔹 Basic Syntax

🔄 Conditionals & Loops

🧠 Variables & Parameters

📁 File & Directory Handling

🔧 Practical Example

#!/bin/bash
echo "Enter a filename:"
read fname

if [ -f "$fname" ]; then
    echo "Contents of $fname:"
    cat "$fname"
else
    echo "$fname does not exist!"
fi