Skip to content

Instantly share code, notes, and snippets.

@termanator1128
Last active October 13, 2017 04:30
Show Gist options
  • Save termanator1128/3cda20e18e0d27484e4eaa91bc6c4df8 to your computer and use it in GitHub Desktop.
Save termanator1128/3cda20e18e0d27484e4eaa91bc6c4df8 to your computer and use it in GitHub Desktop.
Git Commands to Use
Update Repo
*git remote add upstream (url ssh) git@github.com:StormlightTech/openCAD-php.git *ONLY ONCE*
git pull upstream (branch)
Re-push
--rebase
Push Update
git add -A
git commit -m "Message"
git push origin master <-(brach)
*Create New Branch* *USE THIS*
git checkout -b (issue type)/(issue)
git add (files/-A)
git commit
git push origin (new branch)
Go back to master branch
git checkout master
*Delete Branch* *AFTER MERGED*
git branch -D (branch)
repull
repush
@phillf
Copy link

phillf commented Oct 13, 2017

When naming a branch it should be "issue-type/something-descriptive"
Example: enhancement/BOLO-Display-on-MDT
Example: bug/Gender-IDs-showing

This way it is easy to track what issues goes with what.

You can also do commits with JIRA comments as long as your committer email and name match in JIRA and GitHub.

Example: git commit -m "PROJKEY-123 #comment Some comment text here. #resolve"
For more information about Smart Commits please visit this page.

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