Skip to content

기본 레지스트리는 registry.npmjs.org 입니다. 이것은 bunfig.toml 에서 전역적으로 구성할 수 있습니다.

toml
[install]
# 문자열로 기본 레지스트리 설정
registry = "https://registry.npmjs.org"

# 필요한 경우 토큰 설정
registry = { url = "https://registry.npmjs.org", token = "123456" }

# 필요한 경우 사용자 이름/비밀번호 설정
registry = "https://usertitle:password@registry.npmjs.org"

bunfig.toml 은 환경 변수를 참조할 수 있습니다. Bun 은 .env.local, .env.[NODE_ENV], .env 에서 환경 변수를 자동으로 로드합니다. 자세한 내용은 문서 > 환경 변수 를 참조하세요.

toml
[install]
registry = { url = "https://registry.npmjs.org", token = "$npm_token" }

Bun 의 패키지 관리자에 대한 전체 문서는 문서 > 패키지 관리자 를 참조하세요.

Bun by www.bunjs.com.cn 편집