mirror of
https://github.com/friendica/friendica
synced 2024-11-09 17:02:54 +00:00
Fixed CHANGED_FILES
This commit is contained in:
parent
3e0bcf7acd
commit
af135d4ad7
2 changed files with 12 additions and 2 deletions
|
@ -29,5 +29,10 @@ pipeline:
|
||||||
check:
|
check:
|
||||||
image: friendicaci/php-cs
|
image: friendicaci/php-cs
|
||||||
commands:
|
commands:
|
||||||
- export CHANGED_FILES="$(git diff --name-status ${CI_PREV_COMMIT_SHA}..${CI_COMMIT_SHA} | grep ^A | cut -f2)"
|
- if [ ! -z "$${CI_COMMIT_PULL_REQUEST}" ]; then
|
||||||
|
git fetch --no-tags origin ${CI_COMMIT_TARGET_BRANCH};
|
||||||
|
export CHANGED_FILES="$(git diff --name-status $(git merge-base FETCH_HEAD origin/${CI_COMMIT_TARGET_BRANCH})..${CI_COMMIT_SHA} | grep ^A | cut -f2)";
|
||||||
|
else
|
||||||
|
export CHANGED_FILES="$(git diff --name-status ${CI_COMMIT_SHA} | grep ^A | cut -f2)";
|
||||||
|
fi
|
||||||
- /check-php-cs.sh
|
- /check-php-cs.sh
|
||||||
|
|
|
@ -2,5 +2,10 @@ pipeline:
|
||||||
check:
|
check:
|
||||||
image: friendicaci/php-cs
|
image: friendicaci/php-cs
|
||||||
commands:
|
commands:
|
||||||
- export CHANGED_FILES="$(git diff --name-status ${CI_PREV_COMMIT_SHA}..${CI_COMMIT_SHA} | grep -i '\.php$' | cut -f2)"
|
- if [ ! -z "$${CI_COMMIT_PULL_REQUEST}" ]; then
|
||||||
|
git fetch --no-tags origin ${CI_COMMIT_TARGET_BRANCH};
|
||||||
|
export CHANGED_FILES="$(git diff --name-status $(git merge-base FETCH_HEAD origin/${CI_COMMIT_TARGET_BRANCH})..${CI_COMMIT_SHA} | grep -i '\.php$' | cut -f2)";
|
||||||
|
else
|
||||||
|
export CHANGED_FILES="$(git diff --name-status ${CI_COMMIT_SHA} | grep -i '\.php$' | cut -f2)";
|
||||||
|
fi
|
||||||
- /check-license.sh
|
- /check-license.sh
|
||||||
|
|
Loading…
Reference in a new issue