arvis-linker

0.5.1 • Public • Published

arvis-linker

CodeFactor Known Vulnerabilities NPM download total NPM version MIT license PR's Welcome GitHub issues

Make your Arvis extensions installable from npm

This lib is inspired and cloned from alfred-link

Install

$ npm i arvis-linker

Hot it works

arvis-linker creates symlink pointing global node_modules folder's extension directory.

and also if there is user config of that extension, apply user config.

and when uninstall the extension, remove all broken symlinks.

Usage

Add the arvis-link command as postinstall script of your Arvis extension package and add arvis-unlink as preuninstall script to clean up the resources when the extension gets uninstalled.

{
  "name": "arvis-extension",
  "scripts": {
    "postinstall": "arvis-link",
    "preuninstall": "arvis-unlink"
  }
}

You can now install the arvis-extension package like this

$ npm install -g arvis-extension

This will creates a arvis-extension symlink inside the Arvis's directory that points to the location of the arvis-extension module.

Development

When developing an Arvis extension, you can call arvis-link directly from your cli. Use npx to call the local installation of arvis-link and arvis-unlink.

$ npx arvis-link

To remove the symlink afterwards, you can call arvis-unlink.

$ npx arvis-unlink

This command removes all broken symlinks in extension folder.

Related

  • arvish - Arvis workflow, plugin creator tools

Package Sidebar

Install

npm i arvis-linker

Weekly Downloads

3

Version

0.5.1

License

MIT

Unpacked Size

21.7 kB

Total Files

21

Last publish

Collaborators

  • jopemachine