docs:site5:git

This is an old revision of the document!


git (on Site5)

You need to set up ssh_access to be able to act as the developer on a project.

set up a bare git repo

  • ssh into your account
  • create a new folder to hold your repo
    mkdir public_html/git/path/to/repo.git && cd public_html/git/path/to/repo.git
  • create a new “bare” repo
    git init --bare
    • if multiple users will be pushing to this…
      git init --bare shared=group
  • exit from your ssh connection
  • cd into your local project, and add the remote
    git remote add origin remoteuser@remotehost.com:public_html/git/path/to/repo.git
    • ::!:: I'm not sure why, but specifying this with ssh: protocol did not work, but leaving it off works fine * push your local master to the remote repo<code> git push origin master </code> * if you want this to be known as something other than origin, change origin as desired ===== developer user clone ===== <code> git clone remoteuser@remotehost.com:path/to/repo.git localdest </code> ===== public user clone ===== Make a subdomain called “git” in SiteAdmin first. <code> git clone http://git.remotehost.com/Project.git </code>
  • docs/site5/git.1270918446.txt.gz
  • Last modified: 2010/04/10 10:54
  • by billh