Github 程序员加速 http和ssh代理设置

简单直接的输出干货,复制->粘贴->完活.

Http代理设置

全局

bash 复制代码
git config --global http.proxy socks5://127.0.0.1:10808

指定github

bash 复制代码
git config --global http.https://github.com.proxy socks5://127.0.0.1:10808

SSH代理设置

Linux

配置文件在home目录下的 .ssh/config 其中 nc 程序位于 /usr/bin/nc

bash 复制代码
$ cat ~/.ssh/config

Host github.com
Hostname ssh.github.com
User git
Port 443
ProxyCommand nc -v -x 127.0.0.1:10808 %h %p

Windows

使用Git Bash

bash 复制代码
$ cat ~/.ssh/config

Host github.com
Hostname ssh.github.com
User git
Port 443
ProxyCommand "C:\Program Files\Git\mingw64\bin\connect.exe" -S 127.0.0.1:10808 %h %p
相关推荐
不午睡的探索者6 小时前
告别性能瓶颈!Python 量化工程师,进击 C++ 高性能量化交易的“必修课”!
c++·github
光溯星河7 小时前
【实践手记】Git重写已提交代码历史信息
后端·github
独立开阀者_FwtCoder7 小时前
URL地址末尾加不加 "/" 有什么区别
前端·javascript·github
独立开阀者_FwtCoder7 小时前
Vue3 新特性:原来watch 也能“暂停”和“恢复”了!
前端·javascript·github
寻月隐君7 小时前
告别 Vec!掌握 Rust bytes 库,解锁零拷贝的真正威力
后端·rust·github
inhere11 小时前
gookit/goutil v0.7.0 新版本发布:模块调整与功能增强
开源·go·github
用户6210245309212 小时前
React:当UI开发从「搬砖」变成「搭乐高」的魔法时刻!
github
用户39183841721112 小时前
Jupyter Notebook:不只是个笔记本,而是你的科学计算驾驶舱!
github
用户2555816069012 小时前
Laravel实战指南:从工匠工具到现代PHP开发的艺术
github
用户0826998226012 小时前
Docker革命:为什么你的下一个项目必须容器化?🚀
github