The bash book to rule them all
A new book on Bash and the command line prompts broader reflection on how deeply one should learn shell scripting versus relying on tools like GPT, Stack Overflow, or higher-level languages. Commenters compare Bash with alternatives such as PowerShell, Nushell, zsh, and POSIX sh, weighing portability, readability, help systems, and ecosystem fit—especially for Linux vs. Windows workflows. Many recommend classic resources (man/info pages, Wooledge guides, ShellCheck, TLDP) and stress that understanding Unix fundamentals often matters more than mastering every corner of Bash’s complex syntax.
Bash vs. Other Shells (PowerShell, nushell, zsh, POSIX)
- Some argue anyone who “likes bash” should study PowerShell to see better help, discovery, and structured-data handling; others find PowerShell too verbose, inconsistent, Windows/.NET‑centric, and not useful on Linux fleets.
- Supporters highlight PowerShell’s standardized verb–noun commands, strong completion, integrated help, and close .NET integration, especially for complex scripting and object/JSON/XML manipulation.
- Critics emphasize bash’s ubiquity on Unix, availability of GNU tools, and small/memory-efficient core (compared to PowerShell’s VM). They see PowerShell and nushell as “interior‑first” object worlds vs. bash’s “exterior‑first” text-and-tools model.
- nushell is praised as more Unix‑friendly and less .NET‑bound, but not yet mainstream enough for team use.
- Some advocate targeting POSIX shell (dash/ksh88 subset) for portability, then layering bash/zsh features as needed; others are content with a “sane subset” of bash plus zsh as an interactive shell.
Learning Bash: Books, Manuals, and Guides
- The recommended book is well received as practical, but several say the definitive reference is still
man bash/info bash, despite being long, dry, and light on examples. - Some report using bash productively for years without reading the manual; others say skimming the whole manpage occasionally reveals powerful features and subtle behaviors.
- GNU’s online bash manual, Wooledge’s Bash Guide/FAQ/Pitfalls, and TLDP’s beginner/advanced bash guides are cited as strong learning resources.
- One view: the real goal is learning Unix (processes, files, C heritage), not just “learning bash.”
LLMs (GPT) and Bash Usage
- Several commenters say GPT has “revolutionized” their bash use: rapidly generating one‑liners or explaining complex commands faster than manuals or search.
- Others warn about hallucinated or subtly wrong commands, especially destructive ones (
rm,mv, SQLDROP). Consensus: treat GPT output like untrusted StackOverflow snippets—review and test. - Debate centers on craft vs. tooling: some fear over‑reliance will stunt skill growth; others argue the time saved enables learning more domains.
Bash Configuration Files
- Clear explanation offered:
- Login vs non‑login; interactive vs non‑interactive shells.
~/.bash_profile(or~/.profile) for login shells,~/.bashrcfor non‑login interactive shells; many systems just source~/.bashrcfrom~/.bash_profile.
- Some distro quirks (e.g., cross‑sourcing files) cause confusion.
Miscellaneous
- Discussion of O’Reilly‑style animal covers and parodies.
- Note that the article’s Amazon link is an affiliate link, which some feel should be kept in mind.