Skip to content

Commit

Permalink
ci: Rename commitlint to PR title Lint, echo PR titles from env var
Browse files Browse the repository at this point in the history
Signed-off-by: Sergei Petrosian <[email protected]>
  • Loading branch information
spetrosi committed Jun 21, 2023
1 parent b0f181c commit 57a94ab
Showing 1 changed file with 5 additions and 4 deletions.
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
name: Commitlint
name: PR Title Lint
on: # yamllint disable-line rule:truthy
pull_request:
types:
Expand All @@ -25,6 +25,7 @@ jobs:
run: npm install @commitlint/config-conventional @commitlint/cli

- name: Run commitlint on PR title
run: >-
echo '${{ github.event.pull_request.title }}' |
npx commitlint --verbose
env:
PR_TITLE: ${{ github.event.pull_request.title }}
# Echo from env variable to avoid bash errors with extra characters
run: echo "$PR_TITLE" | npx commitlint --verbose

0 comments on commit 57a94ab

Please sign in to comment.