sierra mojave mac instalar home high cask macos homebrew osx-elcapitan

macos - mojave - Homebrew ya no hará cerveza



instalar brew mac os (5)

OS X desordena los permisos con cada actualización.

Prueba esto:

sudo chown -R $(whoami) /usr/local/share/man/man1

y

sudo chown -R $(whoami) /usr/local/share/man

y asegúrese de que el usuario actual (el que se está ejecutando) tiene permiso para acceder a /usr/local .

En mi MacMini con El Capitan no puedo ejecutar brebaje más. Obtuve el siguiente error:

/usr/local/Library/Homebrew/config.rb:34:in `initialize'': no implicit conversion of nil into String (TypeError) from /usr/local/Library/Homebrew/config.rb:34:in `new'' from /usr/local/Library/Homebrew/config.rb:34:in `<top (required)>'' from /Library/Ruby/Site/2.0.0/rubygems/core_ext/kernel_require.rb:54:in `require'' from /Library/Ruby/Site/2.0.0/rubygems/core_ext/kernel_require.rb:54:in `require'' from /usr/local/Library/Homebrew/global.rb:18:in `<top (required)>'' from /Library/Ruby/Site/2.0.0/rubygems/core_ext/kernel_require.rb:54:in `require'' from /Library/Ruby/Site/2.0.0/rubygems/core_ext/kernel_require.rb:54:in `require'' from /usr/local/Library/brew.rb:10:in `<main>''

Los permisos de / usr / local son correctos.

El archivo config.rb, que no he cambiado se ve así:

def cache if ENV["HOMEBREW_CACHE"] Pathname.new(ENV["HOMEBREW_CACHE"]).expand_path else # we do this for historic reasons, however the cache *should* be the same # directory whichever user is used and whatever instance of brew is executed home_cache = Pathname.new("~/Library/Caches/Homebrew").expand_path if home_cache.directory? && home_cache.writable_real? home_cache else Pathname.new("/Library/Caches/Homebrew").extend Module.new { def mkpath unless exist? super chmod 0775 end end } end end end HOMEBREW_CACHE = cache undef cache # Where brews installed via URL are cached HOMEBREW_CACHE_FORMULA = HOMEBREW_CACHE+"Formula" unless defined? HOMEBREW_BREW_FILE HOMEBREW_BREW_FILE = ENV["HOMEBREW_BREW_FILE"] || which("brew").to_s end # Where we link under HOMEBREW_PREFIX = Pathname.new(ENV["HOMEBREW_PREFIX"]) # Where .git is found HOMEBREW_REPOSITORY = Pathname.new(ENV["HOMEBREW_REPOSITORY"]) HOMEBREW_LIBRARY = Pathname.new(ENV["HOMEBREW_LIBRARY"]) HOMEBREW_CONTRIB = HOMEBREW_REPOSITORY/"Library/Contributions" # Where we store built products HOMEBREW_CELLAR = Pathname.new(ENV["HOMEBREW_CELLAR"]) HOMEBREW_LOGS = Pathname.new(ENV["HOMEBREW_LOGS"] || "~/Library/Logs/Homebrew/").expand_path HOMEBREW_TEMP = Pathname.new(ENV.fetch("HOMEBREW_TEMP", "/tmp")) unless defined? HOMEBREW_LIBRARY_PATH HOMEBREW_LIBRARY_PATH = Pathname.new(__FILE__).realpath.parent.join("Homebrew") end HOMEBREW_LOAD_PATH = HOMEBREW_LIBRARY_PATH

El mismo error ocurre con brew, brew doctor, brew update, etc.

¿Alguna idea sobre que podría ir mal?




Tuve el mismo problema: parecía ser el resultado de una actualización de brew que no se pudo completar debido a problemas de permisos.

Primero reinicié el repositorio a la última cabeza:

cd /usr/local/bin git reset --hard HEAD

Entonces podría correr:

brew doctor

Que encontró problemas de permisos. Arreglar esos permisos según las instrucciones finalmente me permitió ejecutar:

brew update


Un poco sucio, pero acabo de desinstalar homebrew y reinstalado. ADVERTENCIA: Esto desinstalará todos los paquetes instalados.

$ ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/uninstall)" $ sudo chown -R $USER /usr/local/ $ ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"