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
相关推荐
qianmoQ2 小时前
GitHub 趋势日报 (2025年05月31日)
github
油泼辣子多加3 小时前
2025年06月06日Github流行趋势
github
粥里有勺糖3 小时前
视野修炼-技术周刊第122期 | 发光图片制作
前端·javascript·github
qianmoQ4 小时前
GitHub 趋势日报 (2025年06月05日)
github
小馒头君君4 小时前
3 个优质的终端 GitHub 开源工具
github
MarkHD7 小时前
AI编程助手入门指南:GitHub Copilot、Cursor与Claude的安装与基础使用
github·copilot·ai编程
追逐时光者9 小时前
2个 GitHub 实用辅助神器,帮你快速了解和上手 GitHub 开源项目(附带 GitHub 加速神器)!
github
寻月隐君11 小时前
Web3实战:Solana CPI全解析,从Anchor封装到PDA转账
后端·web3·github
OpenTiny社区1 天前
开源之夏报名倒计时3天!还有9个前端任务有余位,快来申请吧~
前端·github
王景程1 天前
SELinux是什么以及如何编写SELinux策略
git·github