mirror of https://github.com/ARMmbed/mbed-os.git
Corrected simplified astyle job behavior when base branch is not master
Consolidated efforts from PR #9336. Previous job's env vars would not be populated correctly if the base branch of a PR was not master. Corected by pulling remaining respository information to perform comparison between read-only instance of PR and base branch.pull/9346/head
parent
28d5477e50
commit
84469e1b6f
|
@ -144,9 +144,12 @@ matrix:
|
|||
export PATH=$PWD/bin:$PATH;
|
||||
cd -
|
||||
- astyle --version
|
||||
# Fetch remaining information needed for branch comparison
|
||||
- git fetch --all --unshallow --tags
|
||||
- git fetch origin "${TRAVIS_BRANCH}"
|
||||
script:
|
||||
- >-
|
||||
git diff --name-only --diff-filter=d HEAD..${TRAVIS_BRANCH} \
|
||||
git diff --name-only --diff-filter=d FETCH_HEAD..HEAD \
|
||||
| ( grep '.\(c\|cpp\|h\|hpp\)$' || true ) \
|
||||
| ( fgrep -v -f .astyleignore || true ) \
|
||||
| while read file; do astyle -n --options=.astylerc "${file}"; done
|
||||
|
|
Loading…
Reference in New Issue