1
0
mirror of https://github.com/kremalicious/gatsby-redirect-from.git synced 2024-12-22 17:23:24 +01:00

simplify release-it tasks, add changelog

This commit is contained in:
Matthias Kretschmann 2019-06-11 00:27:44 +02:00
parent 3f33f65430
commit 3ec4ccfb8e
Signed by: m
GPG Key ID: 606EEEF3C479A91F
2 changed files with 24 additions and 9 deletions

View File

@ -77,9 +77,9 @@ redirect_from:
Plugin does not require to be configured but some additional customization options are available:
| Option | Default | Description |
|---|---|---|
| query | `allMarkdownRemark` | Modify the query being used to get the frontmatter data. E.g. if you use MDX, set `allMdx` here. |
| Option | Default | Description |
| ------ | ------------------- | ------------------------------------------------------------------------------------------------ |
| query | `allMarkdownRemark` | Modify the query being used to get the frontmatter data. E.g. if you use MDX, set `allMdx` here. |
Add options to the plugins's configuration object in `gatsby-config.js` like so:
@ -107,8 +107,8 @@ npm run build
# publishing to npm & GitHub releases
# uses https://github.com/webpro/release-it
npm run release
npm run release-minor
npm run release-major
npm run release minor
npm run release major
```
## License

View File

@ -10,10 +10,9 @@
"build": "babel src --out-dir . --ignore __tests__",
"start": "babel -w src --out-dir . --ignore __tests__",
"test": "eslint ./src/**/*.js",
"release": "./node_modules/release-it/bin/release-it.js --src.tagName='v%s' --github.release --npm.publish --non-interactive",
"release-minor": "./node_modules/release-it/bin/release-it.js minor --src.tagName='v%s' --github.release --npm.publish --non-interactive",
"release-major": "./node_modules/release-it/bin/release-it.js major --src.tagName='v%s' --github.release --npm.publish --non-interactive",
"format": "prettier --write 'src/**/*.{js,jsx}'",
"release": "release-it --non-interactive",
"changelog": "auto-changelog -p",
"prepublishOnly": "cross-env NODE_ENV=production npm run build"
},
"browserslist": [
@ -24,6 +23,7 @@
"@babel/cli": "^7.4.4",
"@babel/core": "^7.4.5",
"@babel/preset-env": "^7.4.5",
"auto-changelog": "^1.13.0",
"chalk": "^2.4.2",
"cross-env": "^5.2.0",
"eslint": "^5.16.0",
@ -47,5 +47,20 @@
"gatsby",
"gatsby-plugin",
"redirect"
]
],
"release-it": {
"scripts": {
"beforeStart": "npm test",
"beforeStage": "npm run changelog"
},
"git": {
"tagName": "v${version}"
},
"github": {
"release": true
},
"npm": {
"publish": true
}
}
}