Skip to content

Commit

Permalink
tools: apply linting to first commit in PRs
Browse files Browse the repository at this point in the history
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 <starkwang@126.com>
Reviewed-By: Trivikram Kamat <trivikr.dev@gmail.com>
Reviewed-By: Michaël Zasso <targos@protonmail.com>
Reviewed-By: Steven R Loomis <srloomis@us.ibm.com>
  • Loading branch information
Trott authored and targos committed Oct 7, 2018
1 parent f08373f commit e2a6e05
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,8 @@ matrix:
- NODE=$(which node)
script:
- make lint
# Lint the first commit in the PR.
- git log HEAD ^$TRAVIS_BRANCH --pretty=format:'%h' --no-merges | tail -1 | xargs npx core-validate-commit --no-validate-metadata
- name: "Test Suite"
install:
- ./configure
Expand Down

0 comments on commit e2a6e05

Please sign in to comment.