https://github.com/karimsa/mono
Monorepo helper for JavaScript.
https://github.com/karimsa/mono
Last synced: about 1 year ago
JSON representation
Monorepo helper for JavaScript.
- Host: GitHub
- URL: https://github.com/karimsa/mono
- Owner: karimsa
- Created: 2019-07-06T08:05:13.000Z (almost 7 years ago)
- Default Branch: master
- Last Pushed: 2022-12-04T01:55:54.000Z (over 3 years ago)
- Last Synced: 2025-03-11T21:04:00.610Z (over 1 year ago)
- Language: Shell
- Homepage: https://npmjs.org/@karimsa/mono
- Size: 2.07 MB
- Stars: 0
- Watchers: 0
- Forks: 0
- Open Issues: 16
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# @karimsa/mono [](https://circleci.com/gh/karimsa/mono)
Monorepo helper for JavaScript.
## Usage
To get started, you don't have to do anything. As long as your project follows the typical JS monorepo structure of having projects under `packages/` - you should be good to go.
To run a cross-project `npm install`, simply do `npx @karimsa/mono` (you don't have to install this package, it should download quite fast with npx given that it has no dependencies & it is really small).
Here's some other things you can do:
- **Build all your packages:** `npx @karimsa/mono run build`
- **Run all tests**: `npx @karimsa/mono test`
- **Start all dev servers**: `npx @karimsa/mono start`
- **Link all libraries**: `npx @karimsa/mono link` (`install` will also run `link` after)
## `start`
The `start` command in `@karimsa/mono` is a bit different from the other commands. Most commands will simply run the correct commands in each project directory, but `start` will concurrently run `start` across all projects that support it. This means that you can run all your dev servers in parallel, since this is the typical use case for `start`.
## `link`
The `link` command will create require shortcuts in all repositories to all other packages. For instance, if you have the following directory structure:
```
packages
|--- a
|--- b
```
Then running `npx @karimsa/mono link` will make it so that you can `require('a')` inside of `b` and `require('b')` inside of `a`. The require links the module directly rather than making a copy so changes will always be reflected when you do a `require()`.
## License
Licensed under the MIT license.
Copyright © 2019-present Karim Alibhai. All rights reserved.