Yarn berry

Yarn 的活跃开发主干。快速、可靠、安全的依赖性管理。「📦🐈 Active development trunk for Yarn ⚒. Fast, reliable, and secure dependency management.」

Github星跟蹤圖


Yarn is a modern package manager split into various packages. Its novel architecture allows to do things currently impossible with existing solutions:

  • Yarn supports plugins; adding a plugin is as simple as adding it into your repository
  • Yarn supports Node by default but isn't limited to it - plugins can add support for other languages
  • Yarn supports workspaces natively, and its CLI takes advantage of that
  • Yarn uses a portable shell to execute package scripts, guaranteeing they work the same way on Windows and Linux
  • Yarn is first and foremost a Node API that can be used programmatically (via @yarnpkg/core)
  • Yarn is written in TypeScript, and is fully type checked

Install

Consult the dedicated page for more details.

Documentation

The documentation is being reworked to contain an updated content and a refreshed design, and the most up-to-date version can be found on the repository GitHub pages: yarnpkg.com

Current status

On top of our classic integration tests, we also run Yarn every day against the latest versions of the toolchains used by our community - just in case, really. Everything should be green!













Build your own bundle

Clone this repository, then run the following commands:

yarn build:cli

How it works

After building the CLI your global yarn will immediately start to reflect your local changes. This is because Yarn will pick up the yarnPath settings in this repository's .yarnrc.yml, which is configured to use the newly built CLI if available.

Works out of the box!

Note that no other command is needed! Given that our dependencies are checked-in within the repository (within the .yarn/cache directory), you don't even need to run yarn install. Everything just works right after cloning the project, and is guaranteed to continue to work ten years from now ?

Yarn plugins

Default plugins

Those plugins typically come bundled with Yarn. You don't need to do anything special to use them.

Contrib plugins

Although developed on the same repository as Yarn itself, those plugins are optional and need to be explicitly installed through yarn plugin import @yarnpkg/<plugin-name>.

Third-party plugins

Plugins can be developed by third-party entities. To use them within your applications, just specify the full plugin URL when calling yarn plugin import. Note that plugins aren't fetched from the npm registry at this time - they must be distributed as a single JavaScript file.

Creating a new plugin

To create your own plugin, please refer to the documentation.

Generic packages

The following packages are generic and can be used in a variety of purposes (including to implement other package managers, but not only):

Yarn packages

The following packages are meant to be used by Yarn itself, and probably won't be useful to other applications:

主要指標

概覽
名稱與所有者yarnpkg/berry
主編程語言TypeScript
編程語言JavaScript (語言數: 10)
平台Linux, Mac, Windows
許可證BSD 2-Clause "Simplified" License
所有者活动
創建於2018-09-10 22:49:22
推送於2025-06-30 11:39:14
最后一次提交2025-06-30 13:39:07
發布數4890
最新版本名稱2025-06-03 (發布於 2025-06-03 20:25:24)
第一版名稱2019-08-16 (發布於 )
用户参与
星數7.8k
關注者數82
派生數1.2k
提交數3.7k
已啟用問題?
問題數3153
打開的問題數738
拉請求數2453
打開的拉請求數141
關閉的拉請求數300
项目设置
已啟用Wiki?
已存檔?
是復刻?
已鎖定?
是鏡像?
是私有?