rembrembdocs

Skip to main content

Bun home pagelight logodark logo

[Runtime

](../../../index.md)[Package Manager

](../../../pm/cli/install/index.md)[Bundler

](../../../bundler/index.md)[Test Runner

](../../../test/index.md)[Guides

](../../index.md)[Reference

](https://bun.com/reference)[Blog

](https://bun.com/blog)[Feedback

](../../../feedback/index.md)

Bun supports directly adding GitHub repositories as dependencies of your project.

terminal

bun add github:lodash/lodash

This will add the following line to your package.json:

package.json

{
  "dependencies": {
    "lodash": "github:lodash/lodash"
  }
}

Bun supports a number of protocols for specifying Git dependencies.

terminal

bun add git+https://github.com/lodash/lodash.git
bun add git+ssh://github.com/lodash/lodash.git#4.17.21
bun add git@github.com:lodash/lodash.git
bun add github:colinhacks/zod

Note: GitHub dependencies download via HTTP tarball when possible for faster installation.


See Docs > Package manager for complete documentation of Bun’s package manager.

Was this page helpful?

Suggest editsRaise issue

[

Add a peer dependency

Previous

](../add-peer/index.md)[

Add a tarball dependency

Next

](../add-tarball/index.md)