history #檢視歷史命令 -c 清理歷史命令
ls -hl & ll #列印列表
du -h #列印目錄或檔案大小
mkdir & touch #建立目錄和檔案
mv & cp #移動複製目錄或檔案
rm -rf #刪除目錄或檔案
grep #篩選
cat & more & head & tail #檢視檔案內容
vi & vim#編輯檔案內容
find / -iname #查詢
which & whereis #檢視命令決對路徑
netstat -an #執行的埠
ps -ef #執行的程式
kill #殺死程序
hostname #更改主機名
w #檢視那些使用者正在連線
top #cpu負載
lsof -i :***x #檢視***x埠對應的程式
crontab -l &crontab -e #定時任務
chkconfig --list #開機啟動檢視
df -h & fdisk -l #磁碟大小分割槽
mkfs -t ext4 /dev/sdb1 #格式化磁碟
mount & umount -v #掛載解除安裝磁碟
chattr +i #鎖定檔案,不能刪除,不能更改
引用: git 工作中常用命令
1.刪除本地分支 git branch d branchname 2.將本地分支推到遠端倉庫,並在遠端倉庫建立新的分支 git push origin localbranch romotebranch 3.合併兩個分支 先切換到目標分支targetbranch,再進行merge操作 git chec...
git工作中常用命令
git config global user.name your name here git config global user.email your email here git config l 檢視你當前的配置 ssh keygen 預設設定就可以 cat ssh id rsa.pub 生成...
git 工作中常用命令
git init 初始化 git add 新增所有檔案 git status 檢視狀態 若果是第一次會提示你輸入你的 郵箱 和姓名 git commit m 這個版本修改過的一些描述 新增到他和遠端 倉庫 git log 檢視遠端常庫有幾個版本 git reflog 詳細檢視 git reset h...