Difference between revisions of "Git"
From ProgClub
(Create new git project) |
(Create new git project) |
||
Line 14: | Line 14: | ||
Add: | Add: | ||
− | |||
− | |||
− | |||
[hooks] | [hooks] | ||
mailinglist = vcs@progclub.org | mailinglist = vcs@progclub.org |
Revision as of 14:31, 8 April 2014
Create new git project
$ ssh honesty.progclub.net $ sudo -s # cd /git # mkdir repo-name.git # cd repo-name.git # git init --bare --shared=all # echo repo-name > desription # mv hooks/post-receive.sample hooks/post-receive # chown -R www-data:user . # vim config
Add:
[hooks] mailinglist = vcs@progclub.org
# vim hooks/post-receive
Uncomment:
. /usr/share/doc/git-core/contrib/hooks/post-receive-email
Then from your workstation:
$ git clone ssh://www.progclub.net/git/repo-name.git $ cd repo-name $ git commit -m "Initial empty commit" --allow-empty $ git push origin master