Skip to content

Commit

Permalink
Merge branch '4.0-dev' into ops-plugins
Browse files Browse the repository at this point in the history
  • Loading branch information
wilsonge committed Jul 13, 2018
2 parents 5274bba + 5e1c182 commit 94e2cf5
Show file tree
Hide file tree
Showing 3,406 changed files with 73,188 additions and 43,887 deletions.
The diff you're trying to view is too large. We only load the first 3000 changed files.
2 changes: 1 addition & 1 deletion .drone.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ pipeline:
image: joomlaprojects/docker-phpcs
commands:
- echo $(date)
- /root/.composer/vendor/bin/phpcs --report=full --extensions=php -p --standard=build/phpcs/Joomla .
- /root/.composer/vendor/bin/phpcs --report=full --extensions=php -p --encoding=utf-8 --standard=build/phpcs/Joomla .
- echo $(date)

initdb:
Expand Down
12 changes: 8 additions & 4 deletions .eslintignore
Original file line number Diff line number Diff line change
@@ -1,4 +1,8 @@
# A list of files to ignore from linting
*.js
!*.es6.js
!build/**/*.js
# A list of files to ignore from linting
!*.es6.js
build/**/**/*.js ## Exclude webcomponents till we fix the CS!
*.vue
build/incompatible_page/*.js
media/system/webcomponents/js/*.js ## The linted files are in build/webcomponents!
media/com_media/js/edit-images.js ## TODO: Fix this file
media/mod_menu/js/admin-menu.js ## TODO: Fix this file
6 changes: 5 additions & 1 deletion .eslintrc
Original file line number Diff line number Diff line change
Expand Up @@ -15,9 +15,13 @@
},
// Rule overrides
"rules": {
// Disable no-params-reassign for properties
"no-param-reassign": ["error", { "props": false }],
// Allow usage of dev-dependencies in js files in build directory
"import/no-extraneous-dependencies": ["error", {"devDependencies": ["build/**/*.js"]}],
// Allow strict mode (we are not dealing with modules)
"strict": [0]
"strict": [0],
// Disable alert rule till we have a CE in place
"no-alert": 0
}
}
65 changes: 65 additions & 0 deletions .github/CODEOWNERS
Validating CODEOWNERS rules …
Original file line number Diff line number Diff line change
@@ -0,0 +1,65 @@
# Custom Fields
administrator/components/com_fields/* @laoneo
components/com_fields/* @laoneo
plugins/content/fields/* @laoneo
plugins/editors-xtd/fields/* @laoneo
plugins/fields/* @laoneo
plugins/systems/fields/* @laoneo

# Smart Search
administrator/components/com_finder/* @mbabker
components/com_finder/* @mbabker
modules/mod_finder/* @mbabker
plugins/content/finder/* @mbabker
plugins/finder/* @mbabker

# Language strings
administrator/language/en-GB/* @brianteeman
installation/language/en-GB/* @brianteeman
language/en-GB/* @brianteeman
README.md @brianteeman
README.txt @brianteeman

# CodeMirror
media/editors/codemirror/* @okonomiyaki3000
plugins/editors/codemirror/* @okonomiyaki3000

# Statistics Server
plugins/system/stats/* @mbabker @wilsonge

# Release Tools
build.xml @mbabker
build/build.php @mbabker @rdeutz @wilsonge
build/bump.php @mbabker @rdeutz @wilsonge
build/deleted_file_check.php @mbabker @rdeutz @wilsonge

# Core/Extension Install/Update Tools
administrator/components/com_joomlaupdate/* @mbabker @rdeutz @wilsonge @zero-24
libraries/src/Installer/* @mbabker @rdeutz @wilsonge @zero-24
libraries/src/Updater/* @mbabker @rdeutz @wilsonge @zero-24

# Automated Testing
build/jenkins/* @mbabker @rdeutz
build/travis/* @mbabker @rdeutz
tests/codeception/* @rdeutz
tests/javascript/* @dgt41 @rdeutz
tests/unit/* @mbabker @rdeutz
.appveyor.yml @mbabker @rdeutz
.drone.yml @rdeutz
.hound.yml @mbabker
.travis.yml @mbabker @rdeutz
appveyor-phpunit.xml @mbabker @rdeutz
codeception.yml @rdeutz
karma.conf.js @dgt41 @rdeutz
phpunit.xml.dist @mbabker @rdeutz
RoboFile.dist.ini @rdeutz
RoboFile.php @rdeutz
travis-phpunit.xml @mbabker @rdeutz

# Core JS
media/*/js/* @dgt41

# CSP Tooling
plugins/system/httpheaders/* @zero-24
administrator/components/com_csp/* @zero-24
components/com_csp/* @zero-24
12 changes: 9 additions & 3 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -31,9 +31,6 @@ node_modules/
/build/assets_tmp
/scss-lint-report.xml
/dev/assets/packages.json
# We are ignoring this as a temporary measure until Node 8 and npm5 become the LTS release
# and we can require it.
package-lock.json
yarn.lock

# Removed in Joomla 4 #
Expand Down Expand Up @@ -221,6 +218,11 @@ Desktop.ini
/libraries/vendor/simplepie/simplepie/build
/libraries/vendor/simplepie/simplepie/idn/ReadMe.txt
/libraries/vendor/simplepie/simplepie/composer.json
/libraries/vendor/wamania/php-stemmer/.gitignore
/libraries/vendor/wamania/php-stemmer/README.md
/libraries/vendor/wamania/php-stemmer/composer.json
/libraries/vendor/wamania/php-stemmer/phpunit.xml.dist
/libraries/vendor/wamania/php-stemmer/test
/libraries/vendor/zendframework/zend-diactoros/.coveralls.yml
/libraries/vendor/zendframework/zend-diactoros/CHANGELOG.md
/libraries/vendor/zendframework/zend-diactoros/composer.json
Expand Down Expand Up @@ -248,3 +250,7 @@ composer.phar

# Build related
RoboFile.ini

# Media Manager
/media/com_media/js/mediamanager.min.js.map
/media/com_media/css/mediamanager.min.css.map
6 changes: 6 additions & 0 deletions .hound.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,12 @@ fail_on_violations: true
scss:
config_file: scss-lint.yml

eslint:
enabled: true
config_file: .eslintrc
ignore_file: .eslintignore

# Disable hound default linters
jshint:
enabled: false

Expand Down
12 changes: 4 additions & 8 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,9 @@ Joomla! CMS™ [![Analytics](https://ga-beacon.appspot.com/UA-544070-3/joomla-cm

Build Status
---------------------
Travis-CI: [![Build Status](https://travis-ci.org/joomla/joomla-cms.svg?branch=staging)](https://travis-ci.org/joomla/joomla-cms)

Drone -CI: [![Build Status](http://213.160.72.75/api/badges/joomla/joomla-cms/status.svg)](http://213.160.72.75/joomla/joomla-cms)

AppVeyor: [![Build status](https://ci.appveyor.com/api/projects/status/bpcxulw6nnxlv8kb/branch/staging?svg=true)](https://ci.appveyor.com/project/joomla/joomla-cms)

Jenkins: [![Build Status](http://build.joomla.org/job/cms/badge/icon)](http://build.joomla.org/job/cms/)
| Travis-CI | Drone-CI | AppVeyor | Jenkins |
| ------------- | ------------- | ------------- | ------------- |
| [![Build Status](https://travis-ci.org/joomla/joomla-cms.svg?branch=staging)](https://travis-ci.org/joomla/joomla-cms) | [![Build Status](http://213.160.72.75/api/badges/joomla/joomla-cms/status.svg)](http://213.160.72.75/joomla/joomla-cms) | [![Build status](https://ci.appveyor.com/api/projects/status/bpcxulw6nnxlv8kb/branch/staging?svg=true)](https://ci.appveyor.com/project/joomla/joomla-cms) | [![Build Status](http://build.joomla.org/job/cms/badge/icon)](http://build.joomla.org/job/cms/) |

What is this?
---------------------
Expand Down Expand Up @@ -91,7 +87,7 @@ Do you want to improve Joomla?

Copyright
---------------------
* Copyright (C) 2005 - 2017 Open Source Matters. All rights reserved.
* Copyright (C) 2005 - 2018 Open Source Matters. All rights reserved.
* [Special Thanks](https://docs.joomla.org/Special:MyLanguage/Joomla!_Credits_and_Thanks)
* Distributed under the GNU General Public License version 2 or later
* See [License details](https://docs.joomla.org/Special:MyLanguage/Joomla_Licenses)
2 changes: 1 addition & 1 deletion README.txt
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@
* Documentation for Web designers: https://docs.joomla.org/Special:MyLanguage/Web_designers

Copyright:
* Copyright (C) 2005 - 2017 Open Source Matters. All rights reserved.
* Copyright (C) 2005 - 2018 Open Source Matters. All rights reserved.
* Special Thanks: https://docs.joomla.org/Special:MyLanguage/Joomla!_Credits_and_Thanks
* Distributed under the GNU General Public License version 2 or later
* See Licenses details at https://docs.joomla.org/Special:MyLanguage/Joomla_Licenses
84 changes: 64 additions & 20 deletions RoboFile.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
* @package Joomla.Site
* @subpackage RoboFile
*
* @copyright Copyright (C) 2005 - 2017 Open Source Matters, Inc. All rights reserved.
* @copyright Copyright (C) 2005 - 2018 Open Source Matters, Inc. All rights reserved.
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/

Expand Down Expand Up @@ -219,7 +219,7 @@ protected function copyJoomla($dst, $exclude = array())
/**
* Executes all the Selenium System Tests in a suite on your machine
*
* @param array $opts Array of configuration options:
* @param array $opts Array of configuration options:
* - 'use-htaccess': renames and enable embedded Joomla .htaccess file
* - 'env': set a specific environment to get configuration from
*
Expand All @@ -231,24 +231,7 @@ public function runTests($opts = ['use-htaccess' => false, 'env' => 'desktop'])
{
$this->say("Running tests");

$this->createTestingSite($opts['use-htaccess']);

$this->taskRunSelenium(self::SELENIUM_FOLDER, $this->getWebdriver())->run();

sleep(3);

// Make sure to run the build command to generate AcceptanceTester
if ($this->isWindows())
{
$this->_exec('php ' . $this->getWindowsPath($this->vendorPath . 'bin/codecept') . ' build');
$pathToCodeception = $this->getWindowsPath($this->vendorPath . 'bin/codecept');
}
else
{
$this->_exec('php ' . $this->vendorPath . 'bin/codecept build');

$pathToCodeception = $this->vendorPath . 'bin/codecept';
}
$pathToCodeception = $this->prepareRun($opts);

$suites = [
'acceptance/install/',
Expand All @@ -270,6 +253,65 @@ public function runTests($opts = ['use-htaccess' => false, 'env' => 'desktop'])
}
}

/**
* Install only Joomla
*
* @param array $opts Additional options
*
* @since __DEPLOY_VERSION__
*
* @return void
*/
public function runInstall($opts = ['use-htaccess' => false, 'env' => 'desktop'])
{
$this->say("Running Installation");

$pathToCodeception = $this->prepareRun($opts);

$this->taskCodecept($pathToCodeception)
->arg('--fail-fast')
->arg('--steps')
->arg('--debug')
->env($opts['env'])
->arg($this->testsPath . 'acceptance/install/')
->run()
->stopOnFail();
}

/**
* Prepare the installation
*
* @param array $opts Optional Options
*
* @return string Path to codeception
*
* @since __DEPLOY_VERSION__
*/
protected function prepareRun($opts = ['use-htaccess' => false, 'env' => 'desktop'])
{
$this->createTestingSite($opts['use-htaccess']);

$this->taskRunSelenium(self::SELENIUM_FOLDER, $this->getWebdriver())->run();

// Wait until the server started
sleep(3);

// Make sure to run the build command to generate AcceptanceTester
if ($this->isWindows())
{
$this->_exec('php ' . $this->getWindowsPath($this->vendorPath . 'bin/codecept') . ' build');
$pathToCodeception = $this->getWindowsPath($this->vendorPath . 'bin/codecept');
}
else
{
$this->_exec('php ' . $this->vendorPath . 'bin/codecept build');

$pathToCodeception = $this->vendorPath . 'bin/codecept';
}

return $pathToCodeception;
}

/**
* Executes a specific Selenium System Tests in your machine
*
Expand All @@ -278,6 +320,8 @@ public function runTests($opts = ['use-htaccess' => false, 'env' => 'desktop'])
*
* @since 3.7.3
*
* @throws Exception if test not found
*
* @return void
*/
public function runTest($pathToTestFile = null, $suite = 'acceptance')
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
* @package Joomla.Administrator
* @subpackage com_admin
*
* @copyright Copyright (C) 2005 - 2017 Open Source Matters, Inc. All rights reserved.
* @copyright Copyright (C) 2005 - 2018 Open Source Matters, Inc. All rights reserved.
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
namespace Joomla\Component\Admin\Administrator\Controller;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,14 +3,15 @@
* @package Joomla.Administrator
* @subpackage com_admin
*
* @copyright Copyright (C) 2005 - 2017 Open Source Matters, Inc. All rights reserved.
* @copyright Copyright (C) 2005 - 2018 Open Source Matters, Inc. All rights reserved.
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
namespace Joomla\Component\Admin\Administrator\Controller;

defined('_JEXEC') or die;

use Joomla\CMS\MVC\Controller\FormController;
use Joomla\CMS\Router\Route;

/**
* User profile controller class.
Expand Down Expand Up @@ -48,14 +49,14 @@ protected function allowEdit($data = array(), $key = 'id')
*/
public function save($key = null, $urlVar = null)
{
$this->setRedirect(\JRoute::_('index.php?option=com_admin&view=profile&layout=edit&id=' . $this->app->getIdentity()->id, false));
$this->setRedirect(Route::_('index.php?option=com_admin&view=profile&layout=edit&id=' . $this->app->getIdentity()->id, false));

$return = parent::save();

if ($this->getTask() != 'apply')
{
// Redirect to the main page.
$this->setRedirect(\JRoute::_('index.php', false));
$this->setRedirect(Route::_('index.php', false));
}

return $return;
Expand All @@ -75,7 +76,7 @@ public function cancel($key = null)
$return = parent::cancel($key);

// Redirect to the main page.
$this->setRedirect(\JRoute::_('index.php', false));
$this->setRedirect(Route::_('index.php', false));

return $return;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -3,37 +3,27 @@
* @package Joomla.Administrator
* @subpackage com_admin
*
* @copyright Copyright (C) 2005 - 2017 Open Source Matters, Inc. All rights reserved.
* @copyright Copyright (C) 2005 - 2018 Open Source Matters, Inc. All rights reserved.
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/

defined('_JEXEC') or die;
namespace Joomla\Component\Admin\Administrator\Dispatcher;

use Joomla\CMS\Dispatcher\Dispatcher;
defined('_JEXEC') or die;

/**
* Dispatcher class for com_admin
*
* @since 4.0.0
*/
class AdminDispatcher extends Dispatcher
class Dispatcher extends \Joomla\CMS\Dispatcher\Dispatcher
{
/**
* The extension namespace
*
* @var string
*
* @since 4.0.0
*/
protected $namespace = 'Joomla\\Component\\Admin';

/**
* com_admin does not require check permission, so we override checkAccess method and have it empty
*
* @return void
*/
protected function checkAccess()
{

}
}

0 comments on commit 94e2cf5

Please sign in to comment.