Various small improvements

This commit is contained in:
Daniel Rudolf 2017-06-20 17:32:09 +02:00
parent 793fcdb4e1
commit fd78ec38c7
No known key found for this signature in database
GPG key ID: A061F02CD8DE4538
3 changed files with 6 additions and 7 deletions

View file

@ -94,7 +94,7 @@ Version 1.0.0
* [Removed] ...
```
Before pushing a new Git tag, make sure to update the `Pico::VERSION` and `Pico::VERSION_ID` constants. If you've simultaneously developed a new version of Pico's official [default theme](https://github.com/picocms/pico-theme) and/or the [`PicoDeprecated` plugin](https://github.com/picocms/pico-deprecated), make sure to remove a previously added `@dev` suffix from the corresponding dependencies in Pico's [`composer.json`](https://github.com/picocms/Pico/blob/master/composer.json).
Before pushing a new Git tag, make sure to update the `Pico::VERSION` and `Pico::VERSION_ID` constants. If you've simultaneously developed a new version of Pico's official [default theme](https://github.com/picocms/pico-theme) and/or the [`PicoDeprecated` plugin](https://github.com/picocms/pico-deprecated), make sure to create releases for them first, otherwise automatic deployment will fail.
Travis CI will draft the new [release on GitHub](https://github.com/picocms/Pico/releases) automatically, but will require you to manually amend the descriptions formatting. The latest Pico version is always available at https://github.com/picocms/Pico/releases/latest, so please make sure to publish this URL rather than version-specific URLs. [Packagist](http://packagist.org/packages/picocms/pico) will be updated automatically.

View file

@ -3,7 +3,7 @@
set -e
# set COMPOSER_ROOT_VERSION when necessary
if [ -z "$TRAVIS_TAG" ] && [ "$TRAVIS_PULL_REQUEST" == "false" ]; then
if [ -z "$COMPOSER_ROOT_VERSION" ] && [ -z "$TRAVIS_TAG" ] && [ "$TRAVIS_PULL_REQUEST" == "false" ]; then
PICO_VERSION_PATTERN="$(php -r "
\$json = json_decode(file_get_contents('$TRAVIS_BUILD_DIR/composer.json'), true);
if (\$json !== null) {
@ -20,7 +20,7 @@ if [ -z "$TRAVIS_TAG" ] && [ "$TRAVIS_PULL_REQUEST" == "false" ]; then
")"
fi
if [ -z "$COMPOSER_ROOT_VERSION" ] && [ -n "$PICO_VERSION_PATTERN" ]; then
if [ -n "$PICO_VERSION_PATTERN" ]; then
export COMPOSER_ROOT_VERSION="$PICO_VERSION_PATTERN"
fi
fi

View file

@ -130,10 +130,9 @@ class PicoTwigExtension extends Twig_Extension
*
* This method is registered as the Twig `sort_by` filter. You can use this
* filter to e.g. sort the pages array by a arbitrary meta value. Calling
* `{{ pages|sort_by("meta:nav"|split(":")) }}` returns all pages sorted by
* the meta value `nav`. Please note the `"meta:nav"|split(":")` part of
* the example. The sorting algorithm will never assume equality of two
* values, it will then fall back to the original order. The result is
* `{{ pages|sort_by([ "meta", "nav" ]) }}` returns all pages sorted by the
* meta value `nav`. The sorting algorithm will never assume equality of
* two values, it will then fall back to the original order. The result is
* always sorted in ascending order, apply Twigs `reverse` filter to
* achieve a descending order.
*