Development using git:Developer repositories: Difference between revisions

From Alpine Linux
mNo edit summary
Line 7: Line 7:
{{cmd|cd /your/private/repo/where/you/work/reponame
{{cmd|cd /your/private/repo/where/you/work/reponame
git config remote.origin.pushurl "ssh://user@dev.alpinelinux/home/user/cgit/reponame.git"}}
git config remote.origin.pushurl "ssh://user@dev.alpinelinux/home/user/cgit/reponame.git"}}
Now 'git pull' pulls the public repo, and 'git push' pushes to '''your''' public repo.
Now 'git pull' pulls the public repository and 'git push' pushes to '''your''' public repository.
{{Note|The path where you want to push to should first be prepared with 'git clone --bare ...' as described below in section 'Upload the new project'}}
{{Note|The path where you want to push to should first be prepared with {{cmd|git clone --bare ...}} as described below in section 'Upload the new project'}}

Revision as of 14:59, 26 November 2011

Some git repositories of Alpine developer are hosted at git.alpinelinux.org.

Git Push (Distributed Workflows)

If working with Distributed Workflows you would 'pull' from public repository, 'push' to another publically accessible repository (where you have write access), main developer (who has write access to public repository) 'pulls' you changes from your publically accessed repository into the public repository.

To make it easier for you to work, you can configure 'git push' to push your work to your publically accessible repository ('git pull' would still pull from same repository as you cloned from).

cd /your/private/repo/where/you/work/reponame git config remote.origin.pushurl "ssh://user@dev.alpinelinux/home/user/cgit/reponame.git"

Now 'git pull' pulls the public repository and 'git push' pushes to your public repository.

Note: The path where you want to push to should first be prepared with

git clone --bare ...

as described below in section 'Upload the new project'