Merge pull request #11755 from jtraulle/stickler-ci
Add .stickler.yml config file
This commit is contained in:
commit
442793aa65
10
.stickler.yml
Normal file
10
.stickler.yml
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
---
|
||||||
|
linters:
|
||||||
|
phpcs:
|
||||||
|
standard: 'dev/setup/codesniffer/ruleset.xml'
|
||||||
|
extensions: 'php'
|
||||||
|
tab_width: 4
|
||||||
|
fixer: true
|
||||||
|
|
||||||
|
fixers:
|
||||||
|
enable: true
|
||||||
@ -293,12 +293,12 @@ script:
|
|||||||
echo
|
echo
|
||||||
|
|
||||||
- |
|
- |
|
||||||
echo "Checking coding style"
|
echo "Checking coding style (excluding Pull Requests builds)"
|
||||||
# Ensure we catch errors
|
# Ensure we catch errors
|
||||||
set -e
|
set -e
|
||||||
# Exclusions are defined in the ruleset.xml file
|
# Exclusions are defined in the ruleset.xml file
|
||||||
#phpcs -s -n -p -d memory_limit=-1 --colors --tab-width=4 --standard=dev/setup/codesniffer/ruleset.xml --encoding=utf-8 .
|
#phpcs -s -n -p -d memory_limit=-1 --colors --tab-width=4 --standard=dev/setup/codesniffer/ruleset.xml --encoding=utf-8 .
|
||||||
phpcs -s -p -d memory_limit=-1 --extensions=php --colors --tab-width=4 --standard=dev/setup/codesniffer/ruleset.xml --encoding=utf-8 --runtime-set ignore_warnings_on_exit true .
|
if [ "$TRAVIS_PULL_REQUEST" = "false" ]; then phpcs -s -p -d memory_limit=-1 --extensions=php --colors --tab-width=4 --standard=dev/setup/codesniffer/ruleset.xml --encoding=utf-8 --runtime-set ignore_warnings_on_exit true .; fi
|
||||||
set +e
|
set +e
|
||||||
echo
|
echo
|
||||||
|
|
||||||
|
|||||||
@ -646,7 +646,7 @@ class DiscountAbsolute
|
|||||||
$sql.= ' FROM '.MAIN_DB_PREFIX.'societe_remise_except as rc';
|
$sql.= ' FROM '.MAIN_DB_PREFIX.'societe_remise_except as rc';
|
||||||
$sql.= ' WHERE rc.fk_facture IS NULL AND rc.fk_facture_source = '.$invoice->id;
|
$sql.= ' WHERE rc.fk_facture IS NULL AND rc.fk_facture_source = '.$invoice->id;
|
||||||
}
|
}
|
||||||
else if ($invoice->element == 'invoice_supplier')
|
elseif ($invoice->element == 'invoice_supplier')
|
||||||
{
|
{
|
||||||
$sql = 'SELECT sum(rc.amount_ttc) as amount, sum(rc.multicurrency_amount_ttc) as multicurrency_amount';
|
$sql = 'SELECT sum(rc.amount_ttc) as amount, sum(rc.multicurrency_amount_ttc) as multicurrency_amount';
|
||||||
$sql.= ' FROM '.MAIN_DB_PREFIX.'societe_remise_except as rc';
|
$sql.= ' FROM '.MAIN_DB_PREFIX.'societe_remise_except as rc';
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user