remote-branch

Refresh remote Git branches in Android studio

不打扰是莪最后的温柔 提交于 2019-12-03 04:38:40
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 branch is not showing in the list. In your Android Studio menu bar, click on VCS > Git > Fetch Check the image: You can try using VCS (from menu) then click on Git and then on Fetch . Alternatively, you can use git fetch --all Try using git fetch or use git fetch --all 来源: https://stackoverflow.com/questions/47362422/refresh-remote-git-branches-in-android-studio

Can't push local changes to an existing remote branch

痞子三分冷 提交于 2019-12-03 00:30:43
There is a remote branch called "my-remote" that I had previously pushed to with no problem. As of today, I can't push and I get different errors. First error I got was: hint: Updates were rejected because a pushed branch tip is behind its remote hint: counterpart. If you did not intend to push that branch, you may want to hint: specify branches to push or set the 'push.default' configuration hint: variable to 'current' or 'upstream' to push only the current branch. I did some research and ran this hoping it would solve the problem: git config push.default tracking after running that I ran the

Git: Cannot see new remote branch

我们两清 提交于 2019-12-02 14:05:46
A colleague pushed a new remote branch to origin/dev/homepage and I cannot see it when I run: $ git branch -r I still see preexisting remote branches. I assume this is because my local remote refs are not up-to-date hence when I ran a git pull nothing happened since git pull only pulls on the current working branch correct? Unlike git push which pushes all branches that have changes to the corresponding remote branch? First, double check that the branch has been actually pushed remotely, by using the command git ls-remote origin . If the new branch appears in the output, try and give the

Git clone does not bring master branch

余生颓废 提交于 2019-12-01 04:18:46
I have a remote repository http://github.com/fernandezpablo85/Test This repo has a master branch, but it's behind two other branches so when I clone it I get this warining: warning: remote HEAD refers to nonexistent ref, unable to checkout. And also I don't get a local master branch ( git branch shows nothing). I can fix the whole thing doing: git checkout -b master origin/master But I was wondering why this happens? Is master supposed to be the more advanced branch? Or is there something else wrong with my repo? 1/ No, master is not necessary the most advanced branch. One can publish only to

When does Git refresh the list of remote branches?

我是研究僧i 提交于 2019-11-30 10:04:35
问题 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? 回答1: To update the local list of remote branches: git remote update origin --prune To show all local and remote branches that (local) Git knows about git branch -a 回答2: I believe that if you run git branch --all from Bash that the list of remote and local branches you see will reflect what your local Git "knows" about at the time you run the

How to share a git feature (or topic) branch with multiple developers

这一生的挚爱 提交于 2019-11-30 09:26:14
I'm following the the workflow described here , as I found many references pointing to this page as a good workflow. As mentioned in the article, "feature" branches are shared between developers, but do not go to the central repository. Let's say a developer "A" starts a new feature branch with git checkout -b newfeature develop . Now let's say that developer "B" needs also to work on this feature. This is my problem. What I did: developer "B" adds developer A's machine as a remote developer "B" runs git branch remoteA/newfeature developer "B" works on this branch, commit his work and pushes

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

|▌冷眼眸甩不掉的悲伤 提交于 2019-11-30 04:17:20
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 rebase -i though, I get the following: There is no tracking information for the current branch. Please specify which branch you want to rebase against. See git-rebase(1) for details git rebase <branch> If you wish to set tracking information for this branch you can do so with: git branch --set-upstream-to=<remote>/<branch> MyBranch It seems like git doesn't expect you to use interactive rebase without

How to remove remote origin/refs/heads/master

时间秒杀一切 提交于 2019-11-30 01:54:16
Don't ask me how but I managed to get accidentally the following remote branches in a git repository: $ git branch -r origin/HEAD -> origin/master origin/master origin/refs/heads/master All are pointing to the same commit. How can I remove the unnecessary listing for origin/refs/heads/master ? I tried to do the following $ git push origin :refs/heads/master error: dst refspec refs/heads/master matches more than one. But as shown, this gives an error. That's not actually a branch on the remote - it's just a local ref that claims to be representing something on the remote, just as origin/master

When does git refresh the list of remote branches?

删除回忆录丶 提交于 2019-11-29 18:31:35
Using git branch --all shows all remote and local branches. When does git refresh this list? On pull/push? And how to refresh it using git bash ? Thank you all a lot! centralcmd To show all local and remote branches that (local) git knows about git branch -a To update the local list of remote branches: git remote update origin --prune I believe that if you run git branch --all from the bash that the list of remote and local branches you see will reflect what your local Git "knows" about at the time you run the command. Because your Git is always up to date with regard to the local branches in

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

99封情书 提交于 2019-11-29 02:13:32
问题 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 rebase -i though, I get the following: There is no tracking information for the current branch. Please specify which branch you want to rebase against. See git-rebase(1) for details git rebase <branch> If you wish to set tracking information for this branch you can do so with: git branch --set