Merge pull request #8199 from keymanapp/fix/linux/gha

fix(linux): Fix Verify-API step of GHA
This commit is contained in:
Eberhard Beilharz 2023-02-10 08:44:56 +01:00 committed by GitHub
commit 7f15603bc2
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 9 additions and 8 deletions

View file

@ -203,8 +203,8 @@ jobs:
- name: Verify API
run: |
cd linux
SRC_PKG="artifacts/keyman-srcpkg/keyman_${{ needs.sourcepackage.outputs.VERSION }}-1.debian.tar.xz" \
BIN_PKG="artifacts/keyman-binarypkgs/libkmnkbp0-0_${{ needs.sourcepackage.outputs.VERSION }}-1${{ needs.sourcepackage.outputs.PRERELEASE_TAG }}+jammy1_amd64.deb" \
SRC_PKG="${GITHUB_WORKSPACE}/artifacts/keyman-srcpkg/keyman_${{ needs.sourcepackage.outputs.VERSION }}-1.debian.tar.xz" \
BIN_PKG="${GITHUB_WORKSPACE}/artifacts/keyman-binarypkgs/libkmnkbp0-0_${{ needs.sourcepackage.outputs.VERSION }}-1${{ needs.sourcepackage.outputs.PRERELEASE_TAG }}+jammy1_amd64.deb" \
PKG_VERSION="${{ needs.sourcepackage.outputs.VERSION }}" \
./scripts/deb-packaging.sh --gha verify >> $GITHUB_STEP_SUMMARY

View file

@ -129,17 +129,18 @@ function triggerGitHubActionsBuild() {
local IS_TEST_BUILD="$1"
local GITHUB_ACTION="$2"
local GIT_BRANCH="${3:-master}"
local GIT_REF=$GIT_BRANCH
local GIT_REF
local GITHUB_SERVER=https://api.github.com/repos/keymanapp/keyman/dispatches
# This will only be true if we created and pushed a tag
if [ "${action:-""}" == "commit" ]; then
GIT_REF="release@$VERSION_WITH_TAG"
fi
if [[ $GIT_BRANCH != stable-* ]] && [[ $GIT_BRANCH =~ [0-9]+ ]]; then
# This will only be true if we created and pushed a tag
GIT_REF="refs/tags/release@$VERSION_WITH_TAG"
elif [[ $GIT_BRANCH != stable-* ]] && [[ $GIT_BRANCH =~ [0-9]+ ]]; then
GIT_REF="refs/pull/${GIT_BRANCH}/merge"
GIT_BRANCH="PR-${GIT_BRANCH}"
else
GIT_REF="refs/heads/${GIT_BRANCH}"
fi
local DATA="{\"event_type\": \"$GITHUB_ACTION\", \