Abstract
Because the shell is an interpreted language, it is comparatively slow. Many operations on files are best done with external commands that implicitly loop over the lines of a file. At other times, the shell itself is more efficient. This chapter looks at how the shell works with files – both shell options that modify and extend file name expansion and shell options that read and modify the contents of files. Several external commands that work on files are explained, often accompanied by examples of when not to use them.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Author information
Authors and Affiliations
Rights and permissions
Copyright information
© 2015 Chris F. A. Johnson and Jayant Varma
About this chapter
Cite this chapter
Johnson, C.F.A., Varma, J. (2015). File Operations and Commands. In: Pro Bash Programming. Apress, Berkeley, CA. https://doi.org/10.1007/978-1-4842-0121-3_8
Download citation
DOI: https://doi.org/10.1007/978-1-4842-0121-3_8
Publisher Name: Apress, Berkeley, CA
Print ISBN: 978-1-4842-0122-0
Online ISBN: 978-1-4842-0121-3
eBook Packages: Professional and Applied ComputingApress Access BooksProfessional and Applied Computing (R0)