Create the GIT branch on your local machine :
$ git checkout -b your_branch
Switched to a new branch ''
Push the branch on github :
$ git push origin your_branch
You can see all branches created by using
Pulling all the changes to the branch/repo :
$ git pull
Committing changes to the branch :
$ git commit
Push changes from your commit into your branch :
$ git push origin your_branch
Commit diff between your branch & master :
$git log --pretty=format:'%C(yellow)%h%C(red)%d %C(red)|%C(green) %ad %C(red)| %Creset%s%Cblue [%cn]' --decorate --graph --date=short master..your_branch
Merging code from your branch to master:
$ git checkout master
$ git merge your_branch
$ git merge your_branch
Checking merge from your branch to master:
$ git checkout your_branch
$ git log --pretty=format:'%C(yellow)%h%C(red)%d %C(red)|%C(green) %ad %C(red)| %Creset%s%Cblue [%cn]' --decorate --graph --date=short master..your_branch
$ git log --pretty=format:'%C(yellow)%h%C(red)%d %C(red)|%C(green) %ad %C(red)| %Creset%s%Cblue [%cn]' --decorate --graph --date=short master..your_branch
>> Here you should see 0 diff
Once you are sure the code is merged successfully, push changes from your commit into master:
$ git checkout master
$ git push origin master
$ git push origin master
Creating tag in master:
$ git checkout master
$ git tag -a tag_name -m 'Describe tag details here'
$ git tag -a tag_name
eg. git tag -a syncs_poc_1.0 -m 'Sync Server 1.0 PoC'
Verifying tag Created:
$ git tag -l
This should have the tag you have created
$ git tag -v tag_name
This should show up all the details
Pushing the tag to github:
$ git push origin tag_name
eg. git push origin syncs_poc_1.0
Counting objects: 1, done.
Writing objects: 100% (1/1), 183 bytes, done.
Total 1 (delta 0), reused 0 (delta 0)
To git@github.com:komli/autoatom.git
* [new tag] syncs_poc_1.0 -> syncs_poc_1.0
Writing objects: 100% (1/1), 183 bytes, done.
Total 1 (delta 0), reused 0 (delta 0)
To git@github.com:komli/autoatom.git
* [new tag] syncs_poc_1.0 -> syncs_poc_1.0
No comments:
Post a Comment