Erik's blog

Code, notes, recipes, general musings

steps for merging changes from a remote clone of a git repo

leave a comment »

I’m a fan of github, but I don’t know how to apply changes made to a clone of my repo, usually announced via a pull request. The goal of this post, then, is to define these steps. Note: the steps below pulled in the changes as desired, but also auto-committed them despite the —no-commit flag, so these steps need refinement.

prereq

  • a git repo named origin
  • committer has issued a pull request. For this example, I’ll use a committer named FooBaz

steps

  1. add commiter’s repo as a remote
    • copy clone url for pull requester’s repo, eg git://github.com/FooBaz/yql-tables.git
    • define remote repo: git remote add FooBaz git://github.com/FooBaz/yql-tables.git
    • view list of remotes as sanity check: git remote show
  2. pull in FooBaz’s changes:
    • run: git pull --no-commit FooBaz master
    • note: this actually committed the changes for me 😐
  3. push changes to origin repo: git push origin master

ref

Advertisements

Written by Erik

December 24, 2009 at 11:43 am

Posted in tutorial

Tagged with ,

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: