Functions, arrays, and strings are stored in variables. Bash uses what we call attributes to flag changes in behaviors on assignment. Despite there being a system to modify the behavior of variable assignment, when it all comes down to it, values are stored in variables as strings. In bash, a program lives to put strings into variables and name them for later use. These strings are available to manipulate throughout the lifetime of the program. The program lives to manipulate strings. Here we will cover bash string manipulation in breath and as much depth as possible to be accessible to readers of all makes and shapes. Read on.
Some of the products that appear on this site are from companies from which QuinStreet receives compensation. This compensation may impact how and where products appear on this site including, for example, the order in which they appear. QuinStreet does not include all companies or all types of products available in the marketplace.