Home | 簡體中文 | 繁體中文 | 雜文 | Search | ITEYE 博客 | OSChina 博客 | Facebook | Linkedin | 作品與服務 | Email

第 22 章 Bash Shell

目錄

22.1. bash - GNU Bourne-Again SHell
22.1.1. -n 檢查腳本是否有語法錯誤
22.1.2. -x 顯示詳細運行過程
22.2. Introduction
22.2.1. chsh - change login shell
22.2.2. test 命令
22.2.3. I/O 重定向
22.2.3.1. error 重定向
22.2.3.2. 使用塊記錄日誌
22.2.3.3. tee - read from standard input and write to standard output and files
22.2.3.4. 創建檔案
22.2.3.5. 快速清空一個檔案的內容
22.2.4. pipes (FIFOs)
22.2.5. mktemp - create a temporary file or directory 臨時目錄與檔案
22.2.6. History 命令歷史記錄
22.2.6.1. .bash_history
22.2.6.2. .mysql_history
22.2.7. hash - hash database access method
22.2.8. prompt
22.3. variable
22.3.1. 系統變數
22.3.1.1. 命令行參數傳遞
22.3.1.2.
22.3.1.3.
22.3.2. 表達式
22.3.3. Internal Environment Variables
22.3.4. set 設置變數
22.3.5. unset 變數銷毀
22.3.6. 設置變數預設值
22.3.7. export 設置全局變數
22.3.8. declare
22.3.9. Numerical 數值運算
22.3.10. Strings 字元串操作
22.3.10.1. ##/#
22.3.10.2. %%/%
22.3.10.3. :n1:n2
22.3.10.4. #
22.3.10.5. example
22.3.10.6. 計算字元串長度
22.3.10.7. 字元串查找替換
22.3.11. Array 數組
22.3.11.1. for 與 array
22.3.11.2. while 與 array
22.3.11.3. array 與 read
22.3.11.4. 拆分字元串並轉換為數組
22.3.11.5. 數組轉為字元串
22.3.12. read 賦值多個變數
22.3.13. eval
22.4. conditions if and case
22.4.1. if
22.4.2. case
22.5. Loops for, while and until
22.5.1. for
22.5.2. while
22.5.3. until
22.6. Functions
22.6.1. Local variables
22.7. User interfaces
22.7.1. input
22.8. Example
22.8.1. 有趣的Shell
22.8.2. backup
22.8.3. CPU 核心數
22.8.4. Password
22.8.5. processes
22.8.5.1. pid
22.8.5.2. kill
22.8.5.3. pgrep
22.8.6. Shell 技巧
22.8.6.1. 行轉列,再批評
22.8.6.2. for vs while
22.8.6.3. 遍歷字元串
22.8.7. to convert utf-8 from gb2312 code
22.8.8. 使用內存的百分比
22.8.9. 合併apache被cronlog分割的log檔案

22.1. bash - GNU Bourne-Again SHell

22.1.1. -n 檢查腳本是否有語法錯誤


			

22.1.2. -x 顯示詳細運行過程


			
comments powered by Disqus