In the Bourne shell, very little string manipulation was possible without resorting to external commands. Strings could be concatenated by juxtaposition, they could be split by changing the value of IFS, and they could be searched with case, but anything else required an external command.
© The Author(s), under exclusive license to APress Media, LLC, part of Springer Nature 2023
J. VarmaPro Bash https://doi.org/10.1007/978-1-4842-9588-5_77. String Manipulation
Jayant Varma1
(1)
Berwick, VIC, Australia
Even things that could be done entirely in the shell were often relegated to external commands, and that practice has continued to this day. In some Linux distributions, you can find the following snippet in /etc/profile. It checks whether a directory ...
Get Pro Bash: Learn to Script and Program the GNU/Linux Shell now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.