Linux常用指令记录
查看APT软件包安装路径
dpkg -L 软件名
列出手动安装的软件包
即不包括作为依赖安装的软件包
apt-mark showmanual
内网穿透
在服务器上监听222端口,将连接转发到本地22端口。
autossh -fCNR 222:0.0.0.0:22 root@jdao.online
参数-f表示在后台执行
添加用户
useradd <username>
passwd <username>
安装中文
命令行
apt install language-pack-zh-hans
Gnome界面
apt install language-pack-gnome-zh-hans
运行语言支持检查
sudo apt install $(check-language-support)
从Git整个历史中清除node_modules
愿天堂的Git储存库里没有node_modules
git filter-branch --force --index-filter 'git rm --cached --ignore-unmatch -r node_modules' --prune-empty --tag-name-filter cat -- --all