मैंने घर पर अपने गिटहब भंडार को क्लोन किया, और स्पष्ट रूप से कुछ खराब कर दिया। वैसे भी, मैंने बहुत सारे बदलाव किए हैं, या मैं निर्देशिका को मिटा दूंगा और इसे फिर से कर दूंगा।इस बॉक्स पर गिटहब को धक्का नहीं दे सकता
सभी कीसबसे पहले, जब मैं ssh [email protected]
कर मैं निम्नलिखित हो:
PTY allocation request failed on channel 0 ERROR: Hi asdfadfs! You've successfully authenticated, but GitHub does not provide shell access Connection to github.com closed.
मैं कोई त्रुटि मिलती है, लेकिन यह कहता है कि मैं सफलतापूर्वक प्रमाणीकृत है?
git add .
git commit -a -m "hello"
git push origin master
[master 74a5e82] hello
3 files changed, 45 insertions(+), 12 deletions(-)
fatal: The remote end hung up unexpectedly
यह स्पष्ट रूप से काम नहीं करता है। और मैं git करने के लिए नया हूँ, इसलिए अब यह होता है जब मैं प्रतिबद्ध करने के लिए प्रयास करें:
git add .
git commit -a -m "hello"
git push origin master
# On branch master
nothing to commit (working directory clean)
fatal: The remote end hung up unexpectedly
और अंत में, git pull
?
$ git pull
You asked me to pull without telling me which branch you
want to merge with, and 'branch.master.merge' in
your configuration file does not tell me either. Please
specify which branch you want to merge on the command line and
try again (e.g. 'git pull <repository> <refspec>').
See git-pull(1) for details.
If you often merge with the same branch, you may want to
configure the following variables in your configuration
file:
branch.master.remote = <nickname>
branch.master.merge = <remote-ref>
remote.<nickname>.url = <url>
remote.<nickname>.fetch = <refspec>
See git-config(1) for details.
यहाँ मेरी .git/config
[core]
repositoryformatversion = 0
filemode = true
bare = false
logallrefupdates = true
ignorecase = true
[branch "master"]
[remote "origin"]
url = git://github.com/my/project.git
fetch = +refs/heads/*:refs/remotes/origin/*
कि यूआरएल चर वास्तव में मेरे सही Git यूआरएल को इंगित करता है। धन्यवाद।
ओह: - मेरी libcloud रिपोजिटरी से सीधे मैं इस पोस्ट के लिए अप्रासंगिक कारणों के लिए "mothership" का उपयोग करें। लंबा दिन। धन्यवाद। – mculp
मुझे भी, मैं आपको महसूस करता हूं। :) –
इसे ठीक करने का एक आसान तरीका यह है कि इसे अपनी '~/.gitconfig' फ़ाइल में जोड़ें: https://gist.github.com/412f0b1c8841cceed750 – henrikhodne