diff --git a/.github/actions/gh-cache/cache/action.yml b/.github/actions/gh-cache/cache/action.yml index f0c36a2..7577a39 100644 --- a/.github/actions/gh-cache/cache/action.yml +++ b/.github/actions/gh-cache/cache/action.yml @@ -14,7 +14,7 @@ inputs: fail_on_cache_miss: description: "Fail the workflow if cached item is not found." required: false - default: 'false' + default: "false" outputs: value: @@ -24,8 +24,15 @@ outputs: runs: using: "composite" steps: + - name: Make sub-actions referenceable + working-directory: ${{ github.action_path }} + shell: bash + run: | + mkdir -p /home/runner/work/_actions/current/.github/actions + rsync -a ../../../../.github/actions/ /home/runner/work/_actions/current/.github/actions/ + ls -ltra /home/runner/work/_actions/current/.github/actions - name: Restore cached value - uses: ./.github/actions/gh-cache/restore + uses: ./../../_actions/current/.github/actions/gh-cache/restore with: path: ${{ inputs.key }} token: ${{ inputs.token }} @@ -41,7 +48,7 @@ runs: - if: ${{ inputs.value }} name: Save cached value - uses: ./.github/actions/gh-cache/save + uses: ./../../_actions/current/.github/actions/gh-cache/save with: path: ${{ inputs.key }} token: ${{ inputs.token }} diff --git a/action.yml b/action.yml index 49deef4..3c519bb 100644 --- a/action.yml +++ b/action.yml @@ -40,9 +40,16 @@ outputs: runs: using: "composite" steps: + - name: Make sub-actions referenceable + working-directory: ${{ github.action_path }} + shell: bash + run: | + mkdir -p /home/runner/work/_actions/current/.github/actions + rsync -a .github/actions/ /home/runner/work/_actions/current/.github/actions/ + ls -ltra /home/runner/work/_actions/current/.github/actions - name: Restore cached results id: restore - uses: ./.github/actions/gh-cache/cache + uses: ./../../_actions/current/.github/actions/gh-cache/cache with: key: ${{ inputs.cache_key }} token: ${{ inputs.token }} @@ -59,20 +66,20 @@ runs: - if: ${{ inputs.login_url && inputs.username && inputs.password && !inputs.auth_context }} name: Authenticate id: auth - uses: ./.github/actions/auth + uses: ./../../_actions/current/.github/actions/auth with: login_url: ${{ inputs.login_url }} username: ${{ inputs.username }} password: ${{ inputs.password }} - name: Find id: find - uses: ./.github/actions/find + uses: ./../../_actions/current/.github/actions/find with: urls: ${{ inputs.urls }} auth_context: ${{ inputs.auth_context || steps.auth.outputs.auth_context }} - name: File id: file - uses: ./.github/actions/file + uses: ./../../_actions/current/.github/actions/file with: findings: ${{ steps.find.outputs.findings }} repository: ${{ inputs.repository }} @@ -89,7 +96,7 @@ runs: - if: ${{ inputs.skip_copilot_assignment != 'true' }} name: Fix id: fix - uses: ./.github/actions/fix + uses: ./../../_actions/current/.github/actions/fix with: issues: ${{ steps.get_issues_from_filings.outputs.issues }} repository: ${{ inputs.repository }} @@ -119,7 +126,7 @@ runs: FILINGS: ${{ steps.file.outputs.filings }} FIXINGS: ${{ steps.fix.outputs.fixings }} - name: Save cached results - uses: ./.github/actions/gh-cache/cache + uses: ./../../_actions/current/.github/actions/gh-cache/cache with: key: ${{ inputs.cache_key }} value: ${{ steps.results.outputs.results }}