Skip to content

Commit

Permalink
chore: release process with release-it
Browse files Browse the repository at this point in the history
  • Loading branch information
jonathas committed Jan 7, 2023
1 parent 14411fb commit b353cc9
Show file tree
Hide file tree
Showing 8 changed files with 12,769 additions and 2,030 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
node_modules
test/output
test/fake.pdf
example
.vscode
coverage
4 changes: 4 additions & 0 deletions .husky/commit-msg
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
#!/bin/sh
. "$(dirname "$0")/_/husky.sh"

npx commitlint --edit $1
11 changes: 10 additions & 1 deletion .npmignore
Original file line number Diff line number Diff line change
@@ -1 +1,10 @@
example
example
.editorconfig
.eslintrc.json
.release-it.js
changelog.hbs
commitlint.config.js
.travis.yml
.jshintrc
.istanbul.yml
test
26 changes: 26 additions & 0 deletions .release-it.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
module.exports = {
hooks: {
"after:bump": ["npx auto-changelog -p"]
},
git: {
commit: true,
commitMessage: "chore(release): ${version}",
commitArgs: "",
tag: true,
tagName: "${version}",
tagAnnotation: "${version}",
push: true,
requireCommits: true,
changelog:
"npx auto-changelog --stdout --commit-limit false -u --template ./changelog.hbs"
},
github: {
release: false,
releaseName: "${version}",
// assets: ['dist/*.zip'],
assets: ["dist/*.zip"]
},
npm: {
publish: true
}
};
13 changes: 13 additions & 0 deletions changelog.hbs
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
{{#each releases}}
{{#if @first}}
{{#each merges}}
- {{{message}}}{{#if href}} [`#{{id}}`]({{href}}){{/if}}
{{/each}}
{{#each fixes}}
- {{{commit.subject}}}{{#each fixes}}{{#if href}} [`#{{id}}`]({{href}}){{/if}}{{/each}}
{{/each}}
{{#each commits}}
- {{#if breaking}}**Breaking change:** {{/if}}{{{subject}}}{{#if href}} [`{{shorthash}}`]({{href}}){{/if}}
{{/each}}
{{/if}}
{{/each}}
1 change: 1 addition & 0 deletions commitlint.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
module.exports = { extends: ['@commitlint/config-conventional'] };
Loading

0 comments on commit b353cc9

Please sign in to comment.