Text-processing
The Unix View of Text: Files Are Streams, Not Pages
Many people learn the Unix slogan “everything is a file.” That’s true, but I almost think the more profound slogan is: “Everything is a stream waiting to be read or written.” This last of our three-part series on working with streams demonstrates why it is appropriate to adopt the stream mentality rather than the page mentality when working with files.
read moreText-processing
Thinking in Transformations: Why Textsmiths Love Search-and-Replace
One of the greatest changes that happens when someone becomes a textsmith is not learning a new command. It is learning a new way of thinking. This second of the three-part series on working with streams delves into the psychology of a textsmith.
read moreText-processing
Before You Reach for sed: Master Bash Parameter Expansion
One of the habits that gradually changes a person’s shell scripting style is discovering that Bash can manipulate text on its own.
read moreThe Textsmith's Workshop
Programming as Composition
Most programming books begin with variables, loops, and functions. A textsmith, however, encounters programming from the opposite direction: composition. Before writing a single if statement, they are already composing grep, sort, awk, sed, pandoc, and dozens of other tools into something larger. By the time they sit down to learn a programming language, they have already been programming—they simply didn’t call it that.
read more