
WSL走Clash代理
- 参考教程:
- 注意点:
- Clash打开为全局或rule模式均可
- VScode使用bash端,且将信息粘贴到root目录下的 .bashrc
# 添加到环境变量设置中,例如~/.bashrc export hostip=$(cat /etc/resolv.conf |grep -oP '(?<=nameserver\ ).*') export https_proxy="http://${hostip}:7890" export http_proxy="http://${hostip}:7890"
http_proxy=127.0.0.1:7890 https_proxy=127.0.0.1:78901
2
3
4
5
- Windows走clash代理
- 1. 右键【我的电脑 】-> 属性 -> 高级系统设置 -> 高级 -> 环境变量
- 2. 添加如下的系统环境变量
- 将VScode的默认prompt变为cmd,而不是powershell。