chore(package): re-init package with commitizen and standard-release

This commit is contained in:
Pavel Pertsev
2018-05-16 12:54:46 +03:00
parent cb4e7a5643
commit eaf2328575
10640 changed files with 609660 additions and 117 deletions

126
node_modules/conventional-changelog-eslint/CHANGELOG.md generated vendored Normal file
View File

@@ -0,0 +1,126 @@
# Change Log
All notable changes to this project will be documented in this file.
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
<a name="1.0.9"></a>
## [1.0.9](https://github.com/conventional-changelog/conventional-changelog/compare/conventional-changelog-eslint@1.0.8...conventional-changelog-eslint@1.0.9) (2018-03-28)
### Bug Fixes
* revert previous change ([2f4530f](https://github.com/conventional-changelog/conventional-changelog/commit/2f4530f))
<a name="1.0.8"></a>
## [1.0.8](https://github.com/conventional-changelog/conventional-changelog/compare/conventional-changelog-eslint@1.0.7...conventional-changelog-eslint@1.0.8) (2018-03-27)
**Note:** Version bump only for package conventional-changelog-eslint
<a name="1.0.7"></a>
## [1.0.7](https://github.com/conventional-changelog/conventional-changelog/compare/conventional-changelog-eslint@1.0.6...conventional-changelog-eslint@1.0.7) (2018-03-27)
**Note:** Version bump only for package conventional-changelog-eslint
<a name="1.0.6"></a>
## [1.0.6](https://github.com/conventional-changelog/conventional-changelog/compare/conventional-changelog-eslint@1.0.5...conventional-changelog-eslint@1.0.6) (2018-03-22)
**Note:** Version bump only for package conventional-changelog-eslint
<a name="1.0.5"></a>
## [1.0.5](https://github.com/conventional-changelog/conventional-changelog/compare/conventional-changelog-eslint@1.0.4...conventional-changelog-eslint@1.0.5) (2018-03-03)
### Bug Fixes
* **preset:** recommended-bump ESLint preset ([#295](https://github.com/conventional-changelog/conventional-changelog/issues/295)) ([acf9c19](https://github.com/conventional-changelog/conventional-changelog/commit/acf9c19)), closes [#270](https://github.com/conventional-changelog/conventional-changelog/issues/270) [#241](https://github.com/conventional-changelog/conventional-changelog/issues/241)
<a name="1.0.4"></a>
## [1.0.4](https://github.com/conventional-changelog/conventional-changelog/compare/conventional-changelog-eslint@1.0.3...conventional-changelog-eslint@1.0.4) (2018-02-24)
**Note:** Version bump only for package conventional-changelog-eslint
<a name="1.0.3"></a>
## [1.0.3](https://github.com/conventional-changelog/conventional-changelog/compare/conventional-changelog-eslint@1.0.2...conventional-changelog-eslint@1.0.3) (2018-02-20)
**Note:** Version bump only for package conventional-changelog-eslint
<a name="1.0.2"></a>
## [1.0.2](https://github.com/stevemao/conventional-changelog-eslint/compare/conventional-changelog-eslint@1.0.1...conventional-changelog-eslint@1.0.2) (2018-02-13)
**Note:** Version bump only for package conventional-changelog-eslint
<a name="1.0.1"></a>
## [1.0.1](https://github.com/stevemao/conventional-changelog-eslint/compare/conventional-changelog-eslint@1.0.0...conventional-changelog-eslint@1.0.1) (2018-02-13)
**Note:** Version bump only for package conventional-changelog-eslint
<a name="1.0.0"></a>
# [1.0.0](https://github.com/stevemao/conventional-changelog-eslint/compare/conventional-changelog-eslint@0.3.0...conventional-changelog-eslint@1.0.0) (2018-01-29)
### Features
* **eslint:** improve regex headerPattern ([#268](https://github.com/stevemao/conventional-changelog-eslint/issues/268)) ([ccc1365](https://github.com/stevemao/conventional-changelog-eslint/commit/ccc1365))
### BREAKING CHANGES
* **eslint:** Trailing whitespaces at the beginning of commit messages
will not be saved anymore
<a name="0.3.0"></a>
# [0.3.0](https://github.com/stevemao/conventional-changelog-eslint/compare/conventional-changelog-eslint@0.2.1...conventional-changelog-eslint@0.3.0) (2017-12-18)
### Features
* **preset:** add recommended-bump opts into presets ([60815b5](https://github.com/stevemao/conventional-changelog-eslint/commit/60815b5)), closes [#241](https://github.com/stevemao/conventional-changelog-eslint/issues/241)
<a name="0.2.1"></a>
## [0.2.1](https://github.com/stevemao/conventional-changelog-eslint/compare/conventional-changelog-eslint@0.2.0...conventional-changelog-eslint@0.2.1) (2017-11-13)
**Note:** Version bump only for package conventional-changelog-eslint
<a name="0.2.0"></a>
# 0.2.0 (2017-07-17)
### Features
* migrate repo to lerna mono-repo ([793e823](https://github.com/stevemao/conventional-changelog-eslint/commit/793e823))

15
node_modules/conventional-changelog-eslint/LICENSE.md generated vendored Normal file
View File

@@ -0,0 +1,15 @@
### ISC License
Copyright © [conventional-changelog team](https://github.com/conventional-changelog)
Permission to use, copy, modify, and/or distribute this software for any
purpose with or without fee is hereby granted, provided that the above
copyright notice and this permission notice appear in all copies.
THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND
FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
PERFORMANCE OF THIS SOFTWARE.

51
node_modules/conventional-changelog-eslint/README.md generated vendored Normal file
View File

@@ -0,0 +1,51 @@
# [![NPM version][npm-image]][npm-url] [![Build Status][travis-image]][travis-url] [![Dependency Status][daviddm-image]][daviddm-url] [![Coverage Status][coveralls-image]][coveralls-url]
> [conventional-changelog](https://github.com/ajoslin/conventional-changelog) [eslint](https://github.com/eslint/eslint) preset
**Issues with the convention itself should be reported on the ESLint issue tracker.**
## ESLint Convention
Make the changes to the code and tests and then commit to your branch. Be sure to follow the commit message conventions.
Commit message summaries must follow this basic format:
```
Tag: Message (fixes #1234)
```
`Tag` should not be confused with git tag.
`Message` should not be confused with git commit message.
The `Tag` is one of the following:
* `Fix` - for a bug fix.
* `Update` - for a backwards-compatible enhancement.
* `Breaking` - for a backwards-incompatible enhancement.
* `Docs` - changes to documentation only.
* `Build` - changes to build process only.
* `New` - implemented a new feature.
* `Upgrade` - for a dependency upgrade.
The message summary should be a one-sentence description of the change. The issue number should be mentioned at the end. * The commit message should say "(fixes #1234)" at the end of the description if it closes out an existing issue (replace 1234 with the issue number). If the commit doesn't completely fix the issue, then use `(refs #1234)` instead of `(fixes #1234)`.
Here are some good commit message summary examples:
```
Build: Update Travis to only test Node 0.10 (refs #734)
Fix: Semi rule incorrectly flagging extra semicolon (fixes #840)
Upgrade: Esprima to 1.2, switch to using Esprima comment attachment (fixes #730)
```
The commit message format is important because these messages are used to create a changelog for each release. The tag and issue number help to create more consistent and useful changelogs.
Based on https://github.com/eslint/eslint.github.io/blob/master/docs/developer-guide/contributing.md#step-2-make-your-changes
[npm-image]: https://badge.fury.io/js/conventional-changelog-eslint.svg
[npm-url]: https://npmjs.org/package/conventional-changelog-eslint
[travis-image]: https://travis-ci.org/stevemao/conventional-changelog-eslint.svg?branch=master
[travis-url]: https://travis-ci.org/stevemao/conventional-changelog-eslint
[daviddm-image]: https://david-dm.org/stevemao/conventional-changelog-eslint.svg?theme=shields.io
[daviddm-url]: https://david-dm.org/stevemao/conventional-changelog-eslint
[coveralls-image]: https://coveralls.io/repos/stevemao/conventional-changelog-eslint/badge.svg
[coveralls-url]: https://coveralls.io/r/stevemao/conventional-changelog-eslint

View File

@@ -0,0 +1,10 @@
'use strict'
const Q = require(`q`)
const parserOpts = require(`./parser-opts`)
const writerOpts = require(`./writer-opts`)
module.exports = Q.all([parserOpts, writerOpts])
.spread((parserOpts, writerOpts) => {
return {parserOpts, writerOpts}
})

View File

@@ -0,0 +1,39 @@
'use strict'
module.exports = {
whatBump: commits => {
let level = 2
let breakings = 0
let features = 0
commits.forEach(commit => {
if (!commit.type) {
return
}
if (commit.type.toLowerCase() === 'breaking') {
breakings += 1
level = 0
} else if (commit.type.toLowerCase() === 'new') {
features += 1
if (level === 2) {
level = 1
}
}
})
return {
level: level,
reason: `There are ${breakings} breaking changes and ${features} features`
}
},
parserOpts: {
headerPattern: /^(\w*): (.*)$/,
headerCorrespondence: [
'type',
'subject'
],
revertPattern: /^[rR]evert:\s([\s\S]*?)\s*This reverts commit (\w*)\./,
revertCorrespondence: ['header', 'hash']
}
}

15
node_modules/conventional-changelog-eslint/index.js generated vendored Normal file
View File

@@ -0,0 +1,15 @@
'use strict'
const Q = require(`q`)
const conventionalChangelog = require(`./conventional-changelog`)
const parserOpts = require(`./parser-opts`)
const recommendedBumpOpts = require(`./conventional-recommended-bump`)
const writerOpts = require(`./writer-opts`)
module.exports = presetOpts
function presetOpts (cb) {
Q.all([conventionalChangelog, parserOpts, recommendedBumpOpts, writerOpts])
.spread((conventionalChangelog, parserOpts, recommendedBumpOpts, writerOpts) => {
cb(null, {conventionalChangelog, parserOpts, recommendedBumpOpts, writerOpts})
})
}

View File

@@ -0,0 +1,42 @@
{
"name": "conventional-changelog-eslint",
"version": "1.0.9",
"description": "conventional-changelog eslint preset",
"main": "index.js",
"scripts": {
"lint": "eslint --fix .",
"test": "mocha --timeout=30000 && npm run-script lint",
"test-windows": "echo 'make work on windows'"
},
"repository": {
"type": "git",
"url": "https://github.com/conventional-changelog/conventional-changelog.git"
},
"keywords": [
"conventional-changelog",
"eslint",
"preset"
],
"author": "Steve Mao",
"license": "ISC",
"files": [
"conventional-changelog.js",
"conventional-recommended-bump.js",
"index.js",
"parser-opts.js",
"writer-opts.js",
"templates"
],
"bugs": {
"url": "https://github.com/conventional-changelog/conventional-changelog/issues"
},
"homepage": "https://github.com/conventional-changelog/conventional-changelog/tree/master/packages/conventional-changelog-eslint#readme",
"devDependencies": {
"conventional-changelog-core": "0.0.2",
"shelljs": "^0.8.0",
"through2": "^2.0.0"
},
"dependencies": {
"q": "^1.5.1"
}
}

View File

@@ -0,0 +1,9 @@
'use strict'
module.exports = {
headerPattern: /^(\w*):\s*(.*)$/,
headerCorrespondence: [
`tag`,
`message`
]
}

View File

@@ -0,0 +1,5 @@
* {{#if message}}{{message}}{{else}}{{header}}{{/if}}
{{~!-- commit hash --}} {{#if @root.linkReferences}}([{{hash}}]({{#if @root.host}}{{@root.host}}/{{/if}}{{#if @root.owner}}{{@root.owner}}/{{/if}}{{@root.repository}}/{{@root.commit}}/{{hash}})){{else}}{{hash~}}{{/if}}
{{~!-- commit references --}}{{#if references}}, closes{{~#each references}} {{#if @root.linkReferences}}[{{#if this.owner}}{{this.owner}}/{{/if}}{{this.repository}}#{{this.issue}}]({{#if @root.host}}{{@root.host}}/{{/if}}{{#if this.repository}}{{#if this.owner}}{{this.owner}}/{{/if}}{{this.repository}}{{else}}{{#if @root.owner}}{{@root.owner}}/{{/if}}{{@root.repository}}{{/if}}/{{@root.issue}}/{{this.issue}}){{else}}{{#if this.owner}}{{this.owner}}/{{/if}}{{this.repository}}#{{this.issue}}{{/if}}{{/each}}{{/if}}

View File

@@ -0,0 +1,2 @@
<a name="{{version}}"></a>
{{#if isPatch}}##{{else}}#{{/if}} {{#if @root.linkCompare}}[{{version}}]({{@root.host}}/{{#if @root.owner}}{{@root.owner}}/{{/if}}{{@root.repository}}/compare/{{previousTag}}...{{currentTag}}){{else}}{{version}}{{/if}}{{#if title}} "{{title}}"{{/if}}{{#if date}} ({{date}}){{/if}}

View File

@@ -0,0 +1,15 @@
{{> header}}
{{#each commitGroups}}
{{#if title}}
### {{title}}
{{/if}}
{{#each commits}}
{{> commit root=@root}}
{{/each}}
{{/each}}

View File

@@ -0,0 +1,35 @@
'use strict'
const Q = require(`q`)
const readFile = Q.denodeify(require(`fs`).readFile)
const resolve = require(`path`).resolve
module.exports = Q.all([
readFile(resolve(__dirname, `./templates/template.hbs`), `utf-8`),
readFile(resolve(__dirname, `./templates/header.hbs`), `utf-8`),
readFile(resolve(__dirname, `./templates/commit.hbs`), `utf-8`)
])
.spread((template, header, commit) => {
const writerOpts = getWriterOpts()
writerOpts.mainTemplate = template
writerOpts.headerPartial = header
writerOpts.commitPartial = commit
return writerOpts
})
function getWriterOpts () {
return {
transform: (commit) => {
if (!commit.tag || typeof commit.tag !== `string`) {
return
}
return commit
},
groupBy: `tag`,
commitGroupsSort: `title`,
commitsSort: [`tag`, `message`]
}
}