sync-local-deps

0.1.1 • Public • Published

sync-local-deps

Keep your local npm packages up-to-date with each other

Install

npm install -g sync-local-deps

Usage

sync-local-deps [root] [options]
 
Options:
  [root]               directory where projects are located, defaults to cwd()
  --dryrun, -D         don't make changes                       [default: false]
  --skip, -S           list of directories to skip         [array] [default: []]
  --skipPublish, -P    list of directories to not npm publish
                                                           [array] [default: []]
  --skipGitPush, -G    list of directories to not git push [array] [default: []]
  --ignoreDevDeps, -I  don't update dev deps                           [boolean]
  --updateAll, -a     include even those dependencies whose latest version
                       satisfies the declared semver dependency        [boolean]
  --npmVersion, -v     npm version to bump to, see "npm version --help"
                                                     [string] [default: "patch"]
  --only, -o           only sync the given projects, looks at cwd if empty
                                                                         [array]
  --help               Show help                                       [boolean]
  --version            Show version number                             [boolean]

sync-local-deps does the following:

  1. scans the given root directory for projects that depend on other projects in root
  2. build a dependency graph between projects so they're updated in the correct order
  3. for each project with out-of-date local dependencies:
    1. npm install --save dep1@latest dep2@latest ...
    2. git commit -am 'bump deps'
    3. npm version patch && npm publish
    4. git push

This process continues until every package has up-to-date local dependencies.

The output will looks something like this:

Readme

Keywords

Package Sidebar

Install

npm i sync-local-deps

Weekly Downloads

15

Version

0.1.1

License

none

Unpacked Size

432 kB

Total Files

8

Last publish

Collaborators

  • noahsug