From 9fb5d1ab2fe379609772e5bca6a64cfeb7552155 Mon Sep 17 00:00:00 2001 From: Tomas Sebestik Date: Fri, 6 Dec 2024 07:41:18 +0100 Subject: [PATCH] fix(inputs): add fallback to ENV for inputs JIRA_COMPONENT and JIRA_TASK --- .github/workflows/sync-jira.yml | 2 +- action.yml | 6 +++--- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/.github/workflows/sync-jira.yml b/.github/workflows/sync-jira.yml index 6bb2c7e..0992c50 100644 --- a/.github/workflows/sync-jira.yml +++ b/.github/workflows/sync-jira.yml @@ -48,4 +48,4 @@ jobs: JIRA_URL: ${{ secrets.JIRA_URL }} JIRA_USER: ${{ secrets.JIRA_USER }} JIRA_PROJECT: RDT - JIRA_COMPONENT: 'github-actions-development' + JIRA_COMPONENT: 'github-actions-development' # pragma: allowlist secret diff --git a/action.yml b/action.yml index 2d54fcb..a2a460d 100644 --- a/action.yml +++ b/action.yml @@ -75,6 +75,6 @@ runs: JIRA_URL: ${{ env.JIRA_URL }} # Needs to be passed from caller workflow; by ENV (secure), not by input JIRA_USER: ${{ env.JIRA_USER }} # Needs to be passed from caller workflow; by ENV (secure), not by input INPUT_CRON_JOB: ${{ github.event_name == 'schedule' && 'true' || '' }} - JIRA_PROJECT: ${{ inputs.jira-project != '' && inputs.jira-project || env.JIRA_PROJECT }} # Try input, fallback to enn - JIRA_COMPONENT: ${{ inputs.jira-component }} - JIRA_ISSUE_TYPE: ${{ inputs.jira-issue-type }} + JIRA_PROJECT: ${{ inputs.jira-project != '' && inputs.jira-project || env.JIRA_PROJECT }} # Try input, fallback to env + JIRA_COMPONENT: ${{ inputs.jira-component || env.JIRA_COMPONENT }} # Try input, fallback to env + JIRA_ISSUE_TYPE: ${{ inputs.jira-issue-type || env.JIRA_COMPONENT }} # Try input, fallback to env