Baggy is a reverse engineered NPM registry with a modular structure.
You can provide your own functionality for storing artifacts and metadata.
Baggy is not a production-ready registry. I have started this project for learning purposes and maybe at some point it can be used for specific setups. For now unit tests are missing as well as support for a few npm commands.
This Project is als not published on NPM yet.
- install/update/view
- publish
- unpublish
- audit (will proxy to the npm registry)
- ping
- dist-tag
- deprecate
- login
- whoami
- team
- token
- search
- stars
- star
- unstar
Clone the registry, then run one of those commands
yarn install
yarn serve
to start the express server with filestorageyarn serve-sqlite
to start the express server with sqlite storage
you can now run npm/yarn commands against http://localhost:3000
by setting the "registry" option
- Run
yarn install
to install dependencies - Run
yarn serve
to start express server - Open a separate Terminal
- Run
make test
to execute the test script which will execute a few commands like publish and install
Using ts-node
and nodemon
we can restart the server on any file changes that affect the server.
Files will be to the project root in .local
. If the directory does not exist, it will be created.
Code will be formatted on commit with pretty-quick
. Also there is yarn lint
Future Providers could be something like these:
- AWS DynamoDB for Metadata
- Other cloud providers
Login should probably not be implemented in the core project (@baggy/registry), but rather as a kind of middleware for express and other implementations