A collection of development configs, published as an npm package.
Available configs
- prettier
Install the package (from NPM), for GitHub packages see GitHub Package
npm i @matthewroach/dev-config --save-dev
Reference the configuration in your package.json
file
{
"name": "the-big-project",
"version": "0.0.1",
"prettier": "@matthewroach/dev-config/prettier"
}
Version is handling with npm
and uses semver
Use the correct npm run version:{type}
command to bump the version
major
- Used for created a breaking change release - 1.0.0 -> 2.0.0minor
- Increase the minor version - 1.1.0 -> 1.2.0patch
- Small backwards compatible changes/bug fixes - 1.0.1 -> 1.0.2
To publish to NPM this is manual.
Publish happens with npm publish
command.
As the package is published to the GitHub packages it requires an .npmrc
file configured to the GitHub registry for the scope @matthewroach
and a personal GitHub access code
# .npmrc
@matthewroach:registry=https://npm.pkg.github.com/
//npm.pkg.github.com/:_authToken=${AUTH_TOKEN}
Install the package
npm i @matthewroach/dev-config --save-dev
Publishing happens automatically with GitHub actions when a new tag is create
Package is published to GitHub packages. This requires npm
configuration updates and an authToken
.
Publish happens with npm publish
command.
Before publishing a new version needs to be created. Not creating a new version with the npm run version:{type}
script will result in an error - 409 Conflict
# .npmrc
@matthewroach:registry=https://npm.pkg.github.com/
//npm.pkg.github.com/:_authToken=${AUTH_TOKEN}