Permalink
Browse files

Working on travis

  • Loading branch information...
1 parent 042e6ca commit f639e19b45fc9b0c65f617d271adf5c18a0f8789 @gcofficial gcofficial committed Mar 14, 2016
Showing with 834 additions and 562 deletions.
  1. +33 −0 .jscsrc
  2. +26 −0 .jshintignore
  3. +96 −0 .travis.yml
  4. 0 README.md
  5. +18 −17 cherry-core.php
  6. +24 −0 codesniffer.ruleset.xml
  7. +1 −0 i-module.php
  8. +48 −48 modules/cherry-breadcrumbs/cherry-breadcrumbs.php
  9. 0 modules/cherry-customizer/assets/fonts/google.json
  10. 0 modules/cherry-customizer/assets/fonts/standard.json
  11. +62 −29 modules/cherry-customizer/cherry-customizer.php
  12. +6 −7 modules/cherry-dynamic-css/cherry-dynamic-css.php
  13. +49 −50 modules/cherry-dynamic-css/inc/class-cherry-dynamic-css-utilities.php
  14. +3 −4 modules/cherry-google-fonts-loader/cherry-google-fonts-loader.php
  15. +2 −2 modules/cherry-js-core/assets/js/cherry-js-core.js
  16. 0 modules/cherry-js-core/assets/js/min/cherry-js-core.min.js
  17. +7 −77 modules/cherry-js-core/cherry-js-core.php
  18. +8 −2 modules/cherry-plugin-updater/cherry-plugin-updater.php
  19. +4 −4 modules/cherry-plugin-updater/inc/cherry-base-updater.php
  20. 0 modules/cherry-post-formats-api/assets/js/cherry-post-formats.js
  21. 0 modules/cherry-post-formats-api/assets/js/min/cherry-post-formats.min.js
  22. +21 −28 modules/cherry-post-formats-api/cherry-post-formats-api.php
  23. +1 −2 modules/cherry-post-formats-api/inc/class-cherry-facebook-embed.php
  24. +16 −15 modules/cherry-post-meta/cherry-post-meta.php
  25. +9 −3 modules/cherry-post-meta/views/meta.php
  26. +2 −1 modules/cherry-post-types/cherry-post-type.php
  27. +7 −6 modules/cherry-post-types/cherry-post-types.php
  28. +11 −11 modules/cherry-term-meta/cherry-term-meta.php
  29. +18 −11 modules/cherry-theme-updater/cherry-theme-updater.php
  30. +4 −4 modules/cherry-theme-updater/inc/cherry-base-updater.php
  31. +26 −12 modules/cherry-ui-elements/cherry-ui-elements.php
  32. +1 −0 modules/cherry-ui-elements/i-ui.php
  33. 0 modules/cherry-ui-elements/inc/ui-elements/ui-checkbox/assets/min/ui-checkbox.min.css
  34. 0 modules/cherry-ui-elements/inc/ui-elements/ui-checkbox/assets/min/ui-checkbox.min.js
  35. 0 modules/cherry-ui-elements/inc/ui-elements/ui-checkbox/assets/ui-checkbox.js
  36. 0 modules/cherry-ui-elements/inc/ui-elements/ui-checkbox/assets/ui-checkbox.scss
  37. +17 −10 modules/cherry-ui-elements/inc/ui-elements/ui-checkbox/ui-checkbox.php
  38. 0 modules/cherry-ui-elements/inc/ui-elements/ui-collection/assets/css/ui-collection.css
  39. 0 modules/cherry-ui-elements/inc/ui-elements/ui-collection/assets/js/jquery.collection.js
  40. 0 modules/cherry-ui-elements/inc/ui-elements/ui-collection/assets/js/min/jquery.collection.min.js
  41. 0 modules/cherry-ui-elements/inc/ui-elements/ui-collection/assets/js/min/ui-collection.min.js
  42. 0 modules/cherry-ui-elements/inc/ui-elements/ui-collection/assets/js/ui-collection.js
  43. +17 −14 modules/cherry-ui-elements/inc/ui-elements/ui-collection/ui-collection.php
  44. +12 −6 modules/cherry-ui-elements/inc/ui-elements/ui-collection/views/collection.php
  45. 0 modules/cherry-ui-elements/inc/ui-elements/ui-colorpicker/assets/min/ui-colorpicker.min.css
  46. 0 modules/cherry-ui-elements/inc/ui-elements/ui-colorpicker/assets/min/ui-colorpicker.min.js
  47. 0 modules/cherry-ui-elements/inc/ui-elements/ui-colorpicker/assets/ui-colorpicker.js
  48. 0 modules/cherry-ui-elements/inc/ui-elements/ui-colorpicker/assets/ui-colorpicker.scss
  49. +14 −6 modules/cherry-ui-elements/inc/ui-elements/ui-colorpicker/ui-colorpicker.php
  50. 0 modules/cherry-ui-elements/inc/ui-elements/ui-media/assets/min/ui-media.min.css
  51. 0 modules/cherry-ui-elements/inc/ui-elements/ui-media/assets/min/ui-media.min.js
  52. 0 modules/cherry-ui-elements/inc/ui-elements/ui-media/assets/ui-media.js
  53. 0 modules/cherry-ui-elements/inc/ui-elements/ui-media/assets/ui-media.scss
  54. +19 −11 modules/cherry-ui-elements/inc/ui-elements/ui-media/ui-media.php
  55. +6 −3 modules/cherry-ui-elements/inc/ui-elements/ui-number/ui-number.php
  56. 0 modules/cherry-ui-elements/inc/ui-elements/ui-radio/assets/min/ui-radio.min.css
  57. 0 modules/cherry-ui-elements/inc/ui-elements/ui-radio/assets/min/ui-radio.min.js
  58. 0 modules/cherry-ui-elements/inc/ui-elements/ui-radio/assets/ui-radio.js
  59. 0 modules/cherry-ui-elements/inc/ui-elements/ui-radio/assets/ui-radio.scss
  60. +20 −13 modules/cherry-ui-elements/inc/ui-elements/ui-radio/ui-radio.php
  61. 0 modules/cherry-ui-elements/inc/ui-elements/ui-select/assets/min/select2.min.js
  62. 0 modules/cherry-ui-elements/inc/ui-elements/ui-select/assets/min/ui-select.min.css
  63. 0 modules/cherry-ui-elements/inc/ui-elements/ui-select/assets/min/ui-select.min.js
  64. 0 modules/cherry-ui-elements/inc/ui-elements/ui-select/assets/select2.css
  65. 0 modules/cherry-ui-elements/inc/ui-elements/ui-select/assets/select2.js
  66. 0 modules/cherry-ui-elements/inc/ui-elements/ui-select/assets/ui-select.js
  67. 0 modules/cherry-ui-elements/inc/ui-elements/ui-select/assets/ui-select.scss
  68. +28 −21 modules/cherry-ui-elements/inc/ui-elements/ui-select/ui-select.php
  69. 0 modules/cherry-ui-elements/inc/ui-elements/ui-slider/assets/jquery-ui.css
  70. 0 modules/cherry-ui-elements/inc/ui-elements/ui-slider/assets/min/ui-slider.min.css
  71. 0 modules/cherry-ui-elements/inc/ui-elements/ui-slider/assets/min/ui-slider.min.js
  72. BIN ...-ui-elements/inc/ui-elements/ui-slider/assets/ui-images/ui-bg_diagonals-thick_18_b81900_40x40.png
  73. BIN ...-ui-elements/inc/ui-elements/ui-slider/assets/ui-images/ui-bg_diagonals-thick_20_666666_40x40.png
  74. BIN ...les/cherry-ui-elements/inc/ui-elements/ui-slider/assets/ui-images/ui-bg_flat_10_000000_40x100.png
  75. BIN ...es/cherry-ui-elements/inc/ui-elements/ui-slider/assets/ui-images/ui-bg_glass_100_f6f6f6_1x400.png
  76. BIN ...es/cherry-ui-elements/inc/ui-elements/ui-slider/assets/ui-images/ui-bg_glass_100_fdf5ce_1x400.png
  77. BIN ...les/cherry-ui-elements/inc/ui-elements/ui-slider/assets/ui-images/ui-bg_glass_65_ffffff_1x400.png
  78. BIN ...rry-ui-elements/inc/ui-elements/ui-slider/assets/ui-images/ui-bg_gloss-wave_35_f6a828_500x100.png
  79. BIN ...-ui-elements/inc/ui-elements/ui-slider/assets/ui-images/ui-bg_highlight-soft_100_eeeeee_1x100.png
  80. BIN ...y-ui-elements/inc/ui-elements/ui-slider/assets/ui-images/ui-bg_highlight-soft_75_ffe45c_1x100.png
  81. BIN modules/cherry-ui-elements/inc/ui-elements/ui-slider/assets/ui-images/ui-icons_222222_256x240.png
  82. BIN modules/cherry-ui-elements/inc/ui-elements/ui-slider/assets/ui-images/ui-icons_228ef1_256x240.png
  83. BIN modules/cherry-ui-elements/inc/ui-elements/ui-slider/assets/ui-images/ui-icons_ef8c08_256x240.png
  84. BIN modules/cherry-ui-elements/inc/ui-elements/ui-slider/assets/ui-images/ui-icons_ffd27a_256x240.png
  85. BIN modules/cherry-ui-elements/inc/ui-elements/ui-slider/assets/ui-images/ui-icons_ffffff_256x240.png
  86. 0 modules/cherry-ui-elements/inc/ui-elements/ui-slider/assets/ui-slider.js
  87. 0 modules/cherry-ui-elements/inc/ui-elements/ui-slider/assets/ui-slider.scss
  88. +14 −8 modules/cherry-ui-elements/inc/ui-elements/ui-slider/ui-slider.php
  89. 0 modules/cherry-ui-elements/inc/ui-elements/ui-stepper/assets/min/ui-stepper.min.css
  90. 0 modules/cherry-ui-elements/inc/ui-elements/ui-stepper/assets/min/ui-stepper.min.js
  91. 0 modules/cherry-ui-elements/inc/ui-elements/ui-stepper/assets/ui-stepper.js
  92. 0 modules/cherry-ui-elements/inc/ui-elements/ui-stepper/assets/ui-stepper.scss
  93. +12 −4 modules/cherry-ui-elements/inc/ui-elements/ui-stepper/ui-stepper.php
  94. 0 modules/cherry-ui-elements/inc/ui-elements/ui-switcher/assets/min/ui-switcher.min.css
  95. 0 modules/cherry-ui-elements/inc/ui-elements/ui-switcher/assets/min/ui-switcher.min.js
  96. 0 modules/cherry-ui-elements/inc/ui-elements/ui-switcher/assets/ui-switcher.js
  97. 0 modules/cherry-ui-elements/inc/ui-elements/ui-switcher/assets/ui-switcher.scss
  98. +17 −8 modules/cherry-ui-elements/inc/ui-elements/ui-switcher/ui-switcher.php
  99. 0 modules/cherry-ui-elements/inc/ui-elements/ui-text/assets/min/ui-text.min.css
  100. 0 modules/cherry-ui-elements/inc/ui-elements/ui-text/assets/ui-text.scss
  101. +14 −6 modules/cherry-ui-elements/inc/ui-elements/ui-text/ui-text.php
  102. 0 modules/cherry-ui-elements/inc/ui-elements/ui-textarea/assets/min/ui-textarea.min.css
  103. 0 modules/cherry-ui-elements/inc/ui-elements/ui-textarea/assets/ui-textarea.scss
  104. +14 −7 modules/cherry-ui-elements/inc/ui-elements/ui-textarea/ui-textarea.php
  105. +2 −1 modules/cherry-ui-elements/ui-element.php
  106. +12 −8 modules/cherry-utility/cherry-utility.php
  107. +26 −22 modules/cherry-utility/inc/cherry-attributes-utilit.php
  108. +28 −24 modules/cherry-utility/inc/cherry-media-utilit.php
  109. +30 −28 modules/cherry-utility/inc/cherry-meta-data-utilit.php
  110. +15 −11 modules/cherry-utility/inc/cherry-satellite-utilit.php
  111. +3 −3 modules/cherry-widget-factory/cherry-widget-factory.php
  112. +11 −15 modules/cherry-widget-factory/inc/class-cherry-abstract-widget.php
View
@@ -0,0 +1,33 @@
+{
+ "preset": "wordpress",
+ "fileExtensions": [ ".js" ],
+ "excludeFiles": [
+ "modules/cherry-ui-elements/inc/ui-elements/ui-switcher/assets/min/ui-switcher.min.js",
+ "modules/cherry-ui-elements/inc/ui-elements/ui-stepper/assets/min/ui-stepper.min.js",
+ "modules/cherry-ui-elements/inc/ui-elements/ui-slider/assets/min/ui-slider.min.js",
+ "modules/cherry-ui-elements/inc/ui-elements/ui-select/assets/min/ui-select.min.js",
+ "modules/cherry-ui-elements/inc/ui-elements/ui-select/assets/min/select2.min.js",
+ "modules/cherry-ui-elements/inc/ui-elements/ui-radio/assets/min/ui-radio.min.js",
+ "modules/cherry-ui-elements/inc/ui-elements/ui-media/assets/min/ui-media.min.js",
+ "modules/cherry-ui-elements/inc/ui-elements/ui-colorpicker/assets/min/ui-colorpicker.min.js",
+ "modules/cherry-js-core/assets/js/min/cherry-js-core.min.js",
+ "modules/cherry-js-core/assets/js/min/cherry-js-core.min.js",
+ "modules/cherry-js-core/assets/js/cherry-js-core.js",
+ "modules/cherry-post-formats-api/assets/js/cherry-post-formats.js",
+ "modules/cherry-post-formats-api/assets/js/min/cherry-post-formats.min.js",
+ "modules/cherry-ui-elements/inc/ui-elements/ui-checkbox/assets/min/ui-checkbox.min.js",
+ "modules/cherry-ui-elements/inc/ui-elements/ui-checkbox/assets/ui-checkbox.js",
+ "modules/cherry-ui-elements/inc/ui-elements/ui-colorpicker/assets/ui-colorpicker.js",
+ "modules/cherry-ui-elements/inc/ui-elements/ui-media/assets/ui-media.js",
+ "modules/cherry-ui-elements/inc/ui-elements/ui-radio/assets/ui-radio.js",
+ "modules/cherry-ui-elements/inc/ui-elements/ui-select/assets/select2.js",
+ "modules/cherry-ui-elements/inc/ui-elements/ui-select/assets/ui-select.js",
+ "modules/cherry-ui-elements/inc/ui-elements/ui-slider/assets/ui-slider.js",
+ "modules/cherry-ui-elements/inc/ui-elements/ui-stepper/assets/ui-stepper.js",
+ "modules/cherry-ui-elements/inc/ui-elements/ui-switcher/assets/ui-switcher.js",
+ "modules/cherry-ui-elements/inc/ui-elements/ui-collection/assets/js/min/ui-collection.min.js",
+ "modules/cherry-ui-elements/inc/ui-elements/ui-collection/assets/js/jquery.collection.js",
+ "modules/cherry-ui-elements/inc/ui-elements/ui-collection/assets/js/min/jquery.collection.min.js",
+ "modules/cherry-ui-elements/inc/ui-elements/ui-collection/assets/js/ui-collection.js",
+ ]
+}
View
@@ -0,0 +1,26 @@
+modules/cherry-ui-elements/inc/ui-elements/ui-switcher/assets/min/ui-switcher.min.js
+modules/cherry-ui-elements/inc/ui-elements/ui-stepper/assets/min/ui-stepper.min.js
+modules/cherry-ui-elements/inc/ui-elements/ui-slider/assets/min/ui-slider.min.js
+modules/cherry-ui-elements/inc/ui-elements/ui-select/assets/min/ui-select.min.js
+modules/cherry-ui-elements/inc/ui-elements/ui-select/assets/min/select2.min.js
+modules/cherry-ui-elements/inc/ui-elements/ui-radio/assets/min/ui-radio.min.js
+modules/cherry-ui-elements/inc/ui-elements/ui-media/assets/min/ui-media.min.js
+modules/cherry-ui-elements/inc/ui-elements/ui-colorpicker/assets/min/ui-colorpicker.min.js
+modules/cherry-js-core/assets/js/min/cherry-js-core.min.js
+modules/cherry-js-core/assets/js/cherry-js-core.js
+modules/cherry-post-formats-api/assets/js/cherry-post-formats.js
+modules/cherry-post-formats-api/assets/js/min/cherry-post-formats.min.js
+modules/cherry-ui-elements/inc/ui-elements/ui-checkbox/assets/min/ui-checkbox.min.js
+modules/cherry-ui-elements/inc/ui-elements/ui-checkbox/assets/ui-checkbox.js
+modules/cherry-ui-elements/inc/ui-elements/ui-colorpicker/assets/ui-colorpicker.js
+modules/cherry-ui-elements/inc/ui-elements/ui-media/assets/ui-media.js
+modules/cherry-ui-elements/inc/ui-elements/ui-radio/assets/ui-radio.js
+modules/cherry-ui-elements/inc/ui-elements/ui-select/assets/select2.js
+modules/cherry-ui-elements/inc/ui-elements/ui-select/assets/ui-select.js
+modules/cherry-ui-elements/inc/ui-elements/ui-slider/assets/ui-slider.js
+modules/cherry-ui-elements/inc/ui-elements/ui-stepper/assets/ui-stepper.js
+modules/cherry-ui-elements/inc/ui-elements/ui-switcher/assets/ui-switcher.js
+modules/cherry-ui-elements/inc/ui-elements/ui-collection/assets/js/min/ui-collection.min.js
+modules/cherry-ui-elements/inc/ui-elements/ui-collection/assets/js/jquery.collection.js
+modules/cherry-ui-elements/inc/ui-elements/ui-collection/assets/js/min/jquery.collection.min.js
+modules/cherry-ui-elements/inc/ui-elements/ui-collection/assets/js/ui-collection.js
View
@@ -0,0 +1,96 @@
+# Travis CI configuration file.
+# @link https://travis-ci.org/
+
+# For use with the Twenty Sixteen WordPress theme
+# @link https://github.com/WordPress/twentysixteen/
+
+# Declare project language and PHP versions to test against.
+# @link http://about.travis-ci.org/docs/user/languages/php/
+language: php
+
+# Declare versions of PHP to use. Use one decimal max.
+php:
+ - "7.0"
+ - "5.6"
+ - "5.5"
+ - "5.4"
+ - "5.3"
+ # Current $required_php_version for WordPress: 5.2.4
+ - "5.2"
+
+# Ditch sudo and use containers.
+# @link http://docs.travis-ci.com/user/migrating-from-legacy/#Why-migrate-to-container-based-infrastructure%3F
+# @link http://docs.travis-ci.com/user/workers/container-based-infrastructure/#Routing-your-build-to-container-based-infrastructure
+sudo: false
+
+# Declare which versions of WordPress to test against.
+# Also declare whether or not to test in Multisite.
+env:
+ # Trunk (current version in development is 4.4)
+ # @link https://github.com/WordPress/WordPress
+ - WP_VERSION=master WP_MULTISITE=0
+
+# Use this to prepare your build for testing.
+# e.g. copy database configurations, environment variables, etc.
+# Failures in this section will result in build status 'errored'.
+before_script:
+ # Set up WordPress installation.
+ - export WP_DEVELOP_DIR=/tmp/wordpress/
+ - mkdir -p $WP_DEVELOP_DIR
+ # Use the Git mirror of WordPress.
+ - git clone --depth=1 --branch="$WP_VERSION" git://develop.git.wordpress.org/ $WP_DEVELOP_DIR
+ # Set up Twenty Sixteen theme information.
+ - theme_slug=$(basename $(pwd))
+ - theme_dir=$WP_DEVELOP_DIR/src/wp-content/themes/$theme_slug
+ - cd ..
+ - mv $theme_slug $theme_dir
+ # Set up WordPress configuration.
+ - cd $WP_DEVELOP_DIR
+ - echo $WP_DEVELOP_DIR
+ - cp wp-tests-config-sample.php wp-tests-config.php
+ - sed -i "s/youremptytestdbnamehere/wordpress_test/" wp-tests-config.php
+ - sed -i "s/yourusernamehere/root/" wp-tests-config.php
+ - sed -i "s/yourpasswordhere//" wp-tests-config.php
+ # Create WordPress database.
+ - mysql -e 'CREATE DATABASE wordpress_test;' -uroot
+ # Install CodeSniffer for WordPress Coding Standards checks.
+ - mkdir php-codesniffer && curl -L https://github.com/squizlabs/PHP_CodeSniffer/archive/master.tar.gz | tar xz --strip-components=1 -C php-codesniffer
+ # Install WordPress Coding Standards.
+ - mkdir wordpress-coding-standards && curl -L https://github.com/WordPress-Coding-Standards/WordPress-Coding-Standards/archive/master.tar.gz | tar xz --strip-components=1 -C wordpress-coding-standards
+ # Hop into CodeSniffer directory.
+ - cd php-codesniffer
+ # Set install path for WordPress Coding Standards
+ # @link https://github.com/squizlabs/PHP_CodeSniffer/blob/4237c2fc98cc838730b76ee9cee316f99286a2a7/CodeSniffer.php#L1941
+ - scripts/phpcs --config-set installed_paths ../wordpress-coding-standards
+ # Hop into themes directory.
+ - cd $theme_dir
+ # After CodeSniffer install you should refresh your path.
+ - phpenv rehash
+ # Install JSCS: JavaScript Code Style checker
+ # @link http://jscs.info/
+ - npm install -g jscs
+ # Install JSHint, a JavaScript Code Quality Tool
+ # @link http://jshint.com/docs/
+ - npm install -g jshint
+ - wget https://develop.svn.wordpress.org/trunk/.jshintrc
+
+# Run test script commands.
+# Default is specific to project language.
+# All commands must exit with code 0 on success. Anything else is considered failure.
+script:
+ # Search theme for PHP syntax errors.
+ - find . \( -name '*.php' \) -exec php -lf {} \;
+ # Run the theme through JSHint
+ - jshint .
+ # Run the theme through JavaScript Code Style checker
+ - jscs .
+ # WordPress Coding Standards
+ # @link https://github.com/WordPress-Coding-Standards/WordPress-Coding-Standards
+ # @link http://pear.php.net/package/PHP_CodeSniffer/
+ # -p flag: Show progress of the run.
+ # -s flag: Show sniff codes in all reports.
+ # -v flag: Print verbose output.
+ # -n flag: Do not print warnings (shortcut for --warning-severity=0)
+ # --standard: Use WordPress as the standard.
+ # --extensions: Only sniff PHP files.
+ - $WP_DEVELOP_DIR/php-codesniffer/scripts/phpcs -p -s -v -n . --standard=./codesniffer.ruleset.xml --extensions=php
View
0 README.md 100644 → 100755
No changes.
View
35 cherry-core.php 100644 → 100755
@@ -1,5 +1,6 @@
<?php
/**
+ * Class Cherry Core
*
* @package Cherry_Framework
* @subpackage Class
@@ -15,7 +16,9 @@
}
if ( ! class_exists( 'Cherry_Core' ) ) {
-
+ /**
+ * Class Cherry Core
+ */
class Cherry_Core {
/**
@@ -48,10 +51,10 @@ class Cherry_Core {
public $modules = array();
/**
- * Cherry_Core constructor
- *
- * @since 1.0.0
- */
+ * Cherry_Core constructor
+ *
+ * @since 1.0.0
+ */
public function __construct( $settings = array() ) {
$default_settings = array(
@@ -110,11 +113,11 @@ private function autoload_modules() {
/**
* Init sinle module
*
- * @param string $module module slug.
+ * @param [type] $module module slug.
* @param array $args Module arguments array.
*
* @since 1.0.0
- * @return void
+ * @return mixed
*/
public function init_module( $module, $args = array() ) {
$hook = $module . '-module';
@@ -128,7 +131,7 @@ public function init_module( $module, $args = array() ) {
* @since 1.0.0
* @param bool|object $module_instance Module instnce to return, false at start.
* @param array $args Module rguments.
- * @param Cherry_Core $this Current core object.
+ * @param Cherry_Core $core_instance Current core object.
* @return object|bool
*/
public function pre_load( $module_instance, $args = array(), $core_instance ) {
@@ -148,7 +151,7 @@ public function pre_load( $module_instance, $args = array(), $core_instance ) {
/**
* Check module autoload.
*
- * @param string $module module slug.
+ * @param [type] $module module slug.
* @return boolean
*/
public function is_module_autoload( $module ) {
@@ -163,7 +166,7 @@ public function is_module_autoload( $module ) {
/**
* Include module.
*
- * @param string $module module slug.
+ * @param [type] $module module slug.
*
* @since 1.0.0
* @return bool
@@ -188,7 +191,7 @@ public function load_module( $module ) {
/**
* Get module instance.
*
- * @param string $module module slug.
+ * @param [type] $module module slug.
*
* @since 1.0.0
* @return object
@@ -208,7 +211,7 @@ public function get_module_instance( $module, $args ) {
/**
* Get class name by module slug.
*
- * @param string $slug Module slug.
+ * @param [type] $slug Module slug.
*
* @since 1.0.0
* @return string Class name
@@ -224,7 +227,7 @@ public function get_class_name( $slug = '' ) {
* Get path to main file for passed module
*
* @since 1.0.0
- * @param string $module module slug.
+ * @param [type] $module module slug.
* @return string
*/
public function get_module_path( $module ) {
@@ -237,7 +240,7 @@ public function get_module_path( $module ) {
* @since 1.0.0
* @return string
*/
- public function get_core_dir(){
+ public function get_core_dir() {
return trailingslashit( $this->settings['base_dir'] );
}
@@ -247,7 +250,7 @@ public function get_core_dir(){
* @since 1.0.0
* @return string
*/
- public function get_core_url(){
+ public function get_core_url() {
return trailingslashit( $this->settings['base_url'] );
}
@@ -300,7 +303,5 @@ public static function get_instance() {
return self::$instance;
}
-
}
-
}
@@ -0,0 +1,24 @@
+<?xml version="1.0"?>
+<ruleset name="WordPress Theme Coding Standards">
+ <!-- See https://github.com/squizlabs/PHP_CodeSniffer/wiki/Annotated-ruleset.xml -->
+ <!-- See https://github.com/WordPress-Coding-Standards/WordPress-Coding-Standards/blob/develop/WordPress-Core/ruleset.xml -->
+
+ <!-- Set a description for this ruleset. -->
+ <description>A custom set of code standard rules to check for WordPress themes.</description>
+
+ <!-- Include the WordPress ruleset, with space for exclusions if necessary. -->
+ <rule ref="WordPress-Core">
+ <exclude name="Generic.WhiteSpace.ScopeIndent.Incorrect" />
+ <exclude name="Generic.WhiteSpace.ScopeIndent.IncorrectExact" />
+
+ <exclude name="PEAR.Functions.FunctionCallSignature.Indent" />
+
+ <exclude name="Squiz.Commenting.FileComment.SpacingAfterComment" />
+ <exclude name="Squiz.Commenting.FunctionComment.MissingParamTag" />
+ <exclude name="Squiz.Commenting.InlineComment.InvalidEndChar" />
+ <exclude name="Squiz.Commenting.InlineComment.NotCapital" />
+ </rule>
+ <rule ref="WordPress-Docs">
+
+ </rule>
+</ruleset>
View
1 i-module.php 100644 → 100755
@@ -1,6 +1,7 @@
<?php
/**
* Module interface
+ *
* @package Cherry_Framework
* @subpackage Interface
* @author Cherry Team <cherryframework@gmail.com>
Oops, something went wrong.

0 comments on commit f639e19

Please sign in to comment.