npm-autolink

1.0.0 • Public • Published

npm-autolink

Npm link done right

Npm Npm dependencies Linux Build Windows Build Coverage

Description

When developping multiple node modules it is cumbersome to publish one module to test it in other modules. Npm link is handy in these cases but can be a bit slow (everything is installed globally) and doesn't cover everything.

Npm-autolink come to the rescue by permitting direct links between dev folders.

Main features are :

  • Define your workspace modules links in autolink.json file.
  • Automatically link or unlink all projects at once
  • bin executables are also linked !

Breaking change in v1

V1 of npm-autolink works very differently than v0 :

  • only one conf file is loaded autolink.json
  • you can link and unlink many projects at the same time

Tests are coming ...

Installation

npm install -g npm-autolink

autolink.json file

  • describe linked projects in your workspace
  • npm link will only link those projects

Example autolink.json file:

{
  "link": {
    "@iamasoft/project1": ["@iamasoft/lib1"],
    "@iamasoft/lib1": ["@iamasoft/lib2"],
  }
}

Note : node_modules and bower_components folders are never scanned.

Usage

npmauto [command] [options]

Print usage information

$ npmauto -h
$ npmauto --help

List all detected packages in workspace and their states

$ npmauto ls

Link all

$ npmauto link

Unkink all

$ npmauto unlink

/npm-autolink/

    Package Sidebar

    Install

    npm i npm-autolink

    Weekly Downloads

    13

    Version

    1.0.0

    License

    MIT

    Unpacked Size

    18.4 kB

    Total Files

    10

    Last publish

    Collaborators

    • adogor