Book Review: The Linux Command Line
By
A complete introduction to the shell for novices and masters alike.
Mastery of the shell is what separates boys from men, in the memorable words of The Olde Unix Greybeard. This machudo test of computing proficiency has indeed stood the test of time – a kind of cultural hazing ritual for those who are in the know, as opposed to the namby-pamby who require a graphic interface with options spelled out for every possible task. As one who was struck early by the beauty and versatility of the Unix Shell, I cannot but be pleased by the recent proliferation of books on the subject, popularizing what was often seen as a subject hard to approach and difficult to master. It does certainly pacify my inner drill sergeant!
The Linux Command Line, By William E. Shotts Jr. (No Starch Press, US$ 39.95), is the most recent entry in a veritable pantheon of books dedicated to the subject of using and scripting the *nix shell interface, and to its credit, it is probably the most approachable tome on the subject that is still willing to cover all of its breadth and depth. My chosen terms of comparison for this new work are Arnold Robbins and Nelson H.F. Beebe’s Classic Shell Scripting (O’Reilly) – hands down the best resource on scripting the shell currently in print – and No Starch’s own How Linux Works, by Brian Ward. While spanning similar, overlapping material, these books approach the topic with a different spirit: Robbins and Beebe’s book is an unsurpassed masterpiece that focuses squarely on scripting, exhausting every detail, whereas Ward’s book, albeit closer and more similar to Shotts’ book, focuses on the system’s operation, not on the user’s terminal-mediated interaction with it. And therein lies a significant difference for readers new to the terminal as the only window into a computer’s functionality – the same difference that passes between understanding how a transmission works and being able to drive stick shift.
Unabashedly Bash centric, The Linux Command Line delivers a complete introduction to the shell that presupposes no knowledge whatsoever, providing an easily approachable learning path for those new to the subject but drilling deep enough to leave the reader quite proficient at the other end of the reading traverse. Unlike most other books on the shell, which tend to focus on the task of scripting the interface and not its interactive use, Shotts’ book is first and foremost about using a Linux system through its simplest, most effective interface, and only the latter quarter of the book is dedicated to scripting. Shotts will indeed go quite far in making sure the reader has all the details necessary to make use of the command line, often expanding on the structure and operation of the system to deliver a complete view of just what arguments that are passed to a shell command actually represent –an omnipresent sub-question many authors tend to forget to answer fully when covering the commands themselves.
Any new code hacker in the making will certainly want to take advantage of this well thought-out path to understanding the interface most computers were really meant to be used with, but even those who already dabble in the terminal stand to gain by reviewing the carefully assembled coverage the middle chapters deliver on subjects like input/output redirection, pipelines, variable expansion, and quoting – good sources of recurring “gotcha” moments for most users. The book does not limit itself to the mechanics of performing simple filesystem-based tasks, it dedicates space to examining how to perform, from the shell, more practical tasks like printing, text processing (it’s Vi for those of you worshipping in the church of Emacs, not that it matters in this case), compiling programs, and scheduling backups. The section on keyboard tricks is highly recommended to new and intermediate users alike: I was reminded of a few shortcuts I had forgotten.
The book closes with a complete introduction to shell scripting. Although, as mentioned, this is not the core of the book, it still spans more than 100 pages and is more than adequate for users receiving their induction into the world of the shell. Important advanced topics, like redirection and sub-shells, get their moment in the spotlight, and those destined to Shell Scripting mastery will receive all the tools necessary to make good use of the Linux Documentation Project’s Advanced Bash Scripting Guide or O’Reilly’s aforementioned tome as their next stop on the path to terminal enlightenment.
The Author
Federico Lucifredi is the maintainer of man(1) and a Product Manager for Canonical’s Ubuntu Advantage and Landscape products.
Subscribe to our Linux Newsletters
Find Linux and Open Source Jobs
Subscribe to our ADMIN Newsletters
Support Our Work
Linux Magazine content is made possible with support from readers like you. Please consider contributing when you’ve found an article to be beneficial.
![Learn More](https://www.linux-magazine.com/var/linux_magazin/storage/images/media/linux-magazine-eng-us/images/misc/learn-more/834592-1-eng-US/Learn-More_medium.png)
News
-
NVIDIA Released Driver for Upcoming NVIDIA 560 GPU for Linux
Not only has NVIDIA released the driver for its upcoming CPU series, it's the first release that defaults to using open-source GPU kernel modules.
-
OpenMandriva Lx 24.07 Released
If you’re into rolling release Linux distributions, OpenMandriva ROME has a new snapshot with a new kernel.
-
Kernel 6.10 Available for General Usage
Linus Torvalds has released the 6.10 kernel and it includes significant performance increases for Intel Core hybrid systems and more.
-
TUXEDO Computers Releases InfinityBook Pro 14 Gen9 Laptop
Sporting either AMD or Intel CPUs, the TUXEDO InfinityBook Pro 14 is an extremely compact, lightweight, sturdy powerhouse.
-
Google Extends Support for Linux Kernels Used for Android
Because the LTS Linux kernel releases are so important to Android, Google has decided to extend the support period beyond that offered by the kernel development team.
-
Linux Mint 22 Stable Delayed
If you're anxious about getting your hands on the stable release of Linux Mint 22, it looks as if you're going to have to wait a bit longer.
-
Nitrux 3.5.1 Available for Install
The latest version of the immutable, systemd-free distribution includes an updated kernel and NVIDIA driver.
-
Debian 12.6 Released with Plenty of Bug Fixes and Updates
The sixth update to Debian "Bookworm" is all about security mitigations and making adjustments for some "serious problems."
-
Canonical Offers 12-Year LTS for Open Source Docker Images
Canonical is expanding its LTS offering to reach beyond the DEB packages with a new distro-less Docker image.
-
Plasma Desktop 6.1 Released with Several Enhancements
If you're a fan of Plasma Desktop, you should be excited about this new point release.