How I would do this
git checkout master git pull origin master git merge test git push origin master
If I have a local branch from a remote one, I don’t feel comfortable with merging other branches than this one with the remote. Also I would not push my changes, until I’m happy with what I want to push and also I wouldn’t push things at all, that are only for me and my local repository. In your description it seems, that test
is only for you? So no reason to publish it.
git always tries to respect yours and others changes, and so will --rebase
. I don’t think I can explain it appropriately, so have a look at the Git book – Rebasing or git-ready: Intro into rebasing for a little description. It’s a quite cool feature
Related Posts:
- Git merge hotfix branch into feature branch
- Move the most recent commit(s) to a new branch with Git
- Move the most recent commit(s) to a new branch with Git
- How do I copy a version of a single file from one Git branch to another?
- How to keep a branch synchronized/updated with master?
- How do I delete a Git branch locally and remotely?
- How do I delete a Git branch locally and remotely?
- How do I rename a local Git branch?
- Undo a Git merge that hasn’t been pushed yet
- How to remove local (untracked) files from the current Git working tree
- Abort a Git Merge
- Git fetch remote branch
- How do I clone a specific Git branch? [duplicate]
- Git fetch remote branch
- How do I push a new local branch to a remote Git repository and track it too?
- How do I push a new local branch to a remote Git repository and track it too?
- How do I push a new local branch to a remote Git repository and track it too?
- How to resolve merge conflicts in a Git repository
- How can I merge multiple commits onto another branch as a single squashed commit?
- How to get just one file from another branch?
- How can I merge multiple commits onto another branch as a single squashed commit?
- Update Git branches from master
- Create a branch in Git from another branch
- How do I rename both a Git local and remote branch name?
- Create Git branch with current changes
- The following untracked working tree files would be overwritten by merge, but I don’t care
- The following untracked working tree files would be overwritten by merge, but I don’t care
- How to get the current branch name in Git?
- How do you create a remote Git branch?
- How to copy commits from one branch to another?
- Make an existing Git branch track a remote branch?
- How do I call git diff on the same file between 2 different local branches?
- How to get the current branch name in Git?
- How do you create a remote Git branch?
- Git error on commit after merge – fatal: cannot do a partial commit during a merge
- Is there a “theirs” version of “git merge -s ours”?
- .gitignore and “The following untracked working tree files would be overwritten by checkout”
- Branch from a previous commit using Git
- The following untracked working tree files would be overwritten by merge, but I don’t care
- Not a valid object name: ‘master’
- .gitignore and “The following untracked working tree files would be overwritten by checkout”
- Is there a “theirs” version of “git merge -s ours”?
- Move existing, uncommitted work to a new branch in Git
- Delete branches in Bitbucket
- How do I push a local Git branch to master branch in the remote?
- Is it possible to pull just one file in Git?
- How to resolve git status “Unmerged paths:”?
- Resolve Git merge conflicts in favor of their changes during a pull
- Found a swap file by the name
- Is there a git-merge –dry-run option?
- Git pull – Please move or remove them before you can merge
- How do I run git log to see changes only for a specific branch?
- How to create a local branch from an existing remote branch?
- How to find which git branch I am on when my disk is mounted on other server
- How to create a new branch from a tag?
- What is git tag, How to create tags & How to checkout git remote tag(s)
- How can I switch to another branch in git?
- GitHub: Permission denied (publickey). fatal: Could not read from remote repository
- Updates were rejected because the tip of your current branch is behind its remote counterpart
- git stash apply version
- How do I list all remote branches in Git 1.7+?
- Updating a local repository with changes from a GitHub repository
- How do I remove a submodule?
- Ignoring directories in Git repositories on Windows
- How to find my GitHub username so that I can be found via the URL?
- How do I merge a branch into a master in github?
- github website publish cannot publish unborn HEAD
- How do I resolve git saying “Commit your changes or stash them before you can merge”?
- How do you stash an untracked file?
- Filename too long in Git for Windows
- git – pulling from specific branch
- GitHub: invalid username or password
- Why do I have to “git push –set-upstream origin
“? - Stash just a single file
- How do I provide a username and password when running “git clone [email protected]”?
- “*** Please tell me who you are.” when using SSH key
- master branch and ‘origin/master’ have diverged, how to ‘undiverge’ branches’?
- git pull from master into the development branch
- Clone A Private Repository (Github)
- How to create the branch from specific commit in different branch
- How to clone a specific Git tag
- Heroku: How to change a Git remote on Heroku
- Updates were rejected because the remote contains work that you do not have locally
- Undoing a ‘git push’
- What’s the significance of the “No newline at end of file” log?
- Git update submodules recursively
- Do a “git export” (like “svn export”)?
- How do I set up Eclipse/EGit with GitHub?
- Repository size limits for GitHub.com
- git push origin master does not work
- Git clone verbose output?
- Could not create work tree dir ‘example.com’.: Permission denied
- How to answer the git prompt in npm init for a local repo
- Git says “Automatic merge failed”, what does it mean?
- How to configure git bash command line completion?
- How to stop tracking and ignore changes to a file in Git?
- Pull latest stable release via git [closed]
- Why do the Roots theme CSS files not load (404)?
- Painless way to track remote Git repo for WordPress updates
- WordPress on git – need help with configuration