Commit graph

882 commits

Author SHA1 Message Date
Daniel Rudolf
1aca13e83d
Version 2.1.2
```
* [Fixed] Fix DummyPlugin declaring API version 3
```
2020-04-10 23:18:00 +02:00
Daniel Rudolf
b892d6bb11
Update Pico::VERSION and Pico::VERSION_ID 2020-04-10 23:17:45 +02:00
Daniel Rudolf
0ddde859e8
Update CHANGELOG.md 2020-04-10 23:17:01 +02:00
Daniel Rudolf
6c746fabb6
Fix DummyPlugin declaring API version 3 2020-04-10 23:14:33 +02:00
Daniel Rudolf
af9c09e440
Add composer.json branch alias for Pico 3.0 2020-03-29 16:04:38 +02:00
Daniel Rudolf
5d6257feac
Update composer.json branch aliases 2020-03-29 14:35:52 +02:00
Daniel Rudolf
b49936fb3a
Version 2.1.1
```
* [Fixed] Require Parsedown 1.8.0-beta-7 and Parsedown Extra 0.8.0-beta-1 due
          to changes in Parsedown and Parsedown Extra breaking BC beyond repair
* [Changed] #523: Check for hidden pages based on page ID instead of full paths
* [Changed] Improve Pico docs
```
2019-12-31 16:33:55 +01:00
Daniel Rudolf
6672fb2277
Update Pico::VERSION and Pico::VERSION_ID 2019-12-31 16:33:45 +01:00
Daniel Rudolf
4c97f69ef8
Update CHANGELOG.md 2019-12-31 16:32:22 +01:00
Daniel Rudolf
8a44584291
Composer: Force Parsedown 1.8.0-beta-7 and Parsedown Extra 0.8.0-beta-1
A few days ago Parsedown released new ("stable") versions of Parsedown and Parsedown Extra: Parsedown 1.7.4 and Parsedown Extra 0.8.1. Parsedown 1.7.4 backports some features of Parsedown 1.8.0-beta-7 and is compatible with Parsedown Extra 0.8.1. However, due to these changes Parsedown Extra 0.8.1 now breaks compatibility with Parsedown 1.8.0-beta-7. Parsedown's release process is messed up beyond repair... Not sure what we're going to do now, this needs some research whether we can downgrade to Parsedown 1.7.4 without breaking things (what would require us to release a new major release, i.e. Pico 3.0). For now we're pinning Parsedown 1.8.0-beta-7 and Parsedown Extra 0.8.0-beta-1 as of Pico 2.1.0.
2019-12-31 16:25:52 +01:00
Daniel Rudolf
447479d973
Test hidden page requests on page ID
Fixes #523
2019-12-31 00:36:22 +01:00
Daniel Rudolf
1d250a2f7c
Travis CI: Switch to PHP 5.3 for branch deployment (just like release deployment) 2019-12-02 19:28:16 +01:00
Daniel Rudolf
86f82b930d
Travis CI: Update to Ubuntu Bionic, add HHVM 3.24 LTS 2019-12-02 19:22:57 +01:00
Daniel Rudolf
95146669f7
README.md: Add instructions for using a Git repo 2019-12-02 18:37:56 +01:00
Daniel Rudolf
ae1225f725
Travis CI: Add PHP 7.4 2019-11-30 16:43:00 +01:00
Daniel Rudolf
2661730ef5
CONTRIBUTING.md: Add `info: Pico CMS for Nextcloud\' label 2019-11-29 15:42:33 +01:00
Daniel Rudolf
41a4da5229
Merge pull request #515 from picocms/pico-2.1
This is **Pico 2.1 - small, but mighty!**

If you want to upgrade to Pico 2.1, simply follow the usual upgrade instructions for minor releases. Installing Pico is as easy as before. You can find more extensive upgrade instructions as well as a complete list of all additions and changes in Pico's [upgrade docs](http://picocms.org/in-depth/upgrade-pico-21/) - even though this is a minor release, it's still a lot of new and improved stuff!

You might also want to give [Pico CMS for Nextcloud `v1.0.0`](https://apps.nextcloud.com/apps/cms_pico) a try - it's now an official part of Pico. You can find more info at [picocms.org](http://picocms.org/plugins/#pico-cms-for-nextcloud)
2019-11-25 01:11:59 +01:00
Daniel Rudolf
232a90bdf8
Version 2.1.0
```
* [Changed] Add Pico's official logo and tagline to `content-sample/_meta.md`
* [Changed] Improve `content-sample/theme.md` to show Pico's official logo and
            the usage of the new image utility classes of Pico's default theme
* [Changed] Improve Pico docs and PHPDoc class docs
```
2019-11-25 00:43:58 +01:00
Daniel Rudolf
a87e40fbf0
Update Pico::VERSION 2019-11-25 00:43:58 +01:00
Daniel Rudolf
e4e249ae27
Update CHANGELOG.md 2019-11-25 00:43:58 +01:00
Daniel Rudolf
636e8d2a8a
Travis CI: Force Composer minimum stability <= beta
Unfortunately we must force Composer minimum stability <= beta due to Parsedown 1.8 currently being in beta. Composer AFAIK can't decide this on a per-dependency basis...
2019-11-25 00:43:53 +01:00
Daniel Rudolf
a5ff37e380
Travis CI: Remove 'sudo' requirement for branch deployment 2019-11-25 00:41:08 +01:00
Daniel Rudolf
b25225bbf4
README.md: Update screenshot 2019-11-24 23:40:51 +01:00
Daniel Rudolf
35bfdf51b7
Sample contents: Add usage of Pico's pages variable 2019-11-24 22:20:48 +01:00
Daniel Rudolf
bd0a257784
Update CHANGELOG.md 2019-11-23 19:45:11 +01:00
Daniel Rudolf
47d533982d
Replace Placeholder logo in content-sample/theme.md by Pico's logo
Also shows the new image utility classes of Pico's default theme

Co-Authored-By: type76 <osmanjaro@gmail.com>
2019-11-23 19:39:16 +01:00
Daniel Rudolf
558840643b
Add Pico's logo and tagline to the sample contents 2019-11-23 19:38:45 +01:00
Daniel Rudolf
cc6a478939
README: Mention requirement of PHP extensions 'dom' and 'mbstring'
Resolves #517
2019-11-18 16:49:08 +01:00
Daniel Rudolf
c02e3fa7a4
Various small improvements 2019-11-18 09:55:36 +01:00
Daniel Rudolf
03d466c117
Fix Pico's sample contents 2019-11-13 00:23:43 +01:00
Daniel Rudolf
c99f3cbbdf
Update @version phpDoc class docs 2019-11-11 19:02:11 +01:00
Daniel Rudolf
3b8d89fa30
composer.json: Adding myself as lead dev 2019-11-11 18:33:22 +01:00
Daniel Rudolf
420ede0daa
composer.json: Remove 'ext-dom' extension
Pico doesn't require 'ext-dom' itself, Parsedown Extra does; Parsedown Extra didn't declare this dependency before, but Parsedown Extra 0.8 finally does.
2019-11-10 17:24:25 +01:00
Daniel Rudolf
a04bc6c6b8
Version 2.1.0-beta.1
```
* [New] Add `assets_dir`, `assets_url` and `plugins_url` config params
* [New] Add `%config.*%` Markdown placeholders for scalar config params and the
        `%assets_url%`, `%themes_url%` and `%plugins_url%` placeholders
* [New] Add `content-sample/theme.md` for theme testing purposes
* [New] Introduce API versioning for themes and support theme-specific configs
        using the new `pico-theme.yml` in a theme's directory; `pico-theme.yml`
        allows a theme to influence Pico's Twig config, to register known meta
        headers and to provide defaults for theme config params
* [New] Add `assets_url`, `themes_url` and `plugins_url` Twig variables
* [New] Add `pages` Twig function to deal with Pico's page tree; this function
        replaces the raw usage of Pico's `pages` array in themes
* [New] Add `url` Twig filter to replace URL placeholders (e.g. `%base_url%`)
        in strings using the new `Pico::substituteUrl()` method
* [New] Add `onThemeLoading` and `onThemeLoaded` events
* [New] Add `debug` config param and the `Pico::isDebugModeEnabled()` method,
        cehcking the `PICO_DEBUG` environment variable, to enable debugging
* [New] Add new `Pico::getNormalizedPath()` method to normalize a path; this
        method should be used to prevent content dir breakouts when dealing
        with paths provided by user input
* [New] Add new `Pico::getUrlFromPath()` method to guess a URL from a file path
* [New] Add new `Pico::getAbsoluteUrl()` method to make a relative URL absolute
* [New] #505: Create pre-built `.zip` release archives
* [Fixed] #461: Proberly handle content files with a UTF-8 BOM
* [Changed] Introduce API version 3
* [Changed] Rename `theme_url` config param to `themes_url`; the `theme_url`
            Twig variable and Markdown placeholder are kept unchanged
* [Changed] Update to Parsedown Extra 0.8 and Parsedown 1.8 (both still beta)
* [Changed] Enable Twig's `autoescape` feature by default; outputting a
            variable now causes Twig to escape HTML markup; Pico's `content`
            variable is a notable exception, as it is marked as being HTML safe
* [Changed] Rename `prev_page` Twig variable to `previous_page`
* [Changed] Mark `markdown` and `content` Twig filters as being HTML safe
* [Changed] Add `$singleLine` param to `markdown` Twig filter as well as the
            `Pico::parseFileContent()` method to parse just a single line of
            Markdown input
* [Changed] Add `AbstractPicoPlugin::configEnabled()` method to check whether
            a plugin should be enabled or disabled based on Pico's config
* [Changed] Deprecate the use of `AbstractPicoPlugin::__call()`, use
            `PicoPluginInterface::getPico()` instead
* [Changed] Update to Twig 1.36 as last version supporting PHP 5.3, use a
            Composer-based installation to use a newer Twig version
* [Changed] Add `$basePath` and `$endSlash` params to `Pico::getAbsolutePath()`
* [Changed] Deprecate `Pico::getBaseThemeUrl()`
* [Changed] Replace various `file_exists` calls with proper `is_file` calls
* [Changed] Refactor release & build system
* [Changed] Improve PHP class docs
* [Changed] Various small improvements
* [Removed] Remove superfluous `base_dir` and `theme_dir` Twig variables
* [Removed] Remove `PicoPluginInterface::__construct()`
```
2019-11-04 01:49:11 +01:00
Daniel Rudolf
29f2e95160
Update Pico::VERSION 2019-11-04 01:49:11 +01:00
Daniel Rudolf
58ec760f04
Update CHANGELOG.md 2019-11-04 01:49:11 +01:00
Daniel Rudolf
db1c6301e6
Build system: Fix release package deployment 2019-11-04 01:49:03 +01:00
Daniel Rudolf
03d475c31c
Update Pico's sample contents to reflect the changes of Pico 2.1 2019-11-04 00:36:05 +01:00
Daniel Rudolf
dec44817a5
Build system: Add $PROJECT_REPO_TAG param to release.sh call 2019-11-03 21:18:28 +01:00
Daniel Rudolf
58f615403e
Refactor Build system
- Separate Travis branch deployment and release deployment stages (also makes `deploy.sh` obsolete)
- Add `clean.sh` and `release.sh` scripts to allow users to create "release" packages locally
- Use `setup/*.sh` scripts to check and install build dependencies (like PHP_CodeSniffer, phpDocumentor and cloc)
- Use `create-release.sh` of `picocms/ci-tools` to create release archives
- Streamline script usage

Use the following to test Pico and to create a "release" package locally:

```sh
cd ~/My-Pico-Workspace/Components/pico

ln -rs ../ci-tools .build/ci-tools

. ./.build/ci-tools/init/local.sh.inc
. ./.build/init.sh.inc

phpcs --standard=.phpcs.xml "$PICO_PROJECT_DIR"

clean.sh
release.sh
```
2019-11-03 20:03:48 +01:00
Daniel Rudolf
7bbd8736d1
Update CHANGELOG.md 2019-10-26 14:09:58 +02:00
Daniel Rudolf
e0415c8c1d
Mark Pico's content Twig variable as being safe
This no longer requires themes to output the `content` variable using `{{ content|raw }}`, theme developers can use `{{ content }}` as before.
2019-10-26 14:02:11 +02:00
Daniel Rudolf
3480a520d9
Build system: Use PHP 5.3 to create pre-built release packages
Otherwise Composer downloads a newer version of Twig which isn't compatible with PHP 5.3. Since we don't pin down specific versions of our dependencies, Composer-based installations might use newer versions of Twig which aren't compatible with PHP 5.3. Raising the PHP requirements requires a new major version, something that will definitly happen with Pico 3.0.
2019-10-26 14:00:45 +02:00
Daniel Rudolf
2a23edde4e
Fix code formatting 2019-10-26 11:34:58 +02:00
Daniel Rudolf
23000af64e
Add $singleLine param to Twig markdown parser
This allows you to parse just a single line of Markdown, i.e. the parsed output won't include a HTML paragraph element.
2019-10-24 13:03:38 +02:00
Daniel Rudolf
be0812fb55
Mark Twig content filter as HTML safe 2019-10-24 12:05:08 +02:00
Daniel Rudolf
cb3bdd149f
Mark Twig markdown filter as HTML safe 2019-10-24 12:02:23 +02:00
Daniel Rudolf
d2573c5df5
Fix $this->config['twig_config'] handling in Pico::loadTheme() 2019-10-20 19:17:42 +02:00
Daniel Rudolf
9c00ac4191
Travis CI: Remove not-yet-released PHP 7.4 2019-10-20 15:54:31 +02:00
Daniel Rudolf
b088555d17
Create .github/FUNDING.yml 2019-10-20 15:52:41 +02:00