pushing a new formula
- From:
- Byron Weber Becker
- Date:
- 2011-09-09 @ 15:30
I'm having trouble contributing a new formula. I'm new to git
and it's giving me problems.
I followed the sequence of operations on the cookbook page
and got through the creation of the formula, committing the
results, and forking homebrew on github.
However, the next step fails:
>git push git@github.com:bwbecker/homebrew.git
To git@github.com:bwbecker/homebrew.git
! [rejected] master -> master (non-fast-forward)
error: failed to push some refs to 'git@github.com:bwbecker/homebrew.git'
To prevent you from losing history, non-fast-forward updates were rejected
Merge the remote changes (e.g. 'git pull') before pushing again. See the
'Note about fast-forwards' section of 'git push --help' for details.
Looking at 'git push --help' suggests doing a pull and then a push.
But the pull also fails:
>git pull git@github.com:bwbecker/homebrew.git
remote: Counting objects: 285, done.
remote: Compressing objects: 100% (163/163), done.
remote: Total 239 (delta 170), reused 137 (delta 69)
Receiving objects: 100% (239/239), 26.77 KiB, done.
Resolving deltas: 100% (170/170), completed with 39 local objects.
From github.com:bwbecker/homebrew
* branch HEAD -> FETCH_HEAD
error: Your local changes to the following files would be overwritten by merge:
Library/Contributions/manpages/brew.1.md
Library/Formula/aspell.rb
Library/Formula/avrdude.rb
Library/Formula/cairo.rb
Library/Formula/feh.rb
Library/Formula/gmp.rb
Library/Formula/gnu-prolog.rb
Library/Formula/haproxy.rb
Library/Formula/mongodb.rb
Library/Formula/pcre.rb
Library/Formula/scala.rb
Library/Formula/ssh-copy-id.rb
Library/Formula/wine.rb
Library/Homebrew/cmd/doctor.rb
Library/Homebrew/extend/ENV.rb
share/man/man1/brew.1
Please, commit your changes or stash them before you can merge.
Aborting
Suggestions?
Byron
---------------------------------------------------------
Byron Weber Becker Voice: 519-888-4567 x34661
School of Computer Science Fax: 519-885-1208
University of Waterloo Office: DC3105
Waterloo, ON N2L 3G1
Advising FAQ: http://www.cs.uwaterloo.ca/current/faq/index.shtml
Re: [homebrew] pushing a new formula
- From:
- Max Howell
- Date:
- 2011-09-09 @ 16:11
Force the push. I advise you to read up on what this will do before
you do it though.
> I'm having trouble contributing a new formula. I'm new to git
> and it's giving me problems.
>
> I followed the sequence of operations on the cookbook page
> and got through the creation of the formula, committing the
> results, and forking homebrew on github.
>
> However, the next step fails:
>> git push git@github.com:bwbecker/homebrew.git
> To git@github.com:bwbecker/homebrew.git
> ! [rejected] master -> master (non-fast-forward)
> error: failed to push some refs to 'git@github.com:bwbecker/homebrew.git'
> To prevent you from losing history, non-fast-forward updates were rejected
> Merge the remote changes (e.g. 'git pull') before pushing again. See the
> 'Note about fast-forwards' section of 'git push --help' for details.
>
> Looking at 'git push --help' suggests doing a pull and then a push.
> But the pull also fails:
>> git pull git@github.com:bwbecker/homebrew.git
> remote: Counting objects: 285, done.
> remote: Compressing objects: 100% (163/163), done.
> remote: Total 239 (delta 170), reused 137 (delta 69)
> Receiving objects: 100% (239/239), 26.77 KiB, done.
> Resolving deltas: 100% (170/170), completed with 39 local objects.
>> From github.com:bwbecker/homebrew
> * branch HEAD -> FETCH_HEAD
> error: Your local changes to the following files would be overwritten by merge:
> Library/Contributions/manpages/brew.1.md
> Library/Formula/aspell.rb
> Library/Formula/avrdude.rb
> Library/Formula/cairo.rb
> Library/Formula/feh.rb
> Library/Formula/gmp.rb
> Library/Formula/gnu-prolog.rb
> Library/Formula/haproxy.rb
> Library/Formula/mongodb.rb
> Library/Formula/pcre.rb
> Library/Formula/scala.rb
> Library/Formula/ssh-copy-id.rb
> Library/Formula/wine.rb
> Library/Homebrew/cmd/doctor.rb
> Library/Homebrew/extend/ENV.rb
> share/man/man1/brew.1
> Please, commit your changes or stash them before you can merge.
> Aborting
>
> Suggestions?
>
> Byron
>
> ---------------------------------------------------------
> Byron Weber Becker Voice: 519-888-4567 x34661
> School of Computer Science Fax: 519-885-1208
> University of Waterloo Office: DC3105
> Waterloo, ON N2L 3G1
>
> Advising FAQ: http://www.cs.uwaterloo.ca/current/faq/index.shtml
>