1.bash在用戶(hù)登錄時(shí)從四個(gè)文件中讀取環(huán)境設定:
全局設置文件: /etc/profile /etc/bashrc
用戶(hù)設置文件: ~/.bashrc ~/.bash_profile
~/.bash_logout:在用戶(hù)logout的時(shí)候自動(dòng)執行。
~/.bash_history:用戶(hù)login時(shí)自動(dòng)讀取其內容并加載到內存history記錄中,logout時(shí), 將內存history記錄寫(xiě)入。
/etc/profile.d/*.sh:在/etc/profile中被執行,其中的環(huán)境設定,也會(huì )被全局引用。
2.執行順序
/etc/profile ----> ~/.bash_profile---->~/.bashrc-------->/etc/bashrc
3.快捷鍵
ctrl+d 輸入結束
ctrl+c 鍵盤(pán)中斷請求
ctrl+s&ctrl+q 暫停/恢復屏幕輸出
ctrl+l 清屏
tab :自動(dòng)補全
聯(lián)系客服