webpack-plugin-release-manager
v1.0.1
Published
This plugin allows to notify different parties about new release being deployed, upload files to S3 with or without copies and report changelists
Readme
Webpack plugin for release management
Requirements
- Ability to upload files to S3 (done)
- For given file regexps it should be able to create copies with names given in options (done)
- It should be able to send notifications to given URLs with given method and parameters from options
- It should be able to parse release notes from README.md and submit them to hooks
Install and run
- Install package
yarn add webpack-plugin-release-manager - Configure it in your webpack config:
new ReleaseManager({
hooks : [
{
url: 'https://hooks.slack.com/services/TXXXXXXX/BXXXXXXXX/xxxxxxxxxxxxx',
method: 'POST',
body: {
text: "New release of awesome app: \n${releaseNotes}"
}
}
],
s3: {
accessKeyId: s3Config.key,
secretAccessKey: s3Config.secret,
region: s3Config.region,
bucket: s3Config.bucket,
basePath: 'staging/',
copy: [
{
test: /bundle-stateful-[a-f0-9]{20}\.js$/,
uploadAs: 'bundle-stateful-stable.js'
},
{
test: /bundle-stateful-[a-f0-9]{20}\.js.gz$/,
uploadAs: 'bundle-stateful-stable.js.gz'
},
]
},
releaseNotes: {
file: './RELEASE-NOTES.md',
separator: /==[^=]*/g,
order: 'downward'
}
})