Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add NPM task and docs for creating a release #346

Merged
merged 1 commit into from Jan 27, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion .nvmrc
@@ -1 +1 @@
13.6.0
18
12 changes: 12 additions & 0 deletions .release-it.json
@@ -0,0 +1,12 @@
{
"pkgFiles": ["package.json", "package-lock.json"],
"git": {
"requireCleanWorkingDir": false
},
"npm": {
"publish": false
},
"hooks": {
"after:bump": "auto-changelog --hide-credit --package"
}
}
8 changes: 8 additions & 0 deletions README.md
Expand Up @@ -373,6 +373,14 @@ npm install
npm test
```

# Creating a release

> Travis CI will automatically release the npm package to npmjs.com after a successful build.

```sh
npm run release
```

# FAQ

## Missing dependencies?
Expand Down
5 changes: 4 additions & 1 deletion package.json
Expand Up @@ -36,7 +36,8 @@
"generate": "npm run generate:small && npm run generate:madge",
"generate:small": "bin/cli.js --image /tmp/simple.svg test/cjs/circular/a.js",
"generate:madge": "bin/cli.js --image /tmp/madge.svg bin lib",
"test:output": "./test/output.sh"
"test:output": "./test/output.sh",
"release": "npm test && release-it"
},
"funding": {
"type": "individual",
Expand Down Expand Up @@ -68,9 +69,11 @@
},
"devDependencies": {
"@aptoma/eslint-config": "^7.0.1",
"auto-changelog": "^2.4.0",
"eslint": "^7.29.0",
"mocha": "^9.0.1",
"mz": "^2.7.0",
"release-it": "^15.6.0",
"should": "^13.2.3"
}
}