- Mastering Linux Shell Scripting
- Andrew Mallett
- 202字
- 2021-07-30 09:40:45
Summary
This marks the end of the chapter and I am sure that you might have found this useful. Especially for those making a start with bash scripting, this chapter must have built a firm foundation on which you can build your knowledge.
We began by ensuring that bash is secure and not susceptible to embedded functions shell-shock. With bash secured, we considered the execution hierarchy where aliases, functions, and so on are checked before the command; knowing this can help us plan a good naming structure and a path to locate the scripts.
Soon we were writing simple scripts with static content but we saw how easy it was to add flexibility using arguments. The exit code from the script can be read with the $?
variable and we can create a command line list using ||
and &&
, which depends on the success or failure of the preceding command in the list.
Finally, we closed the chapter by looking at debugging the script. Its not really required when the script is trivial, but it will be useful later when complexity is added.
In the next chapter, we will be creating interactive scripts that read the user's input during script execution.
- The Modern C++ Challenge
- Visual FoxPro程序設計教程
- JIRA 7 Administration Cookbook(Second Edition)
- 數據結構簡明教程(第2版)微課版
- Quarkus實踐指南:構建新一代的Kubernetes原生Java微服務
- MySQL數據庫管理與開發實踐教程 (清華電腦學堂)
- Python數據挖掘與機器學習實戰
- C語言程序設計
- INSTANT Sinatra Starter
- Learning R for Geospatial Analysis
- Unity Android Game Development by Example Beginner's Guide
- Visual C++程序設計與項目實踐
- UI動效設計從入門到精通
- Learning ECMAScript 6
- Python滲透測試編程技術:方法與實踐(第2版)