Skip to content

Commit

Permalink
New module registration, add Dekode Coding Standards (#22)
Browse files Browse the repository at this point in the history
* Update module registration
* Set core requirement >=1.1.7
* Version bump to 1.1.3
* Add changelog for 1.1.3
* Lint fixes
* Add Dekode Coding Standards
* Update Travis conf
  • Loading branch information
stian-overasen committed Apr 5, 2018
1 parent 2ec700c commit 0a4491b
Show file tree
Hide file tree
Showing 10 changed files with 346 additions and 51 deletions.
9 changes: 4 additions & 5 deletions .travis.yml
Expand Up @@ -26,16 +26,15 @@ before_script:
fi
- |
if [[ "$WP_TRAVISCI" == "phpcs" ]] ; then
composer global require wp-coding-standards/wpcs
composer global require wimg/php-compatibility
phpcs --config-set installed_paths $HOME/.composer/vendor/wp-coding-standards/wpcs,$HOME/.composer/vendor/wimg/php-compatibility
composer install;
fi
script:
- |
if [[ "$WP_TRAVISCI" == "phpcs" ]] ; then
find -L . -name '*.php' -print0 | xargs -0 -n 1 -P 4 php -l
phpcs -p -s -v . --standard=./phpcs.xml --extensions=php --runtime-set testVersion $TRAVIS_PHP_VERSION
find . -name '*.php' ! -path "./vendor/*" ! -path "./wp-content/*" -print0 | xargs -0 -n 1 -P 4 php -l
echo Running phpcs for PHP version $TRAVIS_PHP_VERSION …
./vendor/bin/phpcs --runtime-set testVersion $TRAVIS_PHP_VERSION
fi
notifications:
Expand Down
5 changes: 5 additions & 0 deletions CHANGELOG.md
@@ -1,5 +1,10 @@
# Changelog

## 1.1.3
* Update module to new registration method introduced in [Hogan Core 1.1.7](https://github.com/DekodeInteraktiv/hogan-core/releases/tag/1.1.7)
* Set hogan-core dependency `"dekodeinteraktiv/hogan-core": ">=1.1.7"`
* Add Dekode Coding Standards.

## 1.1.2
* Add `$item` and `$this` to before and after text action [#19](https://github.com/DekodeInteraktiv/hogan-linklist/pull/19)
* Set link text if not set in WP link picker [#20](https://github.com/DekodeInteraktiv/hogan-linklist/pull/20)
Expand Down
2 changes: 1 addition & 1 deletion class-linklist.php
Expand Up @@ -129,7 +129,7 @@ public function get_fields() : array {
'type' => 'select',
'allow_null' => 1,
// Translators: %s: Link to navigation menu.
'instructions' => sprintf( __( 'A predefined menu must be created <a href="%s">here</a> in order to show up in this dropdown.', 'hogan-links' ), admin_url() . 'nav-menus.php' ),
'instructions' => sprintf( __( 'A predefined menu must be created <a href="%s">here</a> in order to show up in this dropdown.', 'hogan-linklist' ), admin_url() . 'nav-menus.php' ),
'choices' => [],
'ui' => 1,
'ajax' => 1,
Expand Down
11 changes: 10 additions & 1 deletion composer.json
Expand Up @@ -7,7 +7,7 @@
"require": {
"php": ">=7.0",
"composer/installers": "~1.2",
"dekodeinteraktiv/hogan-core": "^1.1.3"
"dekodeinteraktiv/hogan-core": ">=1.1.7"
},
"archive": {
"exclude": [
Expand All @@ -18,5 +18,14 @@
"LICENSE",
"phpcs.xml"
]
},
"require-dev": {
"dekodeinteraktiv/coding-standards": "^0.3.1"
},
"scripts": {
"test": [
"@composer install",
"./vendor/bin/phpcs"
]
}
}

0 comments on commit 0a4491b

Please sign in to comment.