Quick Tip
Master `ls` with Aliases for Custom Views
Challenge: You frequently need to view files with specific options, like always showing hidden files, human-readable sizes, and sorting by modification time. Typing these options every time with `ls` is repetitive and error-prone.
The Solution: Create a custom `ls` alias in your shell’s configuration file (e.g., ~/.bashrc or ~/.zshrc).
alias ll='ls -alFh --color=auto'
Why it works: This creates a new command `ll` that, when executed, runs `ls` with the specified arguments: -a (all files, including dotfiles), -l (long listing format), -F (append indicator to entries), -h (human-readable sizes), and --color=auto for colored output. After adding this to your shell configuration, run `source ~/.bashrc` (or your relevant file) to apply it.
Pro-Tip: You can create multiple aliases for different common `ls` use cases, such as `la` for just listing hidden files, or `lt` for a tree-like view if you have `tree` installed.
Linux Tips & Tricks | © ngelinux.com | 4/26/2026
