ZenTao Cloud has GIT hosting service. Read the instruction below to use it.
1. Go to your account and click "Manage Git".
Fill in your GIT admin user name and password, and click "Start(Open)".
Then GIT will be available within one minute. The default setting is this admin had privileges to read and write all repositories on this site.
In repository, Git use the netrc file to confirm username and password. Windows use _netrc , while Linux use .netrc. The followings are about how to create netrc.
1) Go to “Start"->"Run” and open %USERPROFILE%. Create “_netrc” file.
2) Open _netrc in Notebook and enter Git server name, user name, password , and Save. For example,
machine xxx.zentao.pm login xxx password xxxxxx is your Git address, user name , and password.
Create .netrc on root directory and edit it as
machine xxx.zentao.pm login xxx password xxxxxx is your Git address, user name, and password.
3. Create a branch
In Linux, run the followings,
#initialize repository mkdir test cd test git init #create readme and add to local touch readme git add readme git commit #add git origin and push to master git remote add origin https://xxx.zentao.pm/zentao.git/ git push origin master
If error: failed to push some refs to 'https://xxx.zentao.pm/git/qq.git', check whether netrc is created in the right way.
Clone Git repository:
git clone https://xxx.zentao.pm/git/xxx.git other
Check whether it is cloned.
git fetch origin
git merge origin/master