iterm2中ping下github.com和github.global.ssl.fastly.net

$ ping github.com

  得到以下

PING github.com (192.30.253.112): 56 data bytes
64 bytes from 192.30.253.112: icmp_seq=0 ttl=47 time=245.930 ms
64 bytes from 192.30.253.112: icmp_seq=1 ttl=47 time=245.910 ms

  记录ip  192.30.253.112

同理

$ ping github.global.ssl.fastly.net

  

最后编辑hosts文件

$ vim /etc/hosts

 加入这两行代码

192.30.253.112 github.com
151.101.113.194 github.global.ssl.fastly.net

 最后更新DNS缓存

$ sudo dscacheutil -flushcache

  

git提交代码速度过慢解决方法(macos)的更多相关文章

  1. 使用git提交代码到github,每次都要输入用户名和密码的解决方法

    自从使用git提交代码到github后,发现自己使用git的功力增长了不少,但也遇到不少问题.比如,使用git提交代码到github的时候,经常要求输入用户名和密码,类似这种: 网上有这么一种解决方法 ...

  2. git提交代码报错 trailing whitespace的解决方法

    1. git提交代码报错 trailing whitespace 禁止执行pre-commit脚本 进入到项目目录中 chmod a-x .git/hooks/pre-commit 2.git提交代码 ...

  3. 怎样解决git提交代码冲突

    当我们使用git提交代码时,别人可能也同一时候改动了我们改动的文件,可是别人的先合入到配置库里边,这样当我们的提交要合入时.就会产生冲突,能够使用下面步骤来解决冲突: (1) git rebase   ...

  4. git 本地代码提交至远程master分支解决方法

    git 提交代码,本地新建一个my分支,不从本地master分支直接上传,而是先从本地my分支上提交至本地master分支,然后本地master提交至远程master分支上.前提是远程只有一个mast ...

  5. Git提交代码到主分区

    git 提交代码,本地新建一个my分支,不从本地master分支直接上传,而是先从本地my分支上提交至本地master分支,然后本地master提交至远程master分支 上.前提是远程只有一个mas ...

  6. git提交代码出现错误fatal: Unable to create '项目路径/.git/index.lock': File exists.

    git提交代码出现错误fatal: Unable to create '项目路径/.git/index.lock': File exists. 具体出错代码如下: 具体原因不详,在stackoverf ...

  7. Git提交代码规范 而且规范的Git提交历史,还可以直接生成项目发版的CHANGELOG(semantic-release)

    Git提交代码规范 - 木之子梦之蝶 - 博客园 https://www.cnblogs.com/liumengdie/p/7885210.html Commit message 的格式 Git 每次 ...

  8. Git提交代码报错Git push error:src refspec XXX matches more than one解决方案

    Git提交代码push时,报错这个 error: src refspec master matches more than one. error: failed to push some refs t ...

  9. “git push”后返回“Error 403”解决方法

    问题描述: 1,mac ox系统,terminal上运行命令git push出现403错误: 2,代码是在别人的github(暂且叫origin branch吧)上克隆的,修改和添加了部分代码后欲提交 ...

随机推荐

  1. Hive开窗函数的理解

    1.从一个sql语句开始 select id,sum(price) over(partition by id order by price desc) from books; sum作为聚合函数的时候 ...

  2. MapReduce Design Patterns(chapter 2 (part 3))(四)

    Inverted Index Summarizations Pattern Description 反向索引模式在MapReduce分析中经常作为一个例子.我们将会讨论我们要创建的term跟标识符之间 ...

  3. unittest:1 用例编写

    unittest是python自带的单元测试框架,包含测试用例case,测试集suite,测试集加载loader,测试执行runner,测试结果result等. 简单使用:写一个用例类继承自unitt ...

  4. Spring Cloud(中文版)

    原文链接:Spring Cloud I.云原生应用 Spring Cloud上下文:应用上下文服务 2.1.Bootstrap应用程序上下文 2.2.应用程序上下文层次结构 2.3.更改Bootstr ...

  5. psql: FATAL: role “postgres” does not exist

    I'm a postgres novice. I installed the postgres.app for mac. I was playing around with the psql comm ...

  6. Django的视图流式响应机制

    Django的视图流式响应机制 Django的响应类型:一次性响应和流式响应. 一次性响应,顾名思义,将响应内容一次性反馈给用户.HttpResponse类及子类和JsonResponse类属于一次性 ...

  7. Python3安装scrapy框架步骤

    Python3安装scrapy框架步骤 1.       安装wheel a)     Pip install wheel 2.       安装lxml Pip install lxml 3.    ...

  8. Controller如何写的更简化

    Controller层相当于MVC中的C,也是安卓或者前端请求的接口. 首先说Controller为什么需要写的更加简化? 第一.Controller是不能复用的: 第二.即便是将Controller ...

  9. 树莓派gitlab

    pi@raspberrypi:~/Downloads $ sudo dpkg -i gitlab-ce_8.17.7-ce.0_armhf.debSelecting previously unsele ...

  10. Linux Shell常用技巧(九)

    十九.  和系统运行进程相关的Shell命令:       1.  进程监控命令(ps):    要对进程进行监测和控制,首先必须要了解当前进程的情况,也就是需要查看当前进程,而ps命令就是最基本同时 ...