move phpmd stuff to a script

This commit is contained in:
Andrew Dolgov 2017-04-26 15:33:01 +03:00
parent 7b55001eee
commit 2f3bce5960
2 changed files with 9 additions and 3 deletions

View File

@ -11,6 +11,5 @@ jobs:
when: manual
stage: test
script:
- phpmd include text utils/gitlab-ci/phpmd-ruleset.xml
- phpmd classes text utils/gitlab-ci/phpmd-ruleset.xml
- FILES=$(ls -dm *.php | sed "s/ //g") && phpmd $FILES text utils/gitlab-ci/phpmd-ruleset.xml
- sh utils/gitlab-ci/phpmd.sh

7
utils/gitlab-ci/phpmd.sh Normal file
View File

@ -0,0 +1,7 @@
#!/bin/sh -e
phpmd include text utils/gitlab-ci/phpmd-ruleset.xml
phpmd classes text utils/gitlab-ci/phpmd-ruleset.xml
FILES=$(ls -dm *.php | sed "s/ //g")
phpmd $FILES text utils/gitlab-ci/phpmd-ruleset.xml