Skip to content

Commit e2a6e05

Browse files
Trotttargos
authored andcommitted
tools: apply linting to first commit in PRs
Use Travis-CI to check the formatting of the first commit in a pull request. This will hopefully reduce formatting errors and nits about them in pull requests. PR-URL: #22452 Reviewed-By: Weijia Wang <[email protected]> Reviewed-By: Trivikram Kamat <[email protected]> Reviewed-By: Michaël Zasso <[email protected]> Reviewed-By: Steven R Loomis <[email protected]>
1 parent f08373f commit e2a6e05

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

.travis.yml

+2
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,8 @@ matrix:
1212
- NODE=$(which node)
1313
script:
1414
- make lint
15+
# Lint the first commit in the PR.
16+
- git log HEAD ^$TRAVIS_BRANCH --pretty=format:'%h' --no-merges | tail -1 | xargs npx core-validate-commit --no-validate-metadata
1517
- name: "Test Suite"
1618
install:
1719
- ./configure

0 commit comments

Comments
 (0)