Skip to content

Commit

Permalink
Fix: Ci: on release use given token and set repository on pontos
Browse files Browse the repository at this point in the history
  • Loading branch information
nichtsfrei committed Mar 13, 2024
1 parent 207e843 commit 22c10ad
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 1 deletion.
1 change: 1 addition & 0 deletions .github/workflows/control.yml
Original file line number Diff line number Diff line change
Expand Up @@ -98,6 +98,7 @@ jobs:
release_kind: ${{ needs.init.outputs.release_kind }}
release_ref: ${{ needs.init.outputs.release_ref }}
project: ${{ needs.init.outputs.release_project }}
repository: ${{ github.repository }}
secrets:
token: ${{ secrets.GREENBONE_BOT_TOKEN }}
name: ${{ secrets.GREENBONE_BOT }}
Expand Down
7 changes: 6 additions & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,9 @@ on:
project:
required: true
type: string
repository:
required: true
type: string
secrets:
token:
required: true
Expand Down Expand Up @@ -53,6 +56,7 @@ jobs:
LATEST_VERSION: ${{inputs.latest_version}}
NEW_VERSION: ${{inputs.new_version}}
PROJECT: ${{inputs.project}}
REPOSITORY: ${{inputs.repository}}
steps:
- uses: actions/checkout@v4
with:
Expand Down Expand Up @@ -107,13 +111,14 @@ jobs:
--next-version ${{ env.NEW_VERSION }} \
--config changelog.toml \
--project $PROJECT \
--repository $REPOSITORY \
--versioning-scheme semver \
-o /tmp/changelog.md || true
# we would rather have empty release notes than no release
if [ ! -f "/tmp/changelog.md" ]; then
touch /tmp/changelog.md
fi
echo "${{ secrets.GREENBONE_BOT_TOKEN }}" | gh auth login --with-token
echo "${{ secrets.token }}" | gh auth login --with-token
export nrn="v${{ env.NEW_VERSION }}"
gh release create "$nrn" -F /tmp/changelog.md
- name: "sign ${{ env.PROJECT }}"
Expand Down

0 comments on commit 22c10ad

Please sign in to comment.