ci: bring up lintTpl.sh

king_uim
SukkaW 7 years ago
parent 83188d564c
commit 0a0a861f37

4
.gitignore vendored

@ -33,4 +33,6 @@ storage/*.*
.user.ini
public/.user.ini
resources/views/material/analytics.tpl
resources/views/material/analytics.tpl
test/tpl_files.txt

@ -64,6 +64,10 @@ before_script:
- if [[ ! -n "$(git log -1 --pretty=%B | grep 'skip lint')" ]]; then
phplint '**/*.php' '!vendor/**';
fi
- chmod +x ./test/listTpl.sh
- if [[ ! -n "$(git log -1 --pretty=%B | grep 'skip lint')" ]]; then
./test/listTpl.sh
fi
script:
- cp config/.config.example.php config/.config.php
- php xcat createAdmin test@example.com test

@ -0,0 +1,10 @@
#!/bin/sh
find ./ -name "*.tpl" > ./test/tpl_files.txt
while read LINE
do
echo '--------------------------------------------------'
echo $LINE
echo '--------------------------------------------------'
./test/smart-lint/smart-lint "$LINE" y
done < ./test/tpl_files.txt
Loading…
Cancel
Save