嗨大家:這是我第一次寫這個清單,所以請原諒新手問題和任何其他規則,我沒有遵循。新手github用戶試圖將文件推送到github上的回購
我正在開發fedora linux,並嘗試用git來自己親自實驗,但真的是github。所以,我遵循各種教程並創建了一個名爲markleeds2/bclean的github帳戶和存儲庫。我還添加了ssh公鑰,這似乎工作正常。回購沒有任何文件。所以,我離開了github並進入了linux命令行,以下是我根據一個教程找到的步驟,我找到了我不記得的地方。顯然,我做錯了什麼,因爲我在嘗試推送文件時遇到錯誤。非常感謝您提供任何幫助。
P.S:因爲它沒有「bclean」我有一種感覺,我的遠程Git在最後添加起源命令是不正確的 。
#==========================================================================================
:~/research/equity/projects/git_hub/git> mkdir test
:~/research/equity/projects/git_hub/git> cd test
:~/research/equity/projects/git_hub/git/test> dir
total 0
:~/research/equity/projects/git_hub/git/test> git init
Initialized empty Git repository in /home/markleeds/research/equity/projects/git_hub /git/test/.git/
:~/research/equity/projects/git_hub/git/test> touch README
:~/research/equity/projects/git_hub/git/test> git status
# On branch master
初始提交
未跟蹤文件: (使用 「混帳添加...」 在什麼將致力於包括)
README
沒有加入到承諾,但未跟蹤文件存在(使用「git add」來跟蹤)
:~/research/equity/projects/git_hub/git/test> git add README
:~/research/equity/projects/git_hub/git/test> git status
On branch master
Initial commit
Changes to be committed:
(use "git rm --cached <file>..." to unstage)
new file: README
:~/research/equity/projects/git_hub/git/test> git commit -m 'first commit'
[master (root-commit) 676f27d] first commit
:~/research/equity/projects/git_hub/git/test> git remote add origin [email protected]:markleeds2/test.git
:~/research/equity/projects/git_hub/git/test> git push -u origin master
ERROR: Repository not found.
fatal: The remote end hung up unexpectedly
看來你沒有在GitHub上創建的存儲庫,也許在'git的一個錯字遠程添加原產[email protected]:markleeds2 /測試。 git'? – eagleoneraptor 2012-03-11 04:33:52