Lerna command extensions for Git Package Manager
Use git for sharing node package, which integrated with lerna (lerna.json)
npm i lerna-cli lerna-command-preset-gpm -D
{
packages: ['packages/*'],
extendCommands: ['lerna-command-preset-gpm'],
command: {},
gpm: {
'packages/shared-lib': {
branch: 'master',
url: 'git-url',
remote: 'origin',
checkout: 'commit-sha'
}
}
}
After executing lerna gpm-update
, the files are as following.
lerna.json
.gitignore # `/packages/shared-lib` will be appended here
packages/
shared-lib/
.git/
...
- lerna-command-gpm-alias - Alias GPM Package
- lerna-command-gpm-check - gpm check command
- lerna-command-gpm-import - import git repo like git submodule
- lerna-command-gpm-lock - gpm lock version command
- lerna-command-gpm-pull - gpm pull command
- lerna-command-gpm-push - gpm push command
- lerna-command-gpm-update - update git repo
- lerna-command-preset-gpm - gpm commands preset
- lerna-utils-git-command - Internal Package: Git Utils (eg. clone/fetch/pull/checkout/compare)
- lerna-utils-globs-command - Internal Package: GPM basic class for lerna command, with globs options, check remote version, concurrency.
- lerna-utils-gpm - Internal Package: GPM common utils
- Fork it!
- Create your new branch:
git checkout -b feature-new
orgit checkout -b fix-which-bug
- Start your magic work now
- Make sure npm test passes
- Commit your changes:
git commit -am 'feat: some description (close #123)'
orgit commit -am 'fix: some description (fix #123)'
- Push to the branch:
git push
- Submit a pull request :)
This library is written and maintained by imcuttle, imcuttle@163.com.
MIT - imcuttle 🐟