Skip to content

Update copyright year in Active Resource & Active Support #468

Closed
wants to merge 4 commits into from

3 participants

@vijaydev
Ruby on Rails member
vijaydev commented May 9, 2011

Update copyright year to include up to 2011 in Active Resource & Active Support.

@spastorino
Ruby on Rails member

Y U change the copyright to 2011 and then to 2006-2011 :P.
Please merge the commits in one.

@vijaydev
Ruby on Rails member
vijaydev commented May 9, 2011

It was the earlier commit! Will do.

@vijaydev
Ruby on Rails member
vijaydev commented May 9, 2011

I think since I'm still on master, me merging and pushing the changes will again bring in all the new commits as it did in the earlier request. Any tips to avoid that?

@guilleiguaran
Ruby on Rails member

Feature branches and git rebase are you friends :P

Some tips about branching and keeping a git fork updated:
http://blog.plataformatec.com.br/2011/04/a-successful-git-branching-model/
http://robots.thoughtbot.com/post/5133345960/keeping-a-git-fork-updated

You can use git-resolve to merge two commits :) http://www.kernel.org/pub/software/scm/git/docs/v1.4.4.4/git-resolve.html

@vijaydev
Ruby on Rails member
vijaydev commented May 9, 2011

Ah! I can't remove commits from a pull request??

@vijaydev
Ruby on Rails member
vijaydev commented May 9, 2011

@guilleiguaran Thanks for the help. But git resolve doesn't exist in my system! (git version 1.7.1). I squashed the two commits and pushed now. But I can't figure how to remove the old commits from the request.

@spastorino
Ruby on Rails member

@vijaydev push -f ?

@guilleiguaran
Ruby on Rails member

@vijaydev: Squash all the four commits:

$ git rebase -i HEAD~4

You will get in your editor something like that:

pick 3d0111b Merge branch 'master' of github.com:vijaydev/rails
pick b127c39 Update copyright year in Active Resource and Active Support
pick 87b0467 Update copyright year in Active Resource and Active Support
pick d7813e9 update copyright year to 2011  

Change the last three picks to squash:

pick 3d0111b Merge branch 'master' of github.com:vijaydev/rails
squash b127c39 Update copyright year in Active Resource and Active Support
squash 87b0467 Update copyright year in Active Resource and Active Support
squash d7813e9 update copyright year to 2011    

Save it and other editor will be open, you will need to specify the new commit message and save it. When rebase finish push changes as @spastorino says:

$ git push -f origin master
@spastorino
Ruby on Rails member

You're doing it wrong, you need to have the branch where you are doing the pull request just with one commit on top if you check here https://github.com/vijaydev/rails/commits/master you will see you have four.
Anyways I've already cherry-picked the one we need, thanks :).

@spastorino spastorino closed this May 9, 2011
@vijaydev
Ruby on Rails member

Thanks @spastorino and @guilleiguaran. I'm changing my workflow from now on to have separate branches.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.