पर गिट पुश के बाद खाली निर्देशिका निर्देशिका खाली है, मैं रिमोट गिट रेपो बनाने का प्रयास कर रहा हूं, (जिसे मैंने --bare
विकल्प के साथ शुरू किया) और कुछ स्रोत फ़ाइलों को धक्का दिया।रिमोट
मैं एक स्थानीय Git रेपो और एक नंगे दूरस्थ है:
[email protected]:~/notebooks$ cat .git/config
[core]
repositoryformatversion = 0
filemode = true
bare = false
logallrefupdates = true
[branch "master"]
[remote "nbcsm"]
url = ssh://[email protected]/home/ubuntu/notebooks/.git
fetch = +refs/heads/*:refs/remotes/nbcsm/*
मैं के साथ स्थानीय रेपो बनाया: 1. git init
2. git add *.ipynb
3. `Git IPython के पहले आयात प्रतिबद्ध मी" नोटबुक "
मैंने तब सत्यापित किया कि मेरे स्थानीय रेपो ने * .ipynb फ़ाइल को संपादित करने के लिए vi का उपयोग करके फ़ाइलों को ट्रैक किया है और फिर git status
चला रहा है। गिट बदलती फाइल देखता है।
हालांकि, धक्का प्रकट होता है जब मैं git push nbcsm master
निष्पादित सफल होने के लिए, लेकिन मेरी दूरस्थ कंप्यूटर/उदाहरण पर लक्ष्य निर्देशिका खाली है (यानी यह मैं दूरदराज के पुश करने के लिए कोशिश कर रहा हूँ फ़ाइलें शामिल नहीं है):
[email protected]:~/notebooks$ git push nbcsm master
Enter passphrase for key '/home/ubuntu/.ssh/id_rsa':
Counting objects: 11, done.
Compressing objects: 100% (9/9), done.
Writing objects: 100% (9/9), 2.49 KiB, done.
Total 9 (delta 5), reused 0 (delta 0)
To ssh://[email protected]/home/ubuntu/notebooks/.git
7a50f44..295a4fa master -> master
[email protected]:~/notebooks$
सत्यापन किया जा रहा है कि फ़ाइलें रिमोट पर नहीं हैं:
[email protected]:~/notebooks$ ssh [email protected]
Enter passphrase for key '/home/ubuntu/.ssh/id_rsa':
Welcome to Ubuntu 12.04 LTS (GNU/Linux 3.2.0-25-virtual x86_64)
* Documentation: https://help.ubuntu.com/
System information as of Tue Dec 18 16:46:23 UTC 2012
System load: 0.02 Processes: 63
Usage of /: 41.7% of 7.97GB Users logged in: 0
Memory usage: 12% IP address for eth0:REMOTE-IP
Swap usage: 0%
Graph this data and manage this system at https://landscape.canonical.com/
Get cloud support with Ubuntu Advantage Cloud Guest
http://www.ubuntu.com/business/services/cloud
*** /dev/xvda1 will be checked for errors at next reboot ***
[email protected]:~$ sudo find /home/ubuntu/ -name "*.ipynb"
/home/ubuntu/notebooks/Untitled0.ipynb
[email protected]:~$
स्थानीय रेपो कि धक्का दिया नहीं किया जा रहा है के बारे में 12 * .ipynb फ़ाइलें हैं। मैं काफी हद तक निश्चित हूं कि यह वाक्यविन्यास मुद्दे के बजाय एक वैचारिक मुद्दा है, लेकिन मैंने O'Reilly गिट पुस्तक में रिमोट अध्याय पढ़ और पढ़ लिया है और मैं स्टंप हूं।
मेरी तुलना में गैर-बेयर और नंगे रिपो के लिए अधिक पूर्ण स्पष्टीकरण। +1 – VonC