-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #1119 from mrapp-ke/merge-feature
Merge feature into main branch
- Loading branch information
Showing
8 changed files
with
366 additions
and
20 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
# Quality-of-Life Improvements | ||
|
||
- Releases are now automated via continuous integration, including the update of the project's changelog. | ||
- The presentation of algorithmic parameters in the documentation has been improved. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
--- | ||
name: Trigger release | ||
on: workflow_dispatch | ||
jobs: | ||
update_changelog: | ||
name: Update changelog | ||
uses: ./.github/workflows/template_update_changelog.yml | ||
with: | ||
release_branch: ${{ github.ref_name }} | ||
secrets: | ||
token_app_id: ${{ secrets.TOKEN_APP_ID }} | ||
token_app_secret: ${{ secrets.TOKEN_APP_SECRET }} | ||
release: | ||
needs: update_changelog | ||
name: Publish release on GitHub | ||
uses: ./.github/workflows/template_release.yml | ||
with: | ||
release_branch: ${{ github.ref_name }} | ||
release_version: ${{ needs.update_changelog.outputs.release_version }} | ||
changelog: ${{ needs.update_changelog.outputs.latest_changelog }} | ||
secrets: | ||
token_app_id: ${{ secrets.TOKEN_APP_ID }} | ||
token_app_secret: ${{ secrets.TOKEN_APP_SECRET }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
--- | ||
name: Publish release on GitHub | ||
on: | ||
workflow_call: | ||
inputs: | ||
release_branch: | ||
required: true | ||
type: string | ||
release_version: | ||
required: true | ||
type: string | ||
changelog: | ||
required: true | ||
type: string | ||
secrets: | ||
token_app_id: | ||
required: true | ||
token_app_secret: | ||
required: true | ||
jobs: | ||
release: | ||
name: Publish release on GitHub | ||
runs-on: ubuntu-latest | ||
steps: | ||
- name: Generate token | ||
uses: actions/create-github-app-token@v1 | ||
id: app-token | ||
with: | ||
app-id: ${{ secrets.token_app_id }} | ||
private-key: ${{ secrets.token_app_secret }} | ||
- name: Publish release on GitHub | ||
uses: softprops/action-gh-release@v2 | ||
with: | ||
target_commitish: ${{ inputs.release_branch }} | ||
name: Version ${{ inputs.release_version }} | ||
tag_name: ${{ inputs.release_version }} | ||
body: ${{ inputs.changelog }} | ||
make_latest: true | ||
token: ${{ steps.app-token.outputs.token }} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,63 @@ | ||
--- | ||
name: Update changelog | ||
on: | ||
workflow_call: | ||
inputs: | ||
release_branch: | ||
required: true | ||
type: string | ||
secrets: | ||
token_app_id: | ||
required: true | ||
token_app_secret: | ||
required: true | ||
outputs: | ||
release_version: | ||
value: ${{ jobs.update_changelog.outputs.release_version }} | ||
latest_changelog: | ||
value: ${{ jobs.update_changelog.outputs.latest_changelog }} | ||
jobs: | ||
update_changelog: | ||
name: Update changelog | ||
runs-on: ubuntu-latest | ||
outputs: | ||
release_version: ${{ steps.print-version.outputs.version }} | ||
latest_changelog: ${{ steps.print-latest-changelog.outputs.changelog }} | ||
steps: | ||
- name: Generate token | ||
uses: actions/create-github-app-token@v1 | ||
id: app-token | ||
with: | ||
app-id: ${{ secrets.token_app_id }} | ||
private-key: ${{ secrets.token_app_secret }} | ||
- name: Checkout | ||
uses: actions/checkout@v4 | ||
with: | ||
fetch-depth: 0 | ||
token: ${{ steps.app-token.outputs.token }} | ||
ref: ${{ inputs.release_branch }} | ||
- name: Setup git | ||
uses: fregante/setup-git-user@v2 | ||
- name: Update changelog | ||
run: | | ||
./build update_changelog_${{ inputs.release_branch }} | ||
git add .changelog-*.md | ||
git add CHANGELOG.md | ||
git commit -m "[Bot] Update changelog." | ||
git push | ||
- name: Save release version to output | ||
id: print-version | ||
run: | | ||
VERSION=$(./build print_version) | ||
EOF=$(dd if=/dev/urandom bs=15 count=1 status=none | base64) | ||
echo "version<<$EOF" >> $GITHUB_OUTPUT | ||
echo "$VERSION" >> $GITHUB_OUTPUT | ||
echo "$EOF" >> $GITHUB_OUTPUT | ||
- name: Save changelog to output | ||
id: print-latest-changelog | ||
run: |- | ||
CHANGELOG=$(./build print_latest_changelog) | ||
EOF=$(dd if=/dev/urandom bs=15 count=1 status=none | base64) | ||
echo "changelog<<$EOF" >> $GITHUB_OUTPUT | ||
echo "$CHANGELOG" >> $GITHUB_OUTPUT | ||
echo "$EOF" >> $GITHUB_OUTPUT |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.