From dfee51f87f5744e02034823c2192a12196f38d32 Mon Sep 17 00:00:00 2001 From: Xianpeng Shen <3353385+shenxianpeng@users.noreply.github.com> Date: Wed, 25 Nov 2026 20:05:44 +0000 Subject: [PATCH] ci: accept FORGE_APP_ID as a secret as well as a variable --- .github/workflows/deploy.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index 3d92ad5..fa3e35d 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -7,6 +7,7 @@ name: Deploy # # Configuration, set once in the repository settings: # vars.FORGE_APP_ID ari:cloud:ecosystem::app/, printed by `forge register` +# (a secret of the same name works too) # secrets.FORGE_EMAIL the Atlassian account's email # secrets.FORGE_API_TOKEN id.atlassian.com > Security > API tokens # @@ -83,10 +84,10 @@ jobs: - name: Write the app id into manifest.yml env: - APP_ID: ${{ vars.FORGE_APP_ID }} + APP_ID: ${{ vars.FORGE_APP_ID || secrets.FORGE_APP_ID }} run: | if ! printf '%s' "$APP_ID" | grep -Eq '^ari:cloud:ecosystem::app/[0-9a-fA-F-]{36}$'; then - echo "::error::Set the repository variable FORGE_APP_ID to the ari that 'forge register' printed." + echo "::error::Set FORGE_APP_ID (a repository variable or secret) to the ari that 'forge register' printed." exit 1 fi sed -i -E "s|^ id: ari:cloud:ecosystem::app/.*$| id: ${APP_ID}|" manifest.yml