From 8610f1f16ccb63a7d9358eed19b5eabebc9fd9b8 Mon Sep 17 00:00:00 2001 From: Yuan <45984206+Yuan325@users.noreply.github.com> Date: Mon, 10 Jun 2024 17:33:37 -0700 Subject: [PATCH] ci: update ci name from tests to lint (#406) --- .github/workflows/{tests.yml => lint.yml} | 10 +++++----- .../{tests_fallback.yml => lint_fallback.yml} | 4 ++-- 2 files changed, 7 insertions(+), 7 deletions(-) rename .github/workflows/{tests.yml => lint.yml} (94%) rename .github/workflows/{tests_fallback.yml => lint_fallback.yml} (94%) diff --git a/.github/workflows/tests.yml b/.github/workflows/lint.yml similarity index 94% rename from .github/workflows/tests.yml rename to .github/workflows/lint.yml index 9217119a..a1f6d4cc 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/lint.yml @@ -12,7 +12,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -name: tests +name: lint on: pull_request: paths-ignore: @@ -34,8 +34,8 @@ permissions: read-all jobs: integration: - # run job on proper workflow event triggers (skip job for pull_request event from forks and only run pull_request_target for "tests: run" label) - if: "${{ (github.event.action != 'labeled' && github.event.pull_request.head.repo.full_name == github.event.pull_request.base.repo.full_name) || github.event.label.name == 'tests: run' }}" + # run job on proper workflow event triggers (skip job for pull_request event from forks and only run pull_request_target for "lint: run" label) + if: "${{ (github.event.action != 'labeled' && github.event.pull_request.head.repo.full_name == github.event.pull_request.base.repo.full_name) || github.event.label.name == 'lint: run' }}" name: ${{ matrix.dir }} runs-on: ubuntu-latest strategy: @@ -49,14 +49,14 @@ jobs: pull-requests: write steps: - name: Remove PR label - if: "${{ github.event.action == 'labeled' && github.event.label.name == 'tests: run' }}" + if: "${{ github.event.action == 'labeled' && github.event.label.name == 'lint: run' }}" uses: actions/github-script@60a0d83039c74a4aee543508d2ffcb1c3799cdea # v7.0.1 with: github-token: ${{ secrets.GITHUB_TOKEN }} script: | try { await github.rest.issues.removeLabel({ - name: 'tests: run', + name: 'lint: run', owner: context.repo.owner, repo: context.repo.repo, issue_number: context.payload.pull_request.number diff --git a/.github/workflows/tests_fallback.yml b/.github/workflows/lint_fallback.yml similarity index 94% rename from .github/workflows/tests_fallback.yml rename to .github/workflows/lint_fallback.yml index 58bb3267..faf534b5 100644 --- a/.github/workflows/tests_fallback.yml +++ b/.github/workflows/lint_fallback.yml @@ -12,7 +12,7 @@ # See the License for the specific language governing permissions and # limitations under the License. -name: tests +name: lint on: pull_request: paths: @@ -30,4 +30,4 @@ jobs: contents: none steps: - - run: echo "No tests required." + - run: echo "No lint required."