CoDep CLI
Copy your frontend dependencies directly into your assets.
Features
- Fast
- Creating non-existent output directories
- User-friendly reporting
Install
npm i -D codep-cli
Usage
codep <outDir> [options]
For local installation usage:
npx codep "assets/vendor" --exclude "jquery,modernizr"
Or via package.json
scripts:
{
"scripts": {
"vendor": "codep assets/vendor --exclude jquery,modernizr"
}
}
Then run npm run vendor
through your CLI.
Options
Please run npx codep --help
to see available options:
$ npx codep --help
Usage
$ codep <outDir> [options]
Examples
$ codep public/assets
$ codep public/assets --exclude jquery,modernizr
Options
-s, --source Specify the node_modules source path
-p, --pkg Specify the package.json path
-k, --keepDist Keep the dist folder to exist, if any.
If "true" the output will be "pkg/dist", default "false"
-e, --exclude Specify the name of the dependencies you don\'t want to copy, e.g. "bootstrap,modernizr"
-d, --devDependencies Should you need to grab devDependencies as well?
--ext Only copied files with the specified extension, e.g. "js,ts"
-o, --overwrite Do you want to overwrite existing dependencies in the <outDir>?
<outDir> Specify an output folder for all copied files
Related