Tag: git branch

New branch creation in Git using old commits in existing branch

I have a stable point commit/tag b1. Now I want to create another branch, say b2, from that stable commit/tag, and work on it. I am thinking I should do this: $ git checkout b1. $ git fetch –tags $ git checkout tags/my_stable_tag Now create and move this code to new branch b2: $ git […]

Working on multiple git branches that are dependent on each other

I’m maintaining 4 branches of a project on Git with a structure as below. master student teacher authentication The problem is I created “authentication” branch the last and added some code from this branch. Now, I switched to “teacher” branch to continue working on it. However, I need some features I added in the “authentication” […]

how to see branches in my remote origin?

I have two remote origins for my project. I did like this when I already have one origin git remote add github https://github.com/iincube/Commuter.git then my project have two remote origins like this github https://github.com/iincube/Commuter.git (fetch) github https://github.com/iincube/Commuter.git (push) origin https://github.com/iincube/SafetraxApp.git (fetch) origin https://github.com/iincube/SafetraxApp.git (push) now if I am doing $git branch I can see only […]

Why changes in one branch can affect the other branch in git?

I was at master branch, I commit everything then I create a new branch “git checkout -b xxx” then I switch back to master “git checkout master” then I delete everything with master branch without using “git rm” I checkouted to branch xxx, during the branch switching, it shows a long list that every file […]

Git not showing star next to current local branch

I am new to git and have encountered a confusing situation. In summary I am having trouble understanding how case-sensitivity works pertaining to branch names. For example I am on the master branch and create a new branch called AP-1025 with the command git checkout -b AP-1025, now I can do a git branch and […]

Git: Does commit affect a remote branch that Im tracking?

I’m currently tracking a remote branch (origin/implement) and I have the authentication to push to it, however currently I don’t want to do such and instead I just want to commit my changes on the local that is tracking the remote. My question is when I commit does it record my commits on the branch […]

Does git submodule branch switch along with main project's branch?

Recently I got to know git submodules. They appear to be self-sufficient projects with their own git structure and branches. When I switch main project’s branch, does this also switch submodule’s branch? How does git handle this situation?

Should Patches have own branch in git workflow?

I am reading here about git branching strategie. Where to assign patches? should patches have their own branch? If yes where should patches branched from? from master branch?

Untangling GIT mess – branch/merge some commits after the fact

A classic case of “don’t start from here“… as is the way of all things, disorganisation has descended on our Git, tree looks something like this: A-B-C-D master \ E-F-G-H-I-J-K-L-M-N-O-P-Q-R-S-T… exciting new stuff Whereas the unfortunate truth that it would be better reflected something like this: P-Q failed idea / A-B-C-D K-L-M-N-O U-V… master \ […]

Are parallel branches the best way to manage similar projects which share code?

I have two projects (Product-line A and Product-line B) which share about 90% of the same code. I want to migrate both projects to GitHub. Should I use the common code as the master branch and create a new branches for product-line A and product-line B? Would there be any disadvantage to having two parallel […]

Git Baby is a git and github fan, let's start git clone.