MacOS12及以brew services 报错 uninitialized constant Homebrew::Service::System
作者: cheng 发布时间: 2023-05-13 浏览: 4106 次 编辑MacOS12及以brew services 报错 uninitialized constant Homebrew::Service::System
xiaocheng@imac ~ % brew services start redis Error: uninitialized constant Homebrew::Service::System /opt/homebrew/Library/Taps/homebrew/homebrew-services/cmd/services.rb:61:in `services' /opt/homebrew/Library/Homebrew/brew.rb:94:in `'
执行以下三条命令:
第一
cd /opt/homebrew/Library/Taps/homebrew
第二
rm -rf /opt/homebrew/Library/Taps/homebrew/homebrew-services
第三
brew tap homebrew/services
xiaocheng@imac ~ % cd /opt/homebrew/Library/Taps/homebrew xiaocheng@imac homebrew % ls homebrew-cask homebrew-core homebrew-services xiaocheng@imac homebrew % rm -rf /opt/homebrew/Library/Taps/homebrew/homebrew-services xiaocheng@imac homebrew % brew tap homebrew/services Running `brew update --auto-update`... ==> Auto-updated Homebrew! Updated 1 tap (homebrew/cask). ==> New Casks
好了,完美解决
xiaocheng@imac homebrew % brew services list Name Status User File redis none xiaocheng@imac homebrew % brew services start redis ==> Successfully started `redis` (label: homebrew.mxcl.redis)