From 29e04aa6eaefdf3a76aa4feafb8ae8cfd5338885 Mon Sep 17 00:00:00 2001 From: Victor Yves Crispim Date: Fri, 24 Nov 2023 17:15:33 -0300 Subject: [PATCH] ci: merge workflows Since the `commits` and `license-header` workflows are very simple and share the same trigger, it made sense to merge both in a single workflow --- .github/workflows/commits.yml | 19 --------------- ...icense-header.yml => repo-conventions.yml} | 24 +++++++++---------- 2 files changed, 12 insertions(+), 31 deletions(-) delete mode 100644 .github/workflows/commits.yml rename .github/workflows/{license-header.yml => repo-conventions.yml} (50%) diff --git a/.github/workflows/commits.yml b/.github/workflows/commits.yml deleted file mode 100644 index d4fff7b78..000000000 --- a/.github/workflows/commits.yml +++ /dev/null @@ -1,19 +0,0 @@ -# yaml-language-server: $schema=https://json.schemastore.org/github-workflow.json -name: Conventional commit check - -on: [push] - -jobs: - commit_messages: - runs-on: ubuntu-latest - steps: - - name: Checkout code - uses: actions/checkout@v4 - with: - fetch-depth: 0 - - - name: Conventional commit check - id: conventional_commit_check - uses: cocogitto/cocogitto-action@v3 - with: - check-latest-tag-only: true diff --git a/.github/workflows/license-header.yml b/.github/workflows/repo-conventions.yml similarity index 50% rename from .github/workflows/license-header.yml rename to .github/workflows/repo-conventions.yml index 5dbafafec..80397f8f1 100644 --- a/.github/workflows/license-header.yml +++ b/.github/workflows/repo-conventions.yml @@ -1,24 +1,24 @@ # yaml-language-server: $schema=https://json.schemastore.org/github-workflow.json -name: Check license header +name: Check repository conventions + +on: push -on: - push: - paths: - - ".github/workflows/license-header.yml" - - ".github/license-check" - - "cmd/**" - - "internal/**" - - "offchain/**" jobs: - check-copyright: + check-conventions: runs-on: ubuntu-latest steps: - uses: actions/checkout@v4 with: submodules: recursive - - - uses: viperproject/check-license-header@v2 + + - name: Check conventional commit + uses: cocogitto/cocogitto-action@v3 + with: + check-latest-tag-only: true + + - name: Check license header + uses: viperproject/check-license-header@v2 with: path: ./ config: .github/license-check/config.json