2013-04-15 10 views
5

Sto cercando di aggiornare il mio birra, quando ho creatoLion OS - torna aggiornamento birra "Errore durante l'esecuzione ..."

brew update

ottengo questo errore:

error: Your local changes to the following files would be overwritten by merge: 
    Library/Formula/imagemagick.rb 
Please, commit your changes or stash them before you can merge. 
Aborting 
Error: Failure while executing: git pull -q origin refs/heads/master:refs/remotes/origin/master 

o

error: The requested URL returned error: 403 while accessing https://github.com/mxcl/homebrew/info/refs 
fatal: HTTP request failed 
Error: Failure while executing: git pull -q origin refs/heads/master:refs/remotes/origin/master 

Qual è il problema con Git? Come aggiornare brew se in questo modo non funziona?

+0

Ragazzi, che cosa c'è di sbagliato con la domanda? – user984621

risposta

0

Il primo errore che si ottiene indica quanto segue: si ha un file Library/Formula/imagemagick.rb che è stato modificato nella propria directory di lavoro e tali modifiche non sono state confermate. Non è possibile avere modifiche senza commit quando si effettua un pull, che brew update esegue implicitamente. È necessario rispettare le istruzioni fornite nel testo dell'errore: Prima di preparare l'aggiornamento, commit tutti i file modificati, incluso imagemagick.rb.

13

Questo è causato da un vecchio bug nel codice update che è stato risolto da tempo. Tuttavia, la natura del bug che richiede di effettuare le seguenti:

cd $(brew --repository) 
git reset --hard FETCH_HEAD 

Se brew doctor ancora lamenta modifiche commit, eseguire anche questo comando:

cd $(brew --repository)  
git clean -fd 
Problemi correlati