Skip to content

Commit

Permalink
enhancement(docusaurus) replace changelog when auto-building docs Ref…
Browse files Browse the repository at this point in the history
…s #145331
  • Loading branch information
ichim-david committed Feb 8, 2022
1 parent d26a717 commit da25c0e
Show file tree
Hide file tree
Showing 2 changed files with 46 additions and 2 deletions.
5 changes: 3 additions & 2 deletions .github/workflows/node.js.yml
Expand Up @@ -30,11 +30,12 @@ jobs:
node-version: ${{ matrix.node-version }}
- name: Push Docusaurus build changes
run: |
git config user.name github-actions
git config user.email github-actions@github.com
npx auto-changelog --commit-limit false --unreleased --stdout --template templates/eea.hbs > website/docs/2-whatsnew.md
cd website
yarn
yarn build
git config user.name github-actions
git config user.email github-actions@github.com
git add ../docs
git diff --staged --quiet || git commit -m "Autobuild of docusaurus docs"
git push
43 changes: 43 additions & 0 deletions templates/eea.hbs
@@ -0,0 +1,43 @@
### Changelog

All notable changes to this project will be documented in this file. Dates are displayed in UTC.

{{#unless options.hideCredit}}
Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog).
{{/unless}}

{{#each releases}}
{{#if href}}
###{{#unless major}}#{{/unless}} [{{title}}]({{href}}) - {{niceDate}}
{{else}}
#### {{title}} - {{niceDate}}
{{/if}}

{{! List commits with `Breaking change: ` somewhere in the message }}
{{#commit-list commits heading='### :boom: Breaking Change' subject='(Breaking change:|breaking:)'}}
- {{subject}} [`{{shorthash}}`]({{href}})
{{/commit-list}}

{{! List commits that add new features, but not those already listed above }}
{{#commit-list commits heading='### :rocket: New Features' subject='feat[:()]*'}}
- {{subject}} [`{{shorthash}}`]({{href}})
{{/commit-list}}

{{! List commits that add new features, but not those already listed above }}
{{#commit-list commits heading='### :bug: Bug Fixes' subject='fix[:()]*'}}
- {{subject}} [`{{shorthash}}`]({{href}})
{{/commit-list}}

{{#commit-list commits heading='### :nail_care: Enhancements' subject='(enhancement[:()])* (change[:!(])*' exclude='(Breaking|breaking)'}}
- {{subject}} [`{{shorthash}}`]({{href}})
{{/commit-list}}

{{#commit-list commits heading='### :house: Internal changes' subject='chore[:()]*'}}
- {{subject}} [`{{shorthash}}`]({{href}})
{{/commit-list}}

{{#commit-list commits heading='### :house: Documentation changes' subject='docs[:()]*' exclude='Autobuild'}}
- {{subject}} [`{{shorthash}}`]({{href}})
{{/commit-list}}

{{/each}}

0 comments on commit da25c0e

Please sign in to comment.