1.0.12 • Published 5 years ago
@hnp/package-scripts v1.0.12
@hnp/package-scripts

Package Maintenance Scripts
Table of contents
Installation
npm install @hnp/package-scripts --save-devUsage
This tool is meant to be used as part of the npm package scripts in your package.json.
compile
Updates the project files.
Normalizes
package.json.- Uses normalize-package-data for basic normalization.
- Ensures the
git-remotematches thegit.urlfield. - Sets the
git.urlas theSSHversion. Usefull on CI and Deployments - Formats the
authorfield as the single line form.name <email> (homepage) - Updates the
contributorsfield using thegit historyand theGitHub API - Ensures a valid
licencefield. - Cleans the results of empty fields and saves a new
package.json
Updates the
README.mdTrying its best to make it standard-readme compilant- Matches the Title to the package name
- Matches the description to the package description
- Updates
## Table of contents. - Updates
## Installation.- If the
package.jsonfieldprivateistrueit will begit clone && npm install - If the
package.jsonfieldpreferGlobalistrueit will benpm install -g - If the
package.jsonfieldpreferDevistrueit will benpm install -D - If none of those rules matches it will be
npm install --save
- If the
- Updates
## Usageby executing the contents ofexample.jsorexamples/index.jsas acode block.\\ Commentsare converted toparagraphsconsole.log()statements are replaced by what the console prints.
- Updates
## Maintainersusing theAUTHORSfile. - Links
## Changelogto theCHANGELOG.mdfile. - Links
## Licenceto theLICENCEfile. - Scans the resulting document and creates links to repositories, pull requests, issues etc.
Updates the
AUTHORSfile.Updates the
LICENCEfile using @hnp/license-generatorUpdates the
TODO.mdfile using leasot- Opt out by using the
--no-todosflag. - Uses the closest
.gitignoreto figure it out which files scan fot TODOs
- Opt out by using the
Stages the changed files. Making it useful as a pre-commit hook
todos
If the tool is already going to install leasot at least should expose it.
- Uses the closest
.gitignoreto figure it out which files scan for TODOs
version
A thin wrapper over standard-version for convenience.
- It will run
package-scripts compileas apost-version-bump hookto keep everything up to date. You can override this hook with--post-bump=${yourcommand} - If no
CHANGELOG.mdfile is found, it will create one as afirst-releasewithout bumping the version.
Changelog
Find the CHANGELOG here, generated using Conventional Commits.