Skip to content

Commit

Permalink
Fix the changelog generation
Browse files Browse the repository at this point in the history
  • Loading branch information
sbrunner committed Nov 1, 2023
1 parent 3d0bec0 commit 4adc837
Show file tree
Hide file tree
Showing 3 changed files with 23 additions and 15 deletions.
3 changes: 3 additions & 0 deletions .github/ci-upgrade.yaml
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
values:
changelogAdditionalArgs:
- --tag-skip=3.23.0

disabled:
- changelogCreateRelease
17 changes: 3 additions & 14 deletions .github/workflows/changelog.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,9 @@ name: Changelog Generator
on:
schedule:
- cron: 0 0 * * 1,4
push:
tags:
- '*.*.*'
repository_dispatch:
types:
- changelog

jobs:
changelog:
Expand All @@ -14,17 +14,6 @@ jobs:
timeout-minutes: 30

steps:
- uses: actions/checkout@v4
if: github.event_name == 'push' && github.ref_type == 'tag'
- name: Create release
run: |-
if [[ ${{ github.ref_name }} =~ ^[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
gh release create ${{ github.ref_name }} --generate-notes || true
fi
if: github.event_name == 'push' && github.ref_type == 'tag'
env:
GH_TOKEN: ${{ secrets.GOPASS_CI_GITHUB_TOKEN }}

- name: Get Date
id: get-date
run: echo "date=$(/bin/date -u "+%Y%m%d%H%M%S")" >> $GITHUB_OUTPUT
Expand Down
18 changes: 17 additions & 1 deletion .github/workflows/main.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,14 @@ on:
permissions:
packages: write

actions: write
contents: write

env:
HAS_SECRETS: ${{ secrets.HAS_SECRETS }}

jobs:
build:
main:
runs-on: ubuntu-22.04
timeout-minutes: 30
name: Continuous integration
Expand Down Expand Up @@ -226,3 +229,16 @@ jobs:
cd ${GITHUB_WORKSPACE}/mapfish-print-doc
git push origin gh-pages
if: github.ref == 'refs/heads/master' && env.HAS_SECRETS == 'HAS_SECRETS'

- name: Trigger changelog workflow
uses: actions/github-script@v6
with:
script: |-
if (process.env.GITHUB_REF_TYPE == 'tag') {
console.log('Trigger changelog');
await github.rest.repos.createDispatchEvent({
owner: 'camptocamp',
repo: 'helm-mutualize',
event_type: 'changelog',
});
}

0 comments on commit 4adc837

Please sign in to comment.