From 1395fc0442bf678fde5f83a8dabe76ee7cb055e6 Mon Sep 17 00:00:00 2001 From: Claudio Bley Date: Tue, 10 Dec 2024 14:16:32 +0100 Subject: [PATCH] Use the action checked out directly Checking out a copy of this action with a fixed revision is surprising and makes it difficult to pin actions properly since the action itself will by default always checkout `v1` again. One would have to duplicate the revision / version on the use site to be safe. --- action.yml | 16 +--------------- 1 file changed, 1 insertion(+), 15 deletions(-) diff --git a/action.yml b/action.yml index e47eea2..53e79e1 100644 --- a/action.yml +++ b/action.yml @@ -7,32 +7,18 @@ inputs: github_token: description: The Github token to authenticate PR operations. required: true - checkout_ref: - type: string - default: v1 - checkout_path: - type: string - default: .github/actions/gha_join_jobs - runs: using: composite steps: - - uses: actions/checkout@11bd71901bbe5b1630ceea73d27597364c9af683 # v4 - with: - repository: cgrindel/gha_join_jobs - ref: ${{ inputs.checkout_ref }} - path: ${{ inputs.checkout_path }} - - name: Check Previous Jobs shell: bash env: - GHA_JOIN_JOBS_PATH: ${{ inputs.checkout_path }} GITHUB_TOKEN: ${{ inputs.github_token }} JOB_NAMES: ${{ inputs.job_names }} run: | repo_dir="${PWD}" - cd "${GHA_JOIN_JOBS_PATH}" + cd '${{ github.action_path }}' bazel_cmd=( bazelisk run //tools:check_jobs -- ) [[ -n "${JOB_NAMES:-}" ]] && bazel_cmd+=( --job_names "${JOB_NAMES}" ) "${bazel_cmd[@]}"