體驗了一下傳說中的 github for windows(操作git有很多的方法,我還沒有學會,所以找了個簡單的方法),聽說用起來還不錯,畢竟也開始接觸了github。下載地址是 http://windows.github.com/
安裝過程就不說了,下載下來的只有600k那樣,是采用在線安裝的,安裝完成后會在桌面看到兩個圖標,一個是GitHub,另一個是Git Shell。
GitHub是圖形界面的操作,這個很是比較容易理解,這里不解釋了。
現在主要的問題是我用GitHub總是不成功,網絡連接不上,不能clone成功,無奈之下嘗試了git shell,發現同樣的問題,提示了
git clone https://code.google.com/p/android-os-monitor.osmonitor/
Cloning into android-os-monitor.osmonitor...
error: Unknown SSL protocol error in connection to code.google.com:443 while accessinghttps://code.google.com/p/android-os-monitor.osmonitor/info/refs
不成功......
經過了google發現了各種吐槽,國內的網絡對github的訪問很不穩定,所以出現了這個情況(經過測試,我住的地方沒問題,但是公司卻不行),所以偉大的網友們提供了代理的方法,設置git shell的代理,說到代理,最好用的當然是goagent了,下面的設置都是在已經使用goagent的前提下進行的。
1.首先是打開goagent軟件了,看到軟件監聽的地址
2.在git shell下面用命令進行設置就行了:git config --global http.proxy "127.0.0.1:8087"(設置全局變量)
到了這里,問題還沒有解決,因為出現了新的問題
D:\GitHub> git clone https://github.com/subying/jsbook.git
Cloning into 'jsbook'...
fatal: unable to access 'https://github.com/subying/jsbook.git/': SSL certificate problem: unable to get local issuer certificate
突然告訴我,SSL證書有問題?什么情況?
后面又去大量的搜索,發現說這個錯誤並不重要是系統證書的問題,系統判斷到這個行為會造成不良影響,所以進行了阻止,只要設置跳過SSL證書驗證就可以了,那么用命令 : git config --global http.sslVerify false
好了,大功告成!
D:\GitHub> git clone https://github.com/subying/jsbook.git
Cloning into 'jsbook'...
remote: Reusing existing pack: 99, done.
remote: Total 99 (delta 0), reused 0 (delta 0)
Unpacking objects: 100% (99/99), done.
Checking connectivity... done
D:\GitHub>