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
相关推荐
灵魂学者3 小时前
Vue3.x —— 父子通信
前端·javascript·vue.js·github
元直数字电路验证4 小时前
GitHub Desktop 上传流程
github
Crystal3287 小时前
Git 基础:生成版本、撤消操作、版本重置、忽略文件
前端·git·github
Elastic 中国社区官方博客10 小时前
用 Elasticsearch 构建一个 ChatGPT connector 来查询 GitHub issues
大数据·人工智能·elasticsearch·搜索引擎·chatgpt·github·全文检索
用户3458482850510 小时前
除了使用dict.fromkeys()和OrderedDict.fromkeys(),还有哪些方法可以实现列表去重?
github
摇滚侠11 小时前
零基础小白自学 Git_Github 教程,git 命令行操作1,笔记18
笔记·git·github
无限进步_11 小时前
C++从入门到类和对象完全指南
开发语言·c++·windows·git·后端·github·visual studio
itwangyang52011 小时前
在 GitHub 上生成和配置个人访问令牌(PAT),并将其用于 R 环境中的凭证管理和包安装。
开发语言·r语言·github
love530love12 小时前
【ComfyUI/SD环境管理指南(二)】:如何避免插件安装导致的环境崩溃与“外科手术式”修复
人工智能·windows·python·stable diffusion·github·aigc·comfyui
Jonathan Star13 小时前
Git 的 pre-commit hook(以及其他钩子脚本)默认不会被 git commit 追踪,也不会被 git push 推送到远程仓库
github