Skip to main content

Questions tagged [remote-branch]

The tag has no usage guidance.

remote-branch
Filter by
Sorted by
Tagged with
-1 votes
1 answer
40 views

Tracking local changes in git to a remote branch without pushing to remote

So this may be really obvious to people, but I find myself regularly wanting a workflow where I can easily: Pull changes from a remote branch Maintain local changes to that branch Pulling changes ...
toofarsideways's user avatar
0 votes
1 answer
53 views

Eclipse Git, Checkout Remote Branch as new Local Branch

When changing the branch in Eclipse with Team > Switch To > Other ... it shows Remote Tracking, there I select the branch I want to checkout. Usually this resulted in checking the branch out as ...
ddomnik's user avatar
  • 63
0 votes
1 answer
71 views

Is it safe to rebase remote branch if nobody based work on it? [duplicate]

I want push my personal local branch for code review with my peer. My peer doesn't will merge this branch. After code review, I want rebase my personal branch in master branch, and push master branch. ...
Alisson's user avatar
0 votes
1 answer
512 views

how do I switch to a remote branch in Xcode 15

I know how to switch to a local branch in Xcode 15 but how do I change to a remote one. the dropdown list doesn't show remote branches. Typing the branch name into the filter search bar doesn't help
SimonTheDiver's user avatar
0 votes
0 answers
42 views

list remote branches has commit within 30 days

I am trying to get list of remote branch which has commit within 30 days and sort them. git fetch # List remote branches containing the name "selva" branches=$(git branch -r) # Create an ...
Selvathalapathy S's user avatar
0 votes
1 answer
14 views

which branch is specified in these git push commands

what is the difference between : git push origin HEAD: <name-of-remote-branch> git push origin CURRENT_BRANCH_NAME Is CURRENT_BRANCH_NAME the name of my local branch or the remote branch ?
user3443063's user avatar
  • 1,573
0 votes
1 answer
39 views

listing and switching /checkout to remote branch error

git ls-remote origin lists all the remote with their commit IDs, xxxx41 refs/heads/ABC xxxx92 refs/heads/dummy_xyz xxxx32 refs/heads/Feature/ABC xxxx77 refs/heads/Feature/ABC-mgc now when i ...
cloudcop's user avatar
  • 1,027
0 votes
0 answers
223 views

git rebase remote branches

my project uses a (remote) master branch and plenty of (remote) feature branches. I usually start my work either on an existing (remote) feature branch or I create one. The real work is done locally ...
stacky67's user avatar
0 votes
2 answers
850 views

Delete unreferenced remote branches

Jii I have been learning git and how to use remote branches on GitHub. I had a remote branch origin/other-branch and merged to update the branches, so when I put git log --oneline --graph --all I get ...
Márquez's user avatar
  • 101
0 votes
1 answer
800 views

Git know the list of branches before cloning

Is there a way to know the list of branches a repository has before cloning? I tried the following command, but it doesn't seem to work for me: git ls-remote [email protected]:Username/project.git Edit ...
Paul's user avatar
  • 4,302
0 votes
1 answer
831 views

Can't push to remote branch after rebase with master?

So I have used git rebase origin/main on my branch - but I want to push these changes to my remote branch. However, whenever I try to use git push -f origin name_of_branch I get the following: ...
lameprogrammer01's user avatar
0 votes
0 answers
39 views

Restore remote branch to previous commit [duplicate]

By mistake I did few wrong commits. Now I want to restore my develop branch to a perticular commit-ID. I tried $git reset --hard 9f3df1996f435907575acafe922b22b88e6f10c4 HEAD is now at 9f3df19 Merge ...
AWS_Beginner's user avatar
3 votes
2 answers
1k views

SourceTree git "clone from url" gives me fatal error

I tried to add a new repository with the option "clone from url". It start the download but, almost immediately, it stops. I cannot see the old branches, it's like a new one. After some time, gives me ...
redYmir's user avatar
  • 113
-1 votes
1 answer
52 views

How to acces and commit to remote branch on github

I wanted to work on remote github repository from multiple machines, on my laptop it works as intended, however on my PC i can't connect my local branch to remote branch. Maybe they are connected but, ...
Veljkoza's user avatar
0 votes
0 answers
84 views

Git cannot fetch remote branch [duplicate]

I am attempting to run the command git checkout -b feature origin/feature I have a repository I've cloned down with the below lines with help from this question: (Git Clone is too slow) $ git clone -...
FancyPants's user avatar
1 vote
1 answer
2k views

Git push again the same commit to remote

My project has a remote and local synchronized repository. I did locally new branch -> than committed and pushed to the remote. Next, I have unaware deleted remote branch - operation is impossible to ...
pawchi's user avatar
  • 111
2 votes
1 answer
377 views

Why does deleting a remote branch by name produce an error while deleting by ref does not?

When I try to delete a non-existent remote Git branch by name, I expectedly get an error: $ git push origin --delete non/existent error: unable to delete 'non/existent': remote ref does not exist ...
Eugene Yarmash's user avatar
24 votes
5 answers
12k views

Error pushing changes on GIT. Ref names must follow git ref-format rules

I have one error using git on Sourcetree. I've created a local branch called sprints/Mycompany_sprint_1 (because I want it in a category) and then I did multiple cherry picks to this branch from ...
Inazense's user avatar
  • 1,637
1 vote
1 answer
389 views

Git: create fork of project after having worked on a clone of that project

I am currently working on a project in which I have the reporter rights (not allowed to push etc.). Unfortunately I did not create a fork, but cloned the original one on my machine and now I am ...
bdskfsdk321dsad3's user avatar
4 votes
1 answer
5k views

How to delete the remote Git branch via the Command Palette(Ctrl+Shift+P) in Visual Studio Code?

I want to delete the remote branch in Visual Studio Code but it seems like it's not supported. GitLens supports Delete Branch (via Terminal) but I want to do it from the Command Palette. I tried ...
Thu San's user avatar
  • 1,494
0 votes
1 answer
126 views

How to restore the deleted remote gerrit branch

We are using Git & Gerrit, Couple of months back our Ex. Colleague (He was an Gerrit Admin) who had deleted a remote gerrit project branch. Now I have request to restore the deleted remote branch. ...
user4948798's user avatar
  • 2,024
1 vote
1 answer
110 views

How do I avoid duplicate commits when pulling changed remote branches in Bitbucket?

If I have a branch with a number of commits, push it to the server, and create a PR in Bitbucket for it, chances are that these commits get changed remotely. For example, someone might click the "...
Felix Dombek's user avatar
  • 14.1k
1 vote
1 answer
1k views

Correct way to update git superproject

Scenario: We have recently started using a superproject in our team but seem to keep ending up having different versions of our superproject. We are all working on 1 branch of the project (but ...
j1849277's user avatar
2 votes
1 answer
2k views

How to compare local master with remote master in Git?

I have made few changes in my remote code on github.com. Now, I need to compare my local master branch with origin. I am using below command to get the diff, but I don't see the diff on the terminal. ...
Vik's user avatar
  • 59
0 votes
1 answer
3k views

Local Branches Not On Remote Branch

I have a project that needs to diverge into 3 different branches. Those branches will never be merged anymore (though certain fixes might have to be applied to all 3 branches). In the image below "...
Hu F.'s user avatar
  • 33
0 votes
1 answer
1k views

Delete remote branch in SAP Web IDE [closed]

I created a remote Branch but with the wrong name and now I want to delete the remote branch. The problem is I don't now how because if I right-click one the Project->Git there is only an option to ...
DarkPlaymo's user avatar
37 votes
3 answers
28k views

Refresh remote Git branches in Android studio

There is a new branch in the remote repository, but it does not appear in the git branches in android studio. How can I refresh that list to show the new branch? I have tried git branch -r but new ...
Firzan Shaikh's user avatar
5 votes
1 answer
16k views

Bitbucket does not show all branches

I have a repository on bitbucket that contains three branches. I'm able to list the remote branches using a good old git branch --remote command, and everything works perfectly. However, when I visit ...
kmos.w's user avatar
  • 432
1 vote
1 answer
35 views

Why do I have to push a new branch?

Initially, I mistakenly checkout the wrong branch of a project using git. I thought this was an easy fix, but I think I checked out the correct remote branch to new local branch. Oops. Now when I try ...
InformationEntropy's user avatar
0 votes
1 answer
82 views

Different remote name GIT, fetch using GUI

At work we have a problem using GIT GUI for bitbucket. I have a project on Bitbucket named TestProject, a remote named bitbucket for local repo, so when I push to remote I have a remote branch called ...
Marcx's user avatar
  • 6,816
2 votes
2 answers
3k views

how to push all files in a folder to all git branches

I have a lot git branches. There's a directory/folder in which I keep apk files. But whenever I add a apk/file and push it (1. git add, 2. git commit -m "", 3. git push), It gets pushed to the ...
Shirish Herwade's user avatar
2 votes
2 answers
1k views

List all remote branches that are behind master

I have a garbage of feature branch in central repository apart from master. My master is up to date. Now, I want to know the list of branches that are lagging behind my master branch. I know ...
LVR's user avatar
  • 21
0 votes
1 answer
928 views

How to start working off a remote branch, Github

I am new to Github and i have a question that i have been trying to find an answer. Say i have three repositories, Origin, Repo1 (my repo - forked from Origin), Repo2 (my colleague's repo forked from ...
user2070333's user avatar
286 votes
34 answers
364k views

Can't push to remote branch, cannot be resolved to branch

I migrated my repos from Bitbucket or Github. I don't think this matters but it's the only thing different. For a little while, I had two remotes set up: origin: bitbucket github: github Then I ...
jleach's user avatar
  • 7,662
4 votes
3 answers
4k views

Delete large number of branches from remote

I have a Git remote that has 1000 branches, and I want to delete all the branches whose name does not start with foo_. Is there an easy way to do that?
Ram Rachum's user avatar
2 votes
2 answers
1k views

Usage of updating a remote-tracking branch by a local branch

I know it is possible to create, update or delete a remote-tracking branch by content of a local branch of current repository. For example: $ git push . :refs/remotes/origin/master Which deletes ...
hasanghaforian's user avatar
4 votes
2 answers
1k views

dotfile management for different machines with git branches reasonable?

I set myself up a dotfiles repo, hosted on a remote server and used on different machines. For some things I'd like to have individual configurations, e.g. the environment variables differ between ...
j. doe's user avatar
  • 41
5 votes
2 answers
4k views

Git tracking branches

I have created a repository in local and pushed all the changes to the github. Later i have created a new branch("git branch v2") called "v2" and did some modification and pushed that branch to github ...
Mayuran's user avatar
  • 708
892 votes
5 answers
695k views

When does Git refresh the list of remote branches?

Using git branch --all shows all remote and local branches. When does Git refresh this list? On pull/push? And how do I refresh it using Git Bash?
BendEg's user avatar
  • 20.8k
0 votes
1 answer
63 views

Swith remote branches in git

Say I have two remote git branches, A and B. I want branch A to contain the contents of branch B and later remove B, so that only branch A remains with B's original contents. Unfortunately, the ...
Nathaniel Bubis's user avatar
1 vote
2 answers
999 views

How to add fork as branch?

There are a lot of forks of Caffe, for example MS have their own Caffe fork. What I want to do is to compare some fork to master branch of original Caffe. I know that using git I can compare 2 ...
mrgloom's user avatar
  • 21.1k
4 votes
3 answers
4k views

Doesn't show all remote branchs with git branch -r

when I execute the command: git branch -r, it's show just: origin/HEAD -> origin/master origin/development-elton origin/master And when execute the command: git remote show origin, it's ...
Elton Santos's user avatar
2 votes
1 answer
1k views

Removing remote Git branch using JGit

I am trying to remove a remote branch called test. I don't get any errors while running this code but the remote branch is not getting removed. 'ans' is the destination including the branch id. ...
user2775042's user avatar
0 votes
1 answer
276 views

Push entire remote git repository to another remote

I've forked my project off the wrong project (I forked a fork) and I want to reset my GitHub repository to be forked off of the original. Moving a fork in GitHub involves dropping and reforking AFAIK....
lanierhall's user avatar
5 votes
3 answers
4k views

How to show connections between local and remote branches in git?

I'd like to add a copy of a remote branch (origin/featureX) to my local repository. Therefore I generated a local branch featureX and set it to track the given remote branch: git branch featureX git ...
Edward's user avatar
  • 4,583
10 votes
4 answers
5k views

When is it safe to delete local branch?

The situation is like this: I created remote branch from other remote develop branch -> fetched it to local -> made some changes -> git add -> git commit -> pushed to remote and made pull request. ...
Phar0x's user avatar
  • 147
2 votes
1 answer
3k views

how to merge two more remote branches directly in git?

I tried to search this question, but none of them answered my question. Please let me give an example: I get two branches in the git server origin/master origin/feature Branch 'feature' is branched ...
yang yu's user avatar
  • 21
42 votes
2 answers
12k views

How do I use Git's interactive rebase with a local-only repository (no remote / origin)?

I use git as a local source control system mostly for history and diff tracking. I still want to use rebase to do fixup / squash on WIP commits that I will make periodically. When I try to do git ...
mcw's user avatar
  • 3,576
1 vote
1 answer
49 views

How to automatically remove remote-tracking branch when the corresponding local branch is removed using git

The current setup: $ git branch -a * master feature remotes/origin/master remotes/origin/feature After feature branch is merged, I would like to remove local branch feature and remote-tracking ...
Albert Netymk's user avatar
8 votes
1 answer
2k views

What happens if I git delete a remote branch that has subbranch that has not been merged to it

I'm getting rid of the development (in purple) branch and having all subbranches branch from master (in teal) and merge to master. development branch is branched from master. If there are sub branches ...
claya's user avatar
  • 1,970