Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: STRF-11934 Separate Github PR Title check #1199

Merged
merged 1 commit into from
Apr 16, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
17 changes: 3 additions & 14 deletions .github/workflows/pull_request_review.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
# This workflow will do a clean install of node dependencies, build the source code and run tests across different versions of node
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-nodejs-with-github-actions

name: Tests

on:
Expand All @@ -20,25 +17,17 @@ jobs:

steps:
- name: Checkout code
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Use Node.js ${{ matrix.node }}
uses: actions/setup-node@v3
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node }}
cache: 'npm'

- name: Install Dependencies
run: npm ci

- name: Verify Github PR Title TEST
run: echo '${{ env.TITLE }}'

- name: Verify Github PR Title
run: echo '${{ env.TITLE }}' | npx commitlint

- name: Verify Git Commit Name
run: git log -1 --pretty=format:"%s" | npx commitlint

- name: Lint the code
run: npm run lint

Expand Down
26 changes: 26 additions & 0 deletions .github/workflows/pull_request_title_check.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: Pull Request Title Check

on:
pull_request:
branches: [master, main]

jobs:
check-pr-title:
env:
TITLE: ${{ github.event.pull_request.title }}

runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: '18.x'
cache: 'npm'
- name: Install Dependencies
run: npm ci

- name: Verify Github PR Title
run: echo $TITLE | npx commitlint

- name: Verify Git Commit Name
run: git log -1 --pretty=format:"%s" | npx commitlint
4 changes: 2 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,8 @@ jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/setup-node@v3
- uses: actions/checkout@v4
- uses: actions/setup-node@v4
with:
node-version: '18.x'
- run: npm i
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release_image.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:

steps:
- name: Checkout repository
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Log in to the Container registry
uses: docker/login-action@v2
Expand Down