mirror of
https://github.com/Homebrew/brew.git
synced 2025-07-14 16:09:03 +08:00

Add a new `brew mcp-server` command for a Model Context Protocol (MCP) server for Homebrew. This integrates with AI/LLM tools like Claude, Claude Code and Cursor. It currently supports the calls needed/used by the MCP Inspector and Cursor (where I've tested it). It provides as `tools` the subcommands output by `brew help` but should be fairly straightforward to add more in future. It is implemented in a slightly strange way (a standalone Ruby command called from a shell command) as MCP servers need a faster startup time than a normal Homebrew Ruby command allows and fail if they don't get it. There are a few Ruby libraries available but, given how relatively simplistic the implementation is, it didn't feel worthwhile to use and vendor them.
130 lines
1.2 KiB
Plaintext
130 lines
1.2 KiB
Plaintext
--cache
|
|
--caskroom
|
|
--cellar
|
|
--config
|
|
--env
|
|
--prefix
|
|
--repo
|
|
--repository
|
|
--version
|
|
-S
|
|
-v
|
|
abv
|
|
alias
|
|
analytics
|
|
audit
|
|
autoremove
|
|
bottle
|
|
bump
|
|
bump-cask-pr
|
|
bump-formula-pr
|
|
bump-revision
|
|
bump-unversioned-casks
|
|
bundle
|
|
casks
|
|
cat
|
|
cleanup
|
|
command
|
|
commands
|
|
completions
|
|
config
|
|
contributions
|
|
create
|
|
debugger
|
|
deps
|
|
desc
|
|
determine-test-runners
|
|
developer
|
|
dispatch-build-bottle
|
|
docs
|
|
doctor
|
|
dr
|
|
edit
|
|
environment
|
|
extract
|
|
fetch
|
|
formula
|
|
formula-analytics
|
|
formulae
|
|
generate-analytics-api
|
|
generate-cask-api
|
|
generate-cask-ci-matrix
|
|
generate-formula-api
|
|
generate-man-completions
|
|
gist-logs
|
|
help
|
|
home
|
|
homepage
|
|
info
|
|
install
|
|
install-bundler-gems
|
|
irb
|
|
lc
|
|
leaves
|
|
link
|
|
linkage
|
|
list
|
|
livecheck
|
|
ln
|
|
log
|
|
ls
|
|
mcp-server
|
|
migrate
|
|
missing
|
|
nodenv-sync
|
|
options
|
|
outdated
|
|
pin
|
|
post_install
|
|
postinstall
|
|
pr-automerge
|
|
pr-publish
|
|
pr-pull
|
|
pr-upload
|
|
prof
|
|
pyenv-sync
|
|
rbenv-sync
|
|
readall
|
|
reinstall
|
|
release
|
|
remove
|
|
rm
|
|
rubocop
|
|
ruby
|
|
rubydoc
|
|
search
|
|
services
|
|
setup-ruby
|
|
sh
|
|
shellenv
|
|
style
|
|
tab
|
|
tap
|
|
tap-info
|
|
tap-new
|
|
tc
|
|
test
|
|
tests
|
|
typecheck
|
|
unalias
|
|
unbottled
|
|
uninstall
|
|
unlink
|
|
unpack
|
|
unpin
|
|
untap
|
|
up
|
|
update
|
|
update-if-needed
|
|
update-license-data
|
|
update-maintainers
|
|
update-python-resources
|
|
update-reset
|
|
update-sponsors
|
|
update-test
|
|
upgrade
|
|
uses
|
|
vendor-gems
|
|
vendor-install
|
|
verify
|