Skip to content

Instantly share code, notes, and snippets.

@ross-spencer
Created January 7, 2019 11:18
Show Gist options
  • Save ross-spencer/01ac6687a68962893f2911e1d73487db to your computer and use it in GitHub Desktop.
Save ross-spencer/01ac6687a68962893f2911e1d73487db to your computer and use it in GitHub Desktop.
Some Git Bits 'n' Pieces

GIT Guidelines at Artefactual

Artefactual has its own Git repository server on Gitolite. The implications of this is that the work a user completes on GitHub will be overwritten by any mirroring process onto the GitHub servers.

In short, branches, pull-requests, etc. subsequently merged via GitHub will never make it onto the Artefactual servers. They push, but never pull.

git remote set-url origin [email protected]:archivematica.git
git checkout -b dev/issue-1-my-new-branch
...work and commits happen here...
git push    # data sent to remote as many times as required
...work and commits happen here ... 
git push    # data sent to remote as many times as required
...rebase happens here...
git push -f
git checkout qa/1.x
git pull --rebase
git merge --ff-only origin/dev/issue-808-invalid-check-for-filesize-against-zero
git push
git push origin :dev/issue-808-invalid-check-for-filesize-against-zero

Other remote branch examples:

origin	[email protected]:archivematica-sampledata.git (fetch)
origin	[email protected]:archivematica-sampledata.git (push)

To see remote branches - those hosted at git.artefactual.com:

ssh [email protected] info

Internal Guidance: https://internal.artefactual.com/wiki/Process_documentation/Merging

--

git pull and rebase example

  • git pull && git rebase stable/1.7.x

git tagging example

  • git tag v1.8.1-rc.1 56b3c2c4; and git push origin refs/tags/v1.8.1-rc.1

If something isn't on the remote server:

you could also add gh remote git remote add -f gh https://github.com/artefactual/automation-tools (edited)

git show b35b78f81a48ae34d1751266b14c30d83d70e94d

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment