I've created monor, which is an interactive monorepo command executor. It filters all commands under Yarn Workspaces and executes them concurrently.
https://github.com/acro5piano/monor
What is monorepo?
Monorepo is a common pattern to management multiple packages.
The key concept is to include all related code into one repository other than split into multiple repositories. In monorepo project, each package can refer to each other which enables to sync packages version and dependencies.
A lot of open source projects, including React/Vue/Babel ...etc, use this pattern nowadays to manage their huge codebases.
What is Yarn Workspace?
Yarn Workspace is a simple tool to manage monorepo. It is built-in feature of Yarn so if you use Yarn it means you can use Yarn Workspace out of the box.
For more information, please take a look at:
https://yarnpkg.com/lang/en/docs/workspaces/
Why monor?
Every time I run Yarn Workspaces commands, we have to type yarn workspace @myapp/package start
, which is a kind of hard work.
With monor
, you can select your workspaces command interactively.
Getting started
Install it globally:
npm -g install monor
Then just run monor
to list all of your commands under your workspaces:
monor
Features
- Read all
scripts
package.json under yarn workspaces' packages - List and execute commands interactively
- Run multiple commands concurrently
Development Status
Still in Beta. If you have any suggestions or feature requests, feel free to open new issues or Pull Requests!
Please run the following commands after you clone it:
yarn install
yarn example
yarn test:unit
yarn test:e2e
Top comments (0)