windows下github使用方法
安裝的時候最好還是允許在shell中嵌入git命令,相對比較方便的。
git的初始設定
git config --global user.name "your real name"建立倉庫git config --global user.email [email protected]
在git bash裡找到你的專案目錄。(或直接用shell右鍵裡的git bash here)
git init這樣在你的專案目錄下就會有乙個.git的隱藏目錄(類似於.svn)。
初始化專案
git add .留心後面的乙個 「.」,這是新增所有檔案的情況,如果願意,你也可以新增特定的幾個檔案,比如git add readme.txt等等。
之後就可以做我們的first commit到倉庫裡了:
git commit -m 'first commit'-m 引數以及後面的字串是新增說明。
註冊github賬號
首先到註冊賬號。註冊之後可以看到這樣的介面。選擇第一項建立乙個專案
表單需要填寫:
project name(專案名稱)
description(描述)
homepage url(主頁url,一般就以專案名稱命名好了)
建立ssh密匙
回到桌面,開啟git bash,輸入以下命令:
ssh-keygen -c '[email protected]' -t rsa確認使用預設路徑,然後輸入兩次密碼就行(也可以空密碼)。
可以使用以下命令測試連線:
ssh -v [email protected]會要求輸入你剛才設定的密碼(空密碼除外),如果成功的話可以看到這樣的error:
error: hi arthraim! you've successfully authenticated, but github does not provide shell access
提交密匙
上傳**
最後就是上傳你的**了~ bash切換到你的專案目錄下,輸入以下命令:
git remote add origin [email protected]:github使用者名稱/github專案名.git這時在」github使用者名稱/github專案homepage url」就可以看到剛才提交的專案了~git push origin master
如果已經有乙個git的repo,想新增到github上,那就直接執行第8步的命令就可以了(不要忘記密匙的相關工作)。
Windows 下GitHub 安裝和使用
一 官網註冊和設定 1.登入官網,註冊賬號,其中使用者名稱以後會用到。2.建立倉庫。使用公開倉庫方式建立,公開倉庫免費。右上角 加號 new repository 第一行 倉庫名字。第二行 對倉庫的描述。第三行 選擇public 公開倉庫 第五行 建立乙個readme檔案,介紹專案功能。第六行 ad...
Windows下安裝OpenSSL及其使用
1.perl 安裝後重啟系統。2latest openssl 並解壓到 c openssl 0.9.8k。參考openssl 目錄下的 install.win32 說明進行安裝 1 進入解壓目錄。cd c openssl 0.9.8k 2 執行configure。perl configure vc ...
Windows下安裝OpenSSL及其使用
方法一 windows binaries can be found here you can do this conversion with the openssl library 方法二 手動編譯 source 參考openssl目錄下的install.win32說明進行安裝 1 進入解壓目錄。c...