GIT

From code/src wiki
Revision as of 10:41, 24 May 2011 by Michael (talk | contribs) (Created page with "== Hosting an existing GIT project == So, you've developed some software, made a release, and want to provide public read-only access to all the sources ? Assumptions: # You've …")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigationJump to search

Hosting an existing GIT project

So, you've developed some software, made a release, and want to provide public read-only access to all the sources ?

Assumptions:

  1. You've already used git to manage software on the host 'dev-host'. The git repository exists in ~/projects/mySoftware, with a corresponding ~/projects/mySoftware/.git directory.
  2. You have access to 'public-host', which is running apache.
  • On public-host, install the necessary packages
sudo apt-get install git-daemon-run gitweb
  • On public-host, clone the existing git repository
cd ~/projects
git clone ssh://dev-host/~/projects/mySoftware
  • On public-host, make the repository available. gitweb and the git daemon will look in /var/cache/git
sudo ln -s ~$USER/projects/mySoftware/.git mySoftware.git
touch ~/projects/mySoftware/.git/git-daemon-export-ok