-
Notifications
You must be signed in to change notification settings - Fork 222
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #159 from webpack/d3viant0ne-changelog
Adds project changelog
- Loading branch information
Showing
4 changed files
with
146 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
<a name="1.7.0"></a> | ||
# [1.7.0](https://github.com/webpack/karma-webpack/compare/v1.6.0...v1.7.0) (2015-07-31) | ||
|
||
|
||
|
||
<a name="1.6.0"></a> | ||
# [1.6.0](https://github.com/webpack/karma-webpack/compare/v1.5.1...v1.6.0) (2015-07-14) | ||
|
||
|
||
### Bug Fixes | ||
|
||
* Drop karma as a peerDependency. ([84ce696](https://github.com/webpack/karma-webpack/commit/84ce696)) | ||
|
||
|
||
|
||
<a name="1.5.1"></a> | ||
## 1.5.1 (2015-05-04) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,40 @@ | ||
var fs = require('fs') | ||
var addStream = require('add-stream') | ||
var cl = require('conventional-changelog') | ||
|
||
const inStream = fs.createReadStream('CHANGELOG.md') | ||
const isForce = process.argv.indexOf('--force') !== -1 | ||
|
||
/** | ||
* Creates and prepends the changelog from the latest tag to head. | ||
* Passing the arg `--force` will rewrite the entire changelog. | ||
*/ | ||
|
||
inStream.on('error', function(err) { | ||
console.error(`Error: failed to read the previous changelog file. | ||
If this is the initial run, use the --force flag. ${err}`) | ||
process.exit(1) | ||
}) | ||
|
||
let config = { | ||
preset: 'angular', | ||
releaseCount: isForce ? 0 : 1 | ||
} | ||
|
||
const getOutputStream = () => { | ||
return fs.createWriteStream('CHANGELOG.md') | ||
} | ||
|
||
let stream = cl(config) | ||
.on('error', function(err) { | ||
console.error(`An error occurred while generating the changelog: ${err}`) | ||
}) | ||
.pipe(!isForce && addStream(inStream) || getOutputStream()) | ||
|
||
if (!isForce) { | ||
inStream.on('end', function() { | ||
stream.pipe(getOutputStream()) | ||
}) | ||
} | ||
|
||
/*eslint no-console: ["error", { allow: ["warn", "error"] }] */ |