? Failure

User tests: Successful: Unsuccessful:

avatar javigomez
javigomez
11 Oct 2014

Do not merge, this is work in progress

This pull adds the PHP script that @mbabker did for com_localise in Joomla repo. This script is run by travis and it will do:

# When issues are detected Travis will fail
exit(1); 

screen shot 2014-10-11 at 18 27 11

# When no issues Travis will succed
exit(0);

screen shot 2014-10-11 at 18 22 33

If we are able to get rid of all the current code style issues in the CMS we will be able to merge this pull request and it will automatically check new Pull request failing when a code style issue is added.

avatar javigomez javigomez - open - 11 Oct 2014
avatar jissues-bot jissues-bot - change - 11 Oct 2014
Labels Added: ?
avatar mbabker
mbabker - comment - 11 Oct 2014

Ironically, the PHPCS checks have been working just fine since adding them into Travis, including failing the build. I don't think we'll need this script here, and could probably remove it in the com_localise repo and just use a standard PHPCS call.

avatar javigomez
javigomez - comment - 11 Oct 2014

But how would the standard PHPcs make travis fail is doing an exit(1)?

avatar mbabker
mbabker - comment - 11 Oct 2014
avatar javigomez
javigomez - comment - 11 Oct 2014

mmm, nice!

avatar javigomez
javigomez - comment - 11 Oct 2014

The benefit that I see with your Travis script is that you can do this specific ignores https://github.com/joomla/joomla-cms/pull/4528/files#diff-f1ccca0df89d1caecd8e66935074f7b7R30

How do you do that with the current script?

avatar mbabker
mbabker - comment - 11 Oct 2014

You just use the --ignore switch. So in the .travis.yml file we'd use something like phpcs --report=full --extensions=php -p --standard=build/phpcs/Joomla --ignore=administrator/components/*/views/*/tmpl/*,components/*/views/*/tmpl/*,layouts/* .

avatar javigomez
javigomez - comment - 11 Oct 2014

Ok, super! closing this one.

avatar javigomez javigomez - close - 11 Oct 2014
avatar javigomez javigomez - change - 11 Oct 2014
The description was changed
Title
Execute Code Style Checks in Travis
[Code Style] Execute Code Style Checks in Travis
Status Pending Closed
Closed_Date 0000-00-00 00:00:00 2014-10-11 17:18:57
avatar infograf768
infograf768 - comment - 12 Oct 2014

If any change to do in com_localise, please do. The amount of errors we get is enormous and some are useless.

Add a Comment

Login with GitHub to post a comment