Linked Questions

5 votes
1 answer
11k views

I don't want to rename a remote branch, as described in Rename master branch for both local and remote Git repositories. How can I rename a local branch which hasn't been pushed to a remote branch? In ...
Acestus's user avatar
  • 63
8 votes
1 answer
18k views

We have a branch called ABC-Awsome_Branch , that is "saved" in feature/3.0.0, so it looks like: feature/3.0.0/ABC-Awsome_Branch But the branch was created with an incorrect name, and even not in the ...
Shudy's user avatar
  • 7,936
6 votes
1 answer
3k views

we have a branch on remote called release/service-release-2016 I want to rename the branch to release/completed/service-release-2016 for archiving and clarity. How do I do this? Everything I ...
Oliver Williams's user avatar
7 votes
0 answers
191 views

I've created a new branch in local with below command and started working on code changes. master> git checkout -b "mybranch" Later, I realized that I needed to follow our standard and that I ...
Freephone Panwal's user avatar
1 vote
0 answers
92 views

I have a single-developer app that was originally written in Python. A few years ago, I decided to try porting it to Go, mainly as a learning exercise. I created a new branch go-port that I used for ...
user9219182's user avatar
1954 votes
25 answers
1.7m views

I have a local branch master that points to a remote branch origin/regacy (oops, typo!). How do I rename the remote branch to origin/legacy or origin/master? I tried: git remote rename regacy legacy ...
JayD's user avatar
  • 20.3k
891 votes
17 answers
335k views

I have the branch master which tracks the remote branch origin/master. I want to rename them to master-old both locally and on the remote. Is this possible? For other users who tracked origin/...
Albert's user avatar
  • 69k
339 votes
2 answers
201k views

How do I rename an existing branch in a Git repo? I want the current branch to have a new name.
Alex's user avatar
  • 3,415
133 votes
8 answers
88k views

We would like to enforce a new policy for our projects that the master branch now be called the release branch to ensure it is more clear as to how the branch should be used. Naturally, we will have ...
Kyle Hayes's user avatar
  • 5,322
53 votes
3 answers
33k views

I know the way to rename branch from command line, but - since I'm using TortoiseGit - I'm curious if there are any options to do such thing. Thanks for the answers :)
Dombi Soma's user avatar
33 votes
4 answers
48k views

One of the things github now recommends is changing the branch to main instead of master. The code given on the github site is: git branch -M main That never works for me, so I thought I would ...
Harlan Nelson's user avatar
13 votes
4 answers
21k views

I have a base repository that lives on a UNC \machine\share ....etc. I have a local clone that I work on in the master branch and occasionally merge over to the "stable" branch. usually I do a git ...
Chris Turner's user avatar
13 votes
2 answers
10k views

I have cloned a git repository. This repository has a remote branch something like -feature-abc. When I type git checkout -feature-abc, I get: error: unknown switch `e' Any idea how to checkout this ...
chanchal118's user avatar
  • 3,667
7 votes
2 answers
6k views

I've taken over a big git repository with lots of branches that no one really seems to know what they are all about. Is there any way to put branches in some kind of grouping or folder so that they ...
Daarwin's user avatar
  • 3,034
10 votes
1 answer
48k views

Please help to make Head point to master in git I tried to git rebase HEAD master and git checkout master Nothing of those helps. Updated: Strange I tried: git symbolic-ref HEAD refs/heads/...
zyxel's user avatar
  • 1,094

15 30 50 per page