Skip to content

Instantly share code, notes, and snippets.

@shamun
Last active January 14, 2018 10:43
Show Gist options
  • Save shamun/b873801c66dc33b56ec57d53c2abfe6f to your computer and use it in GitHub Desktop.
Save shamun/b873801c66dc33b56ec57d53c2abfe6f to your computer and use it in GitHub Desktop.
Details about git

Project management with git

original https://github.com/jp9000/obs-studio, now i want to fork it.

a) have master brance

here keep as it is just for pulling the latest

b) have nightly brance

here work daily

c) have final

here do clean

Step 1:

git clone https://github.com/jp9000/obs-studio
# this already makes the master branch

git remote show origin

Step 2: create branch

git checkout -b nightly
git checkout -b final

NOTE: to delete git branch -d test

Step 3: switch from one to another branch

git checkout master
or
git checkout nightly 
or 
git checkout final


git push origin nightly

Step 4: update and merge

git pull
git merge <branch>

git diff <source_branch> <target_branch>


Step 5: daily working

git add <filename>
git commit -m 'UI: comment'
git push origin <branch>

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