From 222b418d587a989757ebac048cf4e267ac9068d5 Mon Sep 17 00:00:00 2001 From: Mogyuchi Date: Thu, 13 Jun 2024 23:08:47 +0900 Subject: [PATCH] test --- .github/workflows/call-test.yml | 2 +- .github/workflows/test.yml | 34 +++++++++++++++++++++++++++------ 2 files changed, 29 insertions(+), 7 deletions(-) diff --git a/.github/workflows/call-test.yml b/.github/workflows/call-test.yml index b6cd1b0b3..f632b1ba8 100644 --- a/.github/workflows/call-test.yml +++ b/.github/workflows/call-test.yml @@ -4,4 +4,4 @@ on: jobs: call: - uses: 4m-mazi/gh-test/.github/workflows/debug.yml@4cf8a995b52ae9b78a8b9694d473e8a3453281de + uses: 4m-mazi/gh-test/.github/workflows/test.yml@main diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index a9df88dff..b6c95c6d6 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -9,16 +9,38 @@ on: default: false permissions: {} +env: + HERE: "4m-mazi/gh-test/.github/workflows/test.yml" + jobs: test1: + permissions: + contents: read if: > true runs-on: ubuntu-latest steps: + - uses: actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29 # v4.1.6 + with: + sparse-checkout: | + ${{ github.workflow }} + sparse-checkout-cone-mode: false - run: | - test2: - if: >- - true - runs-on: ubuntu-latest - steps: - - run: '' + ls -lah + - id: get-ref + uses: docker://mikefarah/yq:4.44.1-githubaction + with: + args: |- + yq '[.jobs.*.uses | select(tag == "!!str" and test("^${{ env.HERE }}@"))][0] | sub("^${{ env.HERE }}@", "")' ${{ github.workflow }} + + - id: test-ref + run: | + echo "result=v1.3.0" >> "$GITHUB_OUTPUT" + + + - uses: 4m-mazi/souji-action@${{ steps.get-ref.outputs.result }} + - uses: actions/checkout@a5ac7e51b41094c92402da3b24376905380afc29 # v4.1.6 + with: + repository: 4m-mazi/gh-test + ref: ${{ steps.get-ref.outputs.result }} + path: 'souji-action'