Tan Kim

Homebrew (brew)

macOS / Linux용 패키지 매니저.

설치

/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"

주요 명령어

명령어 설명
brew install <패키지> 패키지 설치
brew uninstall <패키지> 패키지 제거
brew upgrade <패키지> 특정 패키지 업그레이드
brew upgrade 전체 업그레이드
brew update brew 자체 및 formulae 목록 업데이트
brew list 설치된 패키지 목록
brew search <키워드> 패키지 검색
brew info <패키지> 패키지 상세 정보
brew doctor 문제 진단
brew cleanup 구버전 캐시 정리

Formula vs Cask

Formula Cask
대상 CLI 도구, 라이브러리 GUI 앱 (macOS)
설치 brew install brew install --cask
예시 node, git, jq docker, vscode, iterm2

Brewfile

설치된 패키지를 파일로 관리.

brew bundle dump          # 현재 설치 목록을 Brewfile로 저장
brew bundle install       # Brewfile 기준으로 설치
brew bundle check         # 설치 여부 확인
# Brewfile 예시
brew "git"
brew "node"
brew "jq"
cask "docker"
cask "visual-studio-code"

메모