0.0.2 • Published 4 years ago

@dupy/move-package v0.0.2

Weekly downloads
-
License
ISC
Repository
gitlab
Last release
4 years ago

What is it ?

move-package is a command line is a command line interface who allow you to refactor our package.json and package-lock.json file.

This command line also copy the readme.md file. (The file is not refactored)

How to install it ?

The easier way it to install it via npm or yarn with the following command: npm install @dupy/move-package (or yarn install @dupy/move-package for yarn).

Options

Options keyDescriptionIs required ?
inputSet the entry directory to the dirname of the input package.json and package-lock.json files:heavy_check_mark:
outputSet the output directory:heavy_check_mark:
remove-scriptRemove the given scripts keys names (the name will be separate with ,):x:
with-readmeA boolean to copy the readme.md file or not. The default value is false.:x:

Understand with an example

I have got my package.json an my package-lock.json files into my current folder. I want to refactor my packages files into the dist folder, and then to publish the dist folder.

in this case, my root package.json file have the entrypoint ./dist/index.js. When I will run the move-package command, my ./dist/package.json will be factorised with to entrypoint ./index.js. (Same for the relative directory folders packages)

Here is a command to remove the publish and test scripts keys, and move the ./package.json, package-lock.json, readme.md files into the dist folder:

move-package --input=\"./\" --output=\"./dist\" --remove-script=\"publish,test\"

Incoming features

  • Adding test to manage this package
  • Export the command line tools library as a package
0.0.2

4 years ago

0.0.1

4 years ago