Skip to content

Commit

Permalink
fix(ci): build changelog
Browse files Browse the repository at this point in the history
  • Loading branch information
Thomgrus committed Dec 21, 2021
1 parent 2ed7d6c commit bfa45ae
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 7 deletions.
4 changes: 4 additions & 0 deletions .github/workflows/build.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,7 @@ jobs:
uses: actions/checkout@v2
with:
fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis
ref: ${{ github.ref }}
- name: Set up JDK
uses: actions/setup-java@v2.3.1
with:
Expand Down Expand Up @@ -192,6 +193,7 @@ jobs:
uses: actions/checkout@v2
with:
fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis
ref: ${{ github.ref }}
- name: Initialize CodeQL
uses: github/codeql-action/init@v1
with:
Expand Down Expand Up @@ -266,6 +268,7 @@ jobs:
uses: actions/checkout@v2
with:
token: ${{ secrets.PAT_TOKEN }}
ref: ${{ github.ref }}
- uses: actions/setup-python@v2
with:
python-version: 3.7
Expand Down Expand Up @@ -302,6 +305,7 @@ jobs:
with:
fetch-depth: 0
persist-credentials: false # To use github token provide for semantic release
ref: ${{ github.ref }}
- if: ${{ needs.bump-candidate.outputs.bump == 'true' || steps.skip_check.outputs.should_skip != 'true' }}
name: Install Helm
uses: azure/setup-helm@v1
Expand Down
17 changes: 10 additions & 7 deletions .github/workflows/charts-release.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,7 @@ jobs:
uses: actions/checkout@v2
with:
fetch-depth: 0
ref: ${{ github.ref }}
- name: Install Helm
uses: azure/setup-helm@v1
with:
Expand All @@ -61,21 +62,23 @@ jobs:
with:
tag_name: ara-stable-v${{ steps.version.outputs.stable }}
release_name: ara-stable-v${{ steps.version.outputs.stable }}
draft: true
draft: false
prerelease: false
- name: Build Changelog
id: github_release
uses: mikepenz/release-changelog-builder-action@v2.7.1
- uses: octokit/request-action@v2
id: generate_changelog
with:
fromTag: "${{ steps.version.outputs.fromTag }}"
toTag: "ara-stable-v${{ steps.version.outputs.stable }}"
route: POST /repos/{owner}/{repo}/releases/generate-notes
owner: Decathlon
repo: ara
tag_name: ara-stable-v${{ steps.version.outputs.stable }}
previous_tag_name: ${{ steps.version.outputs.fromTag }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Create Changelog file
working-directory: charts/stable
run: |
cat <<EOF >CHANGELOG.md
${{steps.github_release.outputs.changelog}}
${{ fromJson(steps.create_check_run.outputs.data).body }}
EOF
- name: Configure Git
run: |
Expand Down

0 comments on commit bfa45ae

Please sign in to comment.