Windows 系统相关配置
powershell 7
安装
1 | winget search Microsoft.PowerShell |
在 store 安装 terminal preview
将 powershell 7(pwsh) 设置为默认
键盘配置
PowerToys
使用 WSL 方案
Terminal
设置默认终端为 wsl 的 ubuntu
直接在 terminal 的 setting json 中找到对应 uuid 填入
在终端开启代理
1 | cd ~ |
填入下面内容
1 | export http_proxy="http://127.0.0.1:10887" |
127.0.0.1 如果是在虚拟机,需要填入vpn开启的 ip 地址
1 | touch closeproxy.sh |
填入
1 | unset http_proxy |
添加别名,在 .bashrc
.zshrc
你使用的终端添加
1 | vim .bashrc |
加入
1 | alias openproxy="source ~/.command/openproxy.sh" |
也可以直接
.zshrc
1 | alias openproxy="export http_proxy='http://192.168.0.103:21882'; export https_proxy='http://192.168.0.103:21882'" |
使用方法
1 | # 开启 |
安装 zsh
1 | sudo apt install zsh |
zplun 用于安装插件
1 | curl -sL --proto-redir -all,https https://raw.githubusercontent.com/zplug/installer/master/installer.zsh | zsh |
1 | source ~/.zplug/init.zsh |
编辑 .zshrc 文件,参考
sudo apt install cowsay
安装 nvm
1 | curl -o- https://raw.githubusercontent.com/nvm-sh/nvm/v0.39.1/install.sh | zsh |
使用 Git Bash 方案
安装 Windows 包管理工具,打开 powershell 非管理员模式
1 | Set-ExecutionPolicy RemoteSigned -Scope CurrentUser |
安装常用包
1 | # lazygit |