GitHub
作為全球最大的同性交友網(wǎng)站,GitHub可謂是又愛(ài)又恨,愛(ài)的是太多非常棒的開(kāi)源項(xiàng)目了,有很大的參考價(jià)值,也方便我們自己托管項(xiàng)目,恨的是這個(gè)網(wǎng)站的訪問(wèn)實(shí)在是太不給力了,基本是隨緣了,不同城市不同網(wǎng)絡(luò)都各不相同,用寬帶,手機(jī)流量也各不相同,大部分是不怎么好的。 最近發(fā)現(xiàn)一個(gè)叫做Fetch Github Hosts的項(xiàng)目,也許能幫到大家,這里只針對(duì)網(wǎng)絡(luò)不好的同學(xué)哈,fetch-github-hosts是主要為解決研究及學(xué)習(xí)人員訪問(wèn)Github過(guò)慢或其他問(wèn)題而提供的免費(fèi)的Github hosts同步服務(wù),項(xiàng)目開(kāi)源,有寫(xiě)具體的使用方法,有需要的同學(xué)可以前往學(xué)習(xí)一下。簡(jiǎn)單粗暴的方法
手動(dòng)添加hosts 訪問(wèn)https://hosts.gitcdn.top/hosts.txt這個(gè)網(wǎng)站,將網(wǎng)頁(yè)的全部?jī)?nèi)容粘貼到你的hosts文件中。
Linux / MacOS hosts路徑:/etc/hosts
Windows hosts路徑:C:WindowsSystem32driversetchost
老宇哥這里也順便貼出來(lái),大家復(fù)制即可:
# fetch-github-hosts begin
140.82.112.26 alive.github.com
140.82.112.26 live.github.com
185.199.108.154 github.githubassets.com
140.82.112.21 central.github.com
185.199.111.133 desktop.githubusercontent.com
185.199.109.153 assets-cdn.github.com
185.199.108.133 camo.githubusercontent.com
185.199.108.133 github.map.fastly.net
146.75.113.194 github.global.ssl.fastly.net
52.192.72.89 gist.github.com
185.199.108.153 github.io
52.192.72.89 github.com
192.0.66.2 github.blog
52.69.239.207 api.github.com
185.199.109.133 raw.githubusercontent.com
185.199.109.133 user-images.githubusercontent.com
185.199.111.133 favicons.githubusercontent.com
185.199.109.133 avatars5.githubusercontent.com
185.199.109.133 avatars4.githubusercontent.com
185.199.109.133 avatars3.githubusercontent.com
185.199.108.133 avatars2.githubusercontent.com
185.199.109.133 avatars1.githubusercontent.com
185.199.111.133 avatars0.githubusercontent.com
185.199.111.133 avatars.githubusercontent.com
52.193.111.178 codeload.github.com
52.216.177.203 github-cloud.s3.amazonaws.com
52.216.177.203 github-com.s3.amazonaws.com
52.217.91.148 github-production-release-asset-2e65be.s3.amazonaws.com
52.217.91.148 github-production-user-asset-6210df.s3.amazonaws.com
52.217.91.148 github-production-repository-file-5c1aeb.s3.amazonaws.com
185.199.109.153 githubstatus.com
64.71.144.211 github.community
52.237.112.130 github.dev
140.82.112.21 collector.github.com
13.107.42.16 pipelines.actions.githubusercontent.com
185.199.108.133 media.githubusercontent.com
185.199.108.133 cloud.githubusercontent.com
185.199.108.133 objects.githubusercontent.com
# last fetch time: 2022-06-11T2302+08:00
# update url: https://hosts.gitcdn.top/hosts.txt
# fetch-github-hosts end
特別注意,在windows中,大家修改完hosts之后,直接保存不了,保存的時(shí)候先另存在桌面,再拖進(jìn)去覆蓋即可!
刷新生效:
Linux: /etc/init.d/network restart
Windows: ipconfig /flushdns
Macos: sudo killall -HUP mDNSResponder
試試訪問(wèn)效果
開(kāi)源倉(cāng)庫(kù):https://github.com/Licoy/fetch-github-hosts
GitHub鏡像站或者使用Github鏡像站,國(guó)內(nèi)可以加速訪問(wèn)GitHub的網(wǎng)站(GitHub加速),使用起來(lái)和官網(wǎng)沒(méi)啥區(qū)別,只是域名不同而已。
-
https://hub.おうか.tw
-
https://hub.連接.臺(tái)灣
-
https://hub.fastgit.xyz
-
https://cdn.githubjs.cf
-
https://gitclone.com
-
開(kāi)源
+關(guān)注
關(guān)注
3文章
3381瀏覽量
42604 -
GitHub
+關(guān)注
關(guān)注
3文章
473瀏覽量
16503
原文標(biāo)題:提高訪問(wèn)GitHub速度方法
文章出處:【微信號(hào):strongerHuang,微信公眾號(hào):strongerHuang】歡迎添加關(guān)注!文章轉(zhuǎn)載請(qǐng)注明出處。
發(fā)布評(píng)論請(qǐng)先 登錄
相關(guān)推薦
評(píng)論