New Research: Supply Chain Attack on Axios Pulls Malicious Dependency from npm.Details →
Socket
Book a DemoSign in
Socket

modsyncr

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

modsyncr

Sychronises local modules without the need to keep bumping version numbers

latest
Source
npmnpm
Version
1.0.2
Version published
Weekly downloads
0
-100%
Maintainers
1
Weekly downloads
 
Created
Source

modsyncr

npm install modsyncr

modsyncr makes it easy to keep locally referenced node modules in sync without requiring a package version update. It is intended to help when working on large projects that need to be broken into seperate packages. With modsyncr you can locally reference packages e.g. require('mysharedpackage') without having to worry about managing paths or symbolic links.

Example app sturucture

mainApp // any file in mainApp can access utilApp by using require(utilApp)
  |--node_modules
      |--utilApp // file:../utilApp
      |--dataApp // file:../dataApp
libs
  |--utilApp // shared app referenced by mainApp
  |--dataApp // shared app referenced by mainApp

mainApp uses the modules utilApp and dataApp and all 3 apps are being developed at the same time. When the mainApp is run, any changes to the utilApp and dataApp will not appear in the node_modules folder of the mainApp

To force utilApp / dataApp to refresh you would either need to delete them from the mainApp node_modules folder and run npm install or bump up the version number of the utilApp/dataApp and run npm update on the mainApp

This is especially slow if there are other modules that require complication.

Modsyncr will analyse all the packages and find any locally referenced packages. It will then compare the packages and if the dependencies have changed then it will force a full update using npm update. If only files that make up the actual referenced package have changed then modsyncr will just copy the changed files over. This is extremely fast.

Modsyncr can be run as part of a grunt/gulp build routine or run from the command line

Code usage var modsyncr = require(‘modsyncr’); modsyncr.sync(function done(){ console.log(‘sync done!’); });

command line node modsyncr

global install npm install –g modsyncr

FAQs

Package last updated on 26 Nov 2015

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts