-
Notifications
You must be signed in to change notification settings - Fork 159
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'main' into batch-vt-sevs
- Loading branch information
Showing
20 changed files
with
179 additions
and
89 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
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
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
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
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
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
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
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,34 +1,54 @@ | ||
name: Release gvmd with pontos | ||
name: Release gvmd | ||
|
||
on: | ||
pull_request: | ||
types: [closed] | ||
workflow_dispatch: | ||
inputs: | ||
release-type: | ||
type: choice | ||
description: What kind of release do you want to do (pontos --release-type argument)? | ||
options: | ||
- patch | ||
- minor | ||
- major | ||
release-version: | ||
type: string | ||
description: Set an explicit version, that will overwrite release-type. Fails if version is not compliant. | ||
|
||
jobs: | ||
build-and-release: | ||
name: Create a new release with pontos | ||
# If the event is a workflow_dispatch or the label 'make release' is set and PR is closed because of a merge | ||
if: (github.event_name == 'workflow_dispatch') || (contains( github.event.pull_request.labels.*.name, 'make release') && github.event.pull_request.merged == true) | ||
runs-on: "ubuntu-latest" | ||
name: Create a new release | ||
# If the event is a workflow_dispatch or on of the labels 'pre release', | ||
# 'patch release', 'minor release' or 'major release' is set and PR is | ||
# closed because of a merge | ||
# NOTE: priority of set labes will be alpha > release-candidate > patch > minor > major, | ||
# so if 'major' and 'patch' labes are set, it will create a patch release. | ||
if: | | ||
( github.event_name == 'workflow_dispatch') || ( | ||
( contains(github.event.pull_request.labels.*.name, 'alpha release') || | ||
contains(github.event.pull_request.labels.*.name, 'rc release') || | ||
contains(github.event.pull_request.labels.*.name, 'patch release') || | ||
contains(github.event.pull_request.labels.*.name, 'minor release') || | ||
contains(github.event.pull_request.labels.*.name, 'major release')) && | ||
github.event.pull_request.merged == true ) | ||
runs-on: 'ubuntu-latest' | ||
steps: | ||
- name: Setting the Reference | ||
run: | | ||
if [[ "${{ github.event_name }}" = "workflow_dispatch" ]]; then | ||
echo "RELEASE_REF=${{ github.ref_name }}" >> $GITHUB_ENV | ||
else | ||
echo "RELEASE_REF=${{ github.base_ref }}" >> $GITHUB_ENV | ||
fi | ||
- name: Selecting the Release type | ||
id: release-type | ||
uses: greenbone/actions/release-type@v2 | ||
with: | ||
release-type-input: ${{ inputs.release-type }} | ||
- name: Release with release action | ||
uses: greenbone/actions/release@v2 | ||
with: | ||
python-version: "3.10" | ||
conventional-commits: true | ||
github-user: ${{ secrets.GREENBONE_BOT }} | ||
github-user-mail: ${{ secrets.GREENBONE_BOT_MAIL }} | ||
github-user-token: ${{ secrets.GREENBONE_BOT_TOKEN }} | ||
gpg-key: ${{ secrets.GPG_KEY }} | ||
gpg-fingerprint: ${{ secrets.GPG_FINGERPRINT }} | ||
gpg-passphrase: ${{ secrets.GPG_PASSPHRASE }} | ||
strategy: calendar | ||
ref: ${{ env.RELEASE_REF }} | ||
release-type: ${{ steps.release-type.outputs.release-type }} | ||
release-version: ${{ inputs.release-version }} | ||
ref: ${{ steps.release-type.outputs.release-ref }} | ||
versioning-scheme: "semver" |
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 |
---|---|---|
|
@@ -2,3 +2,4 @@ build/ | |
tags | ||
.ccls | ||
.vscode | ||
.venv |
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
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
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
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.