The Sysadmin's Text-Only Arsenal

No screenshots. No videos. No fluff. Just battle-tested CLI knowledge you can curl directly into your terminal.

Get Started

Shell Fu - Advanced Techniques

Signal Handling Deep Dive

Create robust scripts that clean up resources reliably, even when interrupted.


# Comprehensive signal management in a script
trap '{
  echo "Cleaning tempdir $TEMPDIR";
  rm -rf "$TEMPDIR";
  [[ -n "$SUBPROCESS" ]] && kill "$SUBPROCESS";
  exit 1;
}' EXIT INT TERM HUP
                        

Parameter Expansion Mastery

Perform advanced string manipulation directly in the shell without external tools like `sed` or `awk`.


filename="backup.tar.gz"
# Remove shortest suffix (*.gz)
echo ${filename%.*} # backup.tar

# Remove longest suffix (*.tar.gz)
echo ${filename%%.*} # backup
                        

Professional Toolchest

jq for JSON

Safely extract nested values from a JSON object, providing a default if the key doesn't exist.


# Extract nested values with null safety
jq '.user?.contacts?.email // "none"' data.json
                        

tmux Workflows

Manage persistent sessions for long-running tasks.


# Create a detached session named 'work'
tmux new -s work -d

# Send commands to the session
tmux send-keys -t work 'vim ~/project' Enter
                        

⚠️ Danger Zone: Caution Advised

These commands can cause irreversible data loss or system instability. Use with extreme care and preferably in a non-production environment.


# Filesystem Wipe (no confirmation!)
dd if=/dev/zero of=/dev/sda bs=4M

# Forcibly trigger a kernel panic
echo c > /proc/sysrq-trigger
                        

Contact & Legal

General Enquiries

For general questions about TerminalFu content and community.

enquiries@terminalfu.co.uk +44 (0)20 7123 4567

Technical Support

For enterprise customers and critical issue reporting.

support@terminalfu.co.uk

Emergency: Use base64 -d on contact page.

Company Information

TerminalFu UK Limited

Kemp House, 160 City Road, London, EC1V 2NX