Learn Linux Fast: Create Your First Bash Script (System Info Project Tutorial)

Опубликовано: 26 Май 2026
на канале: AI + Tech Learning with Joshua
858
13

Create your first Bash script using Nano on Ubuntu

You’ll use simple but powerful Linux commands like whoami, uptime, and df -h

Your goal:
Build a script that prints your username, the current date, your system uptime, and your disk usage.

Step 1: Create the script
nano sysreport.sh

Step 2: Add this code

#!/bin/bash
echo "=== System Report ==="
echo "User: $(whoami)"
echo "Date: $(date)"
echo "Uptime: $(uptime -p)"
echo "Disk usage:"
df -h | grep '^/dev/'

Step 3: Save and run
chmod +x sysreport.sh
./sysreport.sh

💬Inspiration:
Masako Wakamiya didn’t start coding until her 80s — and at 81, she became the world’s oldest app developer, recognised by Apple. If she can start at 81, you can absolutely write your first Bash script today.

🔥 Subscribe for more hands-on Linux challenges, command-line tips, and beginner-friendly projects.