From fbb9d71b02003ce14d3f6a5315ecd59c5e709586 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mislav=20Marohni=C4=87?= Date: Wed, 10 May 2023 12:14:07 +0200 Subject: [PATCH 1/2] Fix release guard for deployment workflow Co-authored-by: Sam Coe --- .github/workflows/deployment.yml | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/.github/workflows/deployment.yml b/.github/workflows/deployment.yml index 8d1cb2169..c2dad891e 100644 --- a/.github/workflows/deployment.yml +++ b/.github/workflows/deployment.yml @@ -293,6 +293,7 @@ jobs: cp -a upload/* site/packages/ - name: Create the release env: + # In non-production environments, the assets will not have been signed DO_PUBLISH: ${{ inputs.environment == 'production' }} TAG_NAME: ${{ inputs.tag_name }} GH_TOKEN: ${{ secrets.GITHUB_TOKEN }} @@ -313,9 +314,9 @@ jobs: else release_args+=( --discussion-category "General" ) fi - action="echo" - [ "$DO_PUBLISH" = "false" ] || action="command" - script/label-assets dist/gh_* | xargs $action gh release create "${release_args[@]}" -- + guard="echo" + [ "$DO_PUBLISH" = "false" ] || guard="" + script/label-assets dist/gh_* | xargs $guard gh release create "${release_args[@]}" -- - name: Publish site env: DO_PUBLISH: ${{ inputs.environment == 'production' && !contains(inputs.tag_name, '-') }} From aa2adab7fac34837e4034244fc8cd24f0dccdee7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mislav=20Marohni=C4=87?= Date: Wed, 10 May 2023 12:38:06 +0200 Subject: [PATCH 2/2] Fix label assets --- script/label-assets | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/script/label-assets b/script/label-assets index 8c06c4b91..322e35998 100755 --- a/script/label-assets +++ b/script/label-assets @@ -16,5 +16,5 @@ for asset; do *.deb ) label="${label} deb" ;; *.rpm ) label="${label} RPM" ;; esac - printf "%s#%s\n" "$asset" "$label" + printf '"%s#%s"\n' "$asset" "$label" done \ No newline at end of file