Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/davibe/package-deps-cli
A cli tool to list package.json dependencies in <package>@<version> form
https://github.com/davibe/package-deps-cli
Last synced: about 2 months ago
JSON representation
A cli tool to list package.json dependencies in <package>@<version> form
- Host: GitHub
- URL: https://github.com/davibe/package-deps-cli
- Owner: davibe
- Created: 2015-09-03T06:32:55.000Z (over 9 years ago)
- Default Branch: master
- Last Pushed: 2015-09-03T06:43:31.000Z (over 9 years ago)
- Last Synced: 2024-10-14T17:56:05.754Z (3 months ago)
- Language: JavaScript
- Size: 133 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
README
------A cli tool to list package.json dependencies in [package]@[version] form
Install
-------npm install -g package-deps-cli
Usage example
-------------$ package-deps-cli
yargs@^3.23.0$ package-deps-cli --dev
yargs@^3.23.0
coffee-script@^1.9.3Why
---I deploy my node.js based applications using docker. This tool allows me to install
dependencies globally which would not be possible using npm. The result looks
like thisRUN npm install -g package-deps
ADD ./package.json /app/package.json
RUN cd /app; npm install -g $(package-deps-cli); npm link $(package-deps-cli)
ADD ./ /app
RUN cd /app; npm installThe benefit is that when you change your app/ source code (but not package.json)
docker will repeat the steps starting from "ADD ./ /app" but it will be very fast
as it will just link global packages.Notes
------ Something similar can be achieved using 'npm-cache', but it's slower
- npm will never install dependencies globally afaik (see )