mirror of
https://github.com/getgrav/grav.git
synced 2025-12-05 23:39:58 +01:00
Compare commits
108 Commits
1.0.0-rc.6
...
1.0.5
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
08cbd9553f | ||
|
|
dcaa9a35c3 | ||
|
|
4a80691e07 | ||
|
|
425831a7ae | ||
|
|
984e0455b1 | ||
|
|
00ecfb30f3 | ||
|
|
c18f20e483 | ||
|
|
71c5ff8c51 | ||
|
|
1996dd7de8 | ||
|
|
e87daa2361 | ||
|
|
987feb1385 | ||
|
|
8d048c689f | ||
|
|
139ef04e0a | ||
|
|
4c01e6c93e | ||
|
|
27744ba747 | ||
|
|
3d3c6f4eba | ||
|
|
fb4abc5f5f | ||
|
|
f29b141d69 | ||
|
|
1cecd09423 | ||
|
|
0142e76270 | ||
|
|
5f8c7f41ec | ||
|
|
451baff26e | ||
|
|
0e8e27877e | ||
|
|
d8a993bc86 | ||
|
|
ec7dbbdc8b | ||
|
|
e152cfd10f | ||
|
|
747daa46f1 | ||
|
|
17a0590ee4 | ||
|
|
653edb064b | ||
|
|
40f5d57737 | ||
|
|
566c5cb38f | ||
|
|
7e3058e3f0 | ||
|
|
053d8a3fd5 | ||
|
|
0e810c15e2 | ||
|
|
6b9154d1f3 | ||
|
|
4a5a400b89 | ||
|
|
2d7a3232cc | ||
|
|
96d7c4790f | ||
|
|
c0b9ada21c | ||
|
|
7b116b41ae | ||
|
|
fcdd0bc0e9 | ||
|
|
0619f7c656 | ||
|
|
f7696b61d3 | ||
|
|
48083b203a | ||
|
|
f8aa9fed91 | ||
|
|
c55521ac4a | ||
|
|
2bb23efa7c | ||
|
|
cdcb76cc55 | ||
|
|
def726a012 | ||
|
|
7d1291e2b9 | ||
|
|
a0297e9d65 | ||
|
|
e4e0c06ea8 | ||
|
|
f46ad2d032 | ||
|
|
0c807b6108 | ||
|
|
3a47d6a580 | ||
|
|
52947b3a2c | ||
|
|
eacfc798f4 | ||
|
|
5c0e5f3c01 | ||
|
|
985141b842 | ||
|
|
1aac2ab95d | ||
|
|
aa7d5ddf59 | ||
|
|
e87505378d | ||
|
|
53f097c2b3 | ||
|
|
6ea7fe9dba | ||
|
|
0206f1b0c7 | ||
|
|
ef9f2c77dd | ||
|
|
822292f541 | ||
|
|
ec08cd9374 | ||
|
|
8fb4063cf2 | ||
|
|
8a2b444c48 | ||
|
|
9c6f243902 | ||
|
|
d5bd99b363 | ||
|
|
5554c07cbf | ||
|
|
acd95aac6f | ||
|
|
8ad5f2624d | ||
|
|
8adc0e1c17 | ||
|
|
fab66cf3a5 | ||
|
|
5df48e7a68 | ||
|
|
079a8c5728 | ||
|
|
d9196426a1 | ||
|
|
2f686f5b74 | ||
|
|
c4b5df20a9 | ||
|
|
06608a6d3c | ||
|
|
fd63911faf | ||
|
|
66a1e55867 | ||
|
|
af2eb2e75d | ||
|
|
9b4f32cafd | ||
|
|
9179fbd1a2 | ||
|
|
24ea7f1f55 | ||
|
|
9b95053110 | ||
|
|
71ffb9c72f | ||
|
|
f29f698f61 | ||
|
|
f1f8579a0b | ||
|
|
4ca8fab750 | ||
|
|
b80ed731b0 | ||
|
|
23a9a73600 | ||
|
|
dc8c0b6522 | ||
|
|
e695b1942c | ||
|
|
3f543e7e84 | ||
|
|
7f6f9e82e3 | ||
|
|
51529eb0ce | ||
|
|
05b24a4b75 | ||
|
|
ca5819489f | ||
|
|
1d2acf8096 | ||
|
|
98278e965b | ||
|
|
7bc990688c | ||
|
|
b86aa6d473 | ||
|
|
fa52e18e3f |
2
.gitignore
vendored
2
.gitignore
vendored
@@ -16,6 +16,8 @@ logs/*
|
||||
!logs/.*
|
||||
images/*
|
||||
!images/.*
|
||||
user/accounts/*
|
||||
!user/accounts/.*
|
||||
user/data/*
|
||||
!user/data/.*
|
||||
user/plugins/*
|
||||
|
||||
@@ -40,8 +40,10 @@ env:
|
||||
- TRAVIS_TAG=$(curl --fail --user ${GH_API_USER} -s https://api.github.com/repos/getgrav/grav/releases/latest | grep tag_name | head -n 1 | cut -d '"' -f 4)
|
||||
|
||||
before_install:
|
||||
- export TZ=Pacific/Honolulu
|
||||
- composer self-update
|
||||
- go get github.com/aktau/github-release
|
||||
- echo "Travis Date: `date`"
|
||||
- git clone --quiet --depth=50 --branch=master https://${BB_TOKEN}bitbucket.org/rockettheme/grav-devtools.git $RT_DEVTOOLS &>/dev/null;
|
||||
- if [ ! -z "$TRAVIS_TAG" ]; then
|
||||
cd "${RT_DEVTOOLS}";
|
||||
|
||||
76
CHANGELOG.md
76
CHANGELOG.md
@@ -1,3 +1,77 @@
|
||||
# v1.0.5
|
||||
## 12/18/2015
|
||||
|
||||
1. [](#new)
|
||||
* Add ability to extend markdown with plugins
|
||||
* Added support for plugins to have individual language files
|
||||
* Added `7z` to media formats
|
||||
* Use Grav's fork of Parsedown until PR is merged
|
||||
* New function to persist plugin configuration to disk
|
||||
* GPM `selfupgrade` will now check PHP version requirements
|
||||
1. [](#improved)
|
||||
* If the field allows multiple files, return array
|
||||
* Handle non-array values in file validation
|
||||
1. [](#bugfix)
|
||||
* Fix when looping `fields` param in a `list` field
|
||||
* Properly convert commas to spaces for media attributes
|
||||
* Forcing Travis VM to HI timezone to address future files in zip file
|
||||
|
||||
# v1.0.4
|
||||
## 12/12/2015
|
||||
|
||||
1. [](#bugfix)
|
||||
* Needed to put default image folder permissions for YAML compatibility
|
||||
|
||||
# v1.0.3
|
||||
## 12/11/2015
|
||||
|
||||
1. [](#bugfix)
|
||||
* Fixed issue when saving config causing incorrect image cache folder perms
|
||||
|
||||
# v1.0.2
|
||||
## 12/11/2015
|
||||
|
||||
1. [](#bugfix)
|
||||
* Fix for timing display in debugbar
|
||||
|
||||
# v1.0.1
|
||||
## 12/11/2015
|
||||
|
||||
1. [](#improved)
|
||||
* Reduced package sizes by removing extra vendor dev bits
|
||||
1. [](#bugfix)
|
||||
* Fix issue when you enable debugger from admin plugin
|
||||
|
||||
# v1.0.0
|
||||
## 12/11/2015
|
||||
|
||||
1. [](#new)
|
||||
* Add new link attributes via markdown media
|
||||
* Added setters to set state of CSS/JS pipelining
|
||||
* Added `user/accounts` to `.gitignore`
|
||||
* Added configurable permissions option for Image cache
|
||||
1. [](#improved)
|
||||
* Hungarian translation updated
|
||||
* Refactored Theme initialization for improved flexibility
|
||||
* Wrapped security section of account blueprints in an 'super user' authorize check
|
||||
* Minor performance optimizations
|
||||
* Updated core page blueprints with markdown preview option
|
||||
* Added useful cache info output to Debugbar
|
||||
* Added `iconv` polyfill library used by Symfony 2.8
|
||||
* Force lowercase of username in a few places for case sensitive filesystems
|
||||
1. [](#bugfix)
|
||||
* Fix for GPM problems "Call to a member function set() on null"
|
||||
* Fix for individual asset pipeline values not functioning
|
||||
* Fix `Page::copy()` and `Page::move()` to support multiple moves at once
|
||||
* Fixed page moving of a page with no content
|
||||
* Fix for wrong ordering when moving many pages
|
||||
* Escape root path in page medium files to work with special characters
|
||||
* Add missing parent constructor to Themes class
|
||||
* Fix missing file error in `bin/grav sandbox` command
|
||||
* Fixed changelog differ when upgrading Grav
|
||||
* Fixed a logic error in `Validation->validate()`
|
||||
* Make `$container` available in `setup.php` to fix multi-site
|
||||
|
||||
# v1.0.0-rc.6
|
||||
## 12/01/2015
|
||||
|
||||
@@ -78,7 +152,7 @@
|
||||
|
||||
1. [](#new)
|
||||
* New Page collection options! `@self.parent, @self.siblings, @self.descendants` + more
|
||||
* Whitelist of file types for fallback route functionality (images by default)
|
||||
* White list of file types for fallback route functionality (images by default)
|
||||
1. [](#improved)
|
||||
* Assets switched from defines to streams
|
||||
1. [](#bugfix)
|
||||
|
||||
@@ -103,7 +103,7 @@ What you mainly want to know is that:
|
||||
|
||||
# License
|
||||
|
||||
See [LICENSE](LICENSE)
|
||||
See [LICENSE](LICENSE.txt)
|
||||
|
||||
|
||||
[gitflow-model]: http://nvie.com/posts/a-successful-git-branching-model/
|
||||
|
||||
2
bin/gpm
2
bin/gpm
@@ -40,8 +40,6 @@ if (!function_exists('curl_version')) {
|
||||
$grav = Grav::instance(array('loader' => $autoload));
|
||||
$grav['config']->init();
|
||||
$grav['streams'];
|
||||
$grav['plugins']->init();
|
||||
$grav['themes']->init();
|
||||
|
||||
$app = new Application('Grav Package Manager', GRAV_VERSION);
|
||||
$app->addCommands(array(
|
||||
|
||||
@@ -7,14 +7,16 @@
|
||||
"license": "MIT",
|
||||
"require": {
|
||||
"php": ">=5.4.0",
|
||||
"twig/twig": "~1.16",
|
||||
"twig/twig": "~1.23",
|
||||
"erusev/parsedown": "dev-master as 1.6.0",
|
||||
"erusev/parsedown-extra": "~0.7",
|
||||
"symfony/yaml": "~2.7",
|
||||
"symfony/console": "~2.7",
|
||||
"symfony/event-dispatcher": "~2.7",
|
||||
"symfony/var-dumper": "~2.7",
|
||||
"doctrine/cache": "~1.4",
|
||||
"filp/whoops": "1.2.*@dev",
|
||||
"symfony/yaml": "~2.8",
|
||||
"symfony/console": "~2.8",
|
||||
"symfony/event-dispatcher": "~2.8",
|
||||
"symfony/var-dumper": "~2.8",
|
||||
"symfony/polyfill-iconv": "~1.0",
|
||||
"doctrine/cache": "~1.5",
|
||||
"filp/whoops": "1.1.10",
|
||||
"monolog/monolog": "~1.0",
|
||||
"gregwar/image": "~2.0",
|
||||
"ircmaxell/password-compat": "1.0.*",
|
||||
@@ -24,6 +26,12 @@
|
||||
"rockettheme/toolbox": "~1.2",
|
||||
"maximebf/debugbar": "~1.10"
|
||||
},
|
||||
"repositories": [
|
||||
{
|
||||
"type": "vcs",
|
||||
"url": "https://github.com/getgrav/parsedown"
|
||||
}
|
||||
],
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
"Grav\\": "system/src/Grav"
|
||||
|
||||
268
composer.lock
generated
268
composer.lock
generated
@@ -1,23 +1,24 @@
|
||||
{
|
||||
"_readme": [
|
||||
"This file locks the dependencies of your project to a known state",
|
||||
"Read more about it at http://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file",
|
||||
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file",
|
||||
"This file is @generated automatically"
|
||||
],
|
||||
"hash": "b1323e540382de7390663756b3a87de7",
|
||||
"hash": "82d333365d7424d73da22f99a2daa42c",
|
||||
"content-hash": "6d876da7dbe11934a98374e67d15550c",
|
||||
"packages": [
|
||||
{
|
||||
"name": "doctrine/cache",
|
||||
"version": "v1.5.1",
|
||||
"version": "v1.5.2",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/doctrine/cache.git",
|
||||
"reference": "2b9cec5a5e722010cbebc91713d4c11eaa064d5e"
|
||||
"reference": "47c7128262da274f590ae6f86eb137a7a64e82af"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/doctrine/cache/zipball/2b9cec5a5e722010cbebc91713d4c11eaa064d5e",
|
||||
"reference": "2b9cec5a5e722010cbebc91713d4c11eaa064d5e",
|
||||
"url": "https://api.github.com/repos/doctrine/cache/zipball/47c7128262da274f590ae6f86eb137a7a64e82af",
|
||||
"reference": "47c7128262da274f590ae6f86eb137a7a64e82af",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
@@ -74,7 +75,7 @@
|
||||
"cache",
|
||||
"caching"
|
||||
],
|
||||
"time": "2015-11-02 18:35:48"
|
||||
"time": "2015-12-03 10:50:37"
|
||||
},
|
||||
{
|
||||
"name": "donatj/phpuseragentparser",
|
||||
@@ -129,16 +130,16 @@
|
||||
},
|
||||
{
|
||||
"name": "erusev/parsedown",
|
||||
"version": "1.6.0",
|
||||
"version": "dev-master",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/erusev/parsedown.git",
|
||||
"reference": "3ebbd730b5c2cf5ce78bc1bf64071407fc6674b7"
|
||||
"url": "https://github.com/getgrav/parsedown.git",
|
||||
"reference": "10a7ff776c3f16b1b3aa41c176c48150fc091065"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/erusev/parsedown/zipball/3ebbd730b5c2cf5ce78bc1bf64071407fc6674b7",
|
||||
"reference": "3ebbd730b5c2cf5ce78bc1bf64071407fc6674b7",
|
||||
"url": "https://api.github.com/repos/getgrav/parsedown/zipball/10a7ff776c3f16b1b3aa41c176c48150fc091065",
|
||||
"reference": "10a7ff776c3f16b1b3aa41c176c48150fc091065",
|
||||
"shasum": ""
|
||||
},
|
||||
"type": "library",
|
||||
@@ -147,7 +148,6 @@
|
||||
"Parsedown": ""
|
||||
}
|
||||
},
|
||||
"notification-url": "https://packagist.org/downloads/",
|
||||
"license": [
|
||||
"MIT"
|
||||
],
|
||||
@@ -164,7 +164,10 @@
|
||||
"markdown",
|
||||
"parser"
|
||||
],
|
||||
"time": "2015-10-04 16:44:32"
|
||||
"support": {
|
||||
"source": "https://github.com/getgrav/parsedown/tree/master"
|
||||
},
|
||||
"time": "2015-12-17 17:48:21"
|
||||
},
|
||||
{
|
||||
"name": "erusev/parsedown-extra",
|
||||
@@ -212,20 +215,20 @@
|
||||
},
|
||||
{
|
||||
"name": "filp/whoops",
|
||||
"version": "dev-master",
|
||||
"version": "1.1.10",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/filp/whoops.git",
|
||||
"reference": "9a393ceb80f7497b6513feb574638e87048fed55"
|
||||
"reference": "72538eeb70bbfb11964412a3d098d109efd012f7"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/filp/whoops/zipball/9a393ceb80f7497b6513feb574638e87048fed55",
|
||||
"reference": "9a393ceb80f7497b6513feb574638e87048fed55",
|
||||
"url": "https://api.github.com/repos/filp/whoops/zipball/72538eeb70bbfb11964412a3d098d109efd012f7",
|
||||
"reference": "72538eeb70bbfb11964412a3d098d109efd012f7",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"php": ">=5.3.3"
|
||||
"php": ">=5.3.0"
|
||||
},
|
||||
"require-dev": {
|
||||
"mockery/mockery": "0.9.*"
|
||||
@@ -266,7 +269,7 @@
|
||||
"whoops",
|
||||
"zf2"
|
||||
],
|
||||
"time": "2015-09-27 09:47:06"
|
||||
"time": "2015-06-29 05:42:04"
|
||||
},
|
||||
{
|
||||
"name": "gregwar/cache",
|
||||
@@ -403,25 +406,25 @@
|
||||
},
|
||||
{
|
||||
"name": "maximebf/debugbar",
|
||||
"version": "v1.10.5",
|
||||
"version": "v1.11.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/maximebf/php-debugbar.git",
|
||||
"reference": "30e53e8a28284b69dd223c9f5ee8957befd72636"
|
||||
"reference": "07741d84d39d10f00551c94284cdefcc69703e77"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/maximebf/php-debugbar/zipball/30e53e8a28284b69dd223c9f5ee8957befd72636",
|
||||
"reference": "30e53e8a28284b69dd223c9f5ee8957befd72636",
|
||||
"url": "https://api.github.com/repos/maximebf/php-debugbar/zipball/07741d84d39d10f00551c94284cdefcc69703e77",
|
||||
"reference": "07741d84d39d10f00551c94284cdefcc69703e77",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"php": ">=5.3.0",
|
||||
"psr/log": "~1.0",
|
||||
"symfony/var-dumper": "~2.6"
|
||||
"psr/log": "^1.0",
|
||||
"symfony/var-dumper": "^2.6|^3.0"
|
||||
},
|
||||
"require-dev": {
|
||||
"phpunit/phpunit": "~4.0"
|
||||
"phpunit/phpunit": "^4.0|^5.0"
|
||||
},
|
||||
"suggest": {
|
||||
"kriswallsmith/assetic": "The best way to manage assets",
|
||||
@@ -431,12 +434,12 @@
|
||||
"type": "library",
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
"dev-master": "1.10-dev"
|
||||
"dev-master": "1.11-dev"
|
||||
}
|
||||
},
|
||||
"autoload": {
|
||||
"psr-0": {
|
||||
"DebugBar": "src/"
|
||||
"psr-4": {
|
||||
"DebugBar\\": "src/DebugBar/"
|
||||
}
|
||||
},
|
||||
"notification-url": "https://packagist.org/downloads/",
|
||||
@@ -448,14 +451,19 @@
|
||||
"name": "Maxime Bouroumeau-Fuseau",
|
||||
"email": "maxime.bouroumeau@gmail.com",
|
||||
"homepage": "http://maximebf.com"
|
||||
},
|
||||
{
|
||||
"name": "Barry vd. Heuvel",
|
||||
"email": "barryvdh@gmail.com"
|
||||
}
|
||||
],
|
||||
"description": "Debug bar in the browser for php application",
|
||||
"homepage": "https://github.com/maximebf/php-debugbar",
|
||||
"keywords": [
|
||||
"debug"
|
||||
"debug",
|
||||
"debugbar"
|
||||
],
|
||||
"time": "2015-10-19 20:35:12"
|
||||
"time": "2015-12-10 09:50:24"
|
||||
},
|
||||
{
|
||||
"name": "monolog/monolog",
|
||||
@@ -714,25 +722,26 @@
|
||||
},
|
||||
{
|
||||
"name": "symfony/console",
|
||||
"version": "v2.7.7",
|
||||
"version": "v2.8.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/symfony/console.git",
|
||||
"reference": "16bb1cb86df43c90931df65f529e7ebd79636750"
|
||||
"reference": "d232bfc100dfd32b18ccbcab4bcc8f28697b7e41"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/symfony/console/zipball/16bb1cb86df43c90931df65f529e7ebd79636750",
|
||||
"reference": "16bb1cb86df43c90931df65f529e7ebd79636750",
|
||||
"url": "https://api.github.com/repos/symfony/console/zipball/d232bfc100dfd32b18ccbcab4bcc8f28697b7e41",
|
||||
"reference": "d232bfc100dfd32b18ccbcab4bcc8f28697b7e41",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"php": ">=5.3.9"
|
||||
"php": ">=5.3.9",
|
||||
"symfony/polyfill-mbstring": "~1.0"
|
||||
},
|
||||
"require-dev": {
|
||||
"psr/log": "~1.0",
|
||||
"symfony/event-dispatcher": "~2.1",
|
||||
"symfony/process": "~2.1"
|
||||
"symfony/event-dispatcher": "~2.1|~3.0.0",
|
||||
"symfony/process": "~2.1|~3.0.0"
|
||||
},
|
||||
"suggest": {
|
||||
"psr/log": "For using the console logger",
|
||||
@@ -742,7 +751,7 @@
|
||||
"type": "library",
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
"dev-master": "2.7-dev"
|
||||
"dev-master": "2.8-dev"
|
||||
}
|
||||
},
|
||||
"autoload": {
|
||||
@@ -769,20 +778,20 @@
|
||||
],
|
||||
"description": "Symfony Console Component",
|
||||
"homepage": "https://symfony.com",
|
||||
"time": "2015-11-18 09:54:26"
|
||||
"time": "2015-11-30 12:35:10"
|
||||
},
|
||||
{
|
||||
"name": "symfony/event-dispatcher",
|
||||
"version": "v2.7.7",
|
||||
"version": "v2.8.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/symfony/event-dispatcher.git",
|
||||
"reference": "7e2f9c31645680026c2372edf66f863fc7757af5"
|
||||
"reference": "a5eb815363c0388e83247e7e9853e5dbc14999cc"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/7e2f9c31645680026c2372edf66f863fc7757af5",
|
||||
"reference": "7e2f9c31645680026c2372edf66f863fc7757af5",
|
||||
"url": "https://api.github.com/repos/symfony/event-dispatcher/zipball/a5eb815363c0388e83247e7e9853e5dbc14999cc",
|
||||
"reference": "a5eb815363c0388e83247e7e9853e5dbc14999cc",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
@@ -790,10 +799,10 @@
|
||||
},
|
||||
"require-dev": {
|
||||
"psr/log": "~1.0",
|
||||
"symfony/config": "~2.0,>=2.0.5",
|
||||
"symfony/dependency-injection": "~2.6",
|
||||
"symfony/expression-language": "~2.6",
|
||||
"symfony/stopwatch": "~2.3"
|
||||
"symfony/config": "~2.0,>=2.0.5|~3.0.0",
|
||||
"symfony/dependency-injection": "~2.6|~3.0.0",
|
||||
"symfony/expression-language": "~2.6|~3.0.0",
|
||||
"symfony/stopwatch": "~2.3|~3.0.0"
|
||||
},
|
||||
"suggest": {
|
||||
"symfony/dependency-injection": "",
|
||||
@@ -802,7 +811,7 @@
|
||||
"type": "library",
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
"dev-master": "2.7-dev"
|
||||
"dev-master": "2.8-dev"
|
||||
}
|
||||
},
|
||||
"autoload": {
|
||||
@@ -829,24 +838,140 @@
|
||||
],
|
||||
"description": "Symfony EventDispatcher Component",
|
||||
"homepage": "https://symfony.com",
|
||||
"time": "2015-10-30 20:10:21"
|
||||
"time": "2015-10-30 20:15:42"
|
||||
},
|
||||
{
|
||||
"name": "symfony/var-dumper",
|
||||
"version": "v2.7.7",
|
||||
"name": "symfony/polyfill-iconv",
|
||||
"version": "v1.0.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/symfony/var-dumper.git",
|
||||
"reference": "72bcb27411780eaee9469729aace73c0d46fb2b8"
|
||||
"url": "https://github.com/symfony/polyfill-iconv.git",
|
||||
"reference": "21a18998764e569c1675efc7191887130b319605"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/symfony/var-dumper/zipball/72bcb27411780eaee9469729aace73c0d46fb2b8",
|
||||
"reference": "72bcb27411780eaee9469729aace73c0d46fb2b8",
|
||||
"url": "https://api.github.com/repos/symfony/polyfill-iconv/zipball/21a18998764e569c1675efc7191887130b319605",
|
||||
"reference": "21a18998764e569c1675efc7191887130b319605",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"php": ">=5.3.9"
|
||||
"php": ">=5.3.3"
|
||||
},
|
||||
"type": "library",
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
"dev-master": "1.0-dev"
|
||||
}
|
||||
},
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
"Symfony\\Polyfill\\Iconv\\": ""
|
||||
},
|
||||
"files": [
|
||||
"bootstrap.php"
|
||||
]
|
||||
},
|
||||
"notification-url": "https://packagist.org/downloads/",
|
||||
"license": [
|
||||
"MIT"
|
||||
],
|
||||
"authors": [
|
||||
{
|
||||
"name": "Nicolas Grekas",
|
||||
"email": "p@tchwork.com"
|
||||
},
|
||||
{
|
||||
"name": "Symfony Community",
|
||||
"homepage": "https://symfony.com/contributors"
|
||||
}
|
||||
],
|
||||
"description": "Symfony polyfill for the Iconv extension",
|
||||
"homepage": "https://symfony.com",
|
||||
"keywords": [
|
||||
"compatibility",
|
||||
"iconv",
|
||||
"polyfill",
|
||||
"portable",
|
||||
"shim"
|
||||
],
|
||||
"time": "2015-11-04 20:28:58"
|
||||
},
|
||||
{
|
||||
"name": "symfony/polyfill-mbstring",
|
||||
"version": "v1.0.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/symfony/polyfill-mbstring.git",
|
||||
"reference": "0b6a8940385311a24e060ec1fe35680e17c74497"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/0b6a8940385311a24e060ec1fe35680e17c74497",
|
||||
"reference": "0b6a8940385311a24e060ec1fe35680e17c74497",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"php": ">=5.3.3"
|
||||
},
|
||||
"type": "library",
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
"dev-master": "1.0-dev"
|
||||
}
|
||||
},
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
"Symfony\\Polyfill\\Mbstring\\": ""
|
||||
},
|
||||
"files": [
|
||||
"bootstrap.php"
|
||||
]
|
||||
},
|
||||
"notification-url": "https://packagist.org/downloads/",
|
||||
"license": [
|
||||
"MIT"
|
||||
],
|
||||
"authors": [
|
||||
{
|
||||
"name": "Nicolas Grekas",
|
||||
"email": "p@tchwork.com"
|
||||
},
|
||||
{
|
||||
"name": "Symfony Community",
|
||||
"homepage": "https://symfony.com/contributors"
|
||||
}
|
||||
],
|
||||
"description": "Symfony polyfill for the Mbstring extension",
|
||||
"homepage": "https://symfony.com",
|
||||
"keywords": [
|
||||
"compatibility",
|
||||
"mbstring",
|
||||
"polyfill",
|
||||
"portable",
|
||||
"shim"
|
||||
],
|
||||
"time": "2015-11-04 20:28:58"
|
||||
},
|
||||
{
|
||||
"name": "symfony/var-dumper",
|
||||
"version": "v2.8.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/symfony/var-dumper.git",
|
||||
"reference": "e6f3855005f2bfad7d7e72431d374a6478893fe3"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/symfony/var-dumper/zipball/e6f3855005f2bfad7d7e72431d374a6478893fe3",
|
||||
"reference": "e6f3855005f2bfad7d7e72431d374a6478893fe3",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
"php": ">=5.3.9",
|
||||
"symfony/polyfill-mbstring": "~1.0"
|
||||
},
|
||||
"require-dev": {
|
||||
"twig/twig": "~1.20|~2.0"
|
||||
},
|
||||
"suggest": {
|
||||
"ext-symfony_debug": ""
|
||||
@@ -854,7 +979,7 @@
|
||||
"type": "library",
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
"dev-master": "2.7-dev"
|
||||
"dev-master": "2.8-dev"
|
||||
}
|
||||
},
|
||||
"autoload": {
|
||||
@@ -888,20 +1013,20 @@
|
||||
"debug",
|
||||
"dump"
|
||||
],
|
||||
"time": "2015-11-18 13:41:01"
|
||||
"time": "2015-11-18 13:45:00"
|
||||
},
|
||||
{
|
||||
"name": "symfony/yaml",
|
||||
"version": "v2.7.7",
|
||||
"version": "v2.8.0",
|
||||
"source": {
|
||||
"type": "git",
|
||||
"url": "https://github.com/symfony/yaml.git",
|
||||
"reference": "4cfcd7a9fceba662b3c036b7d9a91f6197af046c"
|
||||
"reference": "f79824187de95064a2f5038904c4d7f0227fedb5"
|
||||
},
|
||||
"dist": {
|
||||
"type": "zip",
|
||||
"url": "https://api.github.com/repos/symfony/yaml/zipball/4cfcd7a9fceba662b3c036b7d9a91f6197af046c",
|
||||
"reference": "4cfcd7a9fceba662b3c036b7d9a91f6197af046c",
|
||||
"url": "https://api.github.com/repos/symfony/yaml/zipball/f79824187de95064a2f5038904c4d7f0227fedb5",
|
||||
"reference": "f79824187de95064a2f5038904c4d7f0227fedb5",
|
||||
"shasum": ""
|
||||
},
|
||||
"require": {
|
||||
@@ -910,7 +1035,7 @@
|
||||
"type": "library",
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
"dev-master": "2.7-dev"
|
||||
"dev-master": "2.8-dev"
|
||||
}
|
||||
},
|
||||
"autoload": {
|
||||
@@ -937,7 +1062,7 @@
|
||||
],
|
||||
"description": "Symfony Yaml Component",
|
||||
"homepage": "https://symfony.com",
|
||||
"time": "2015-11-18 13:41:01"
|
||||
"time": "2015-11-30 12:35:10"
|
||||
},
|
||||
{
|
||||
"name": "twig/twig",
|
||||
@@ -1002,10 +1127,17 @@
|
||||
}
|
||||
],
|
||||
"packages-dev": [],
|
||||
"aliases": [],
|
||||
"aliases": [
|
||||
{
|
||||
"alias": "1.6.0",
|
||||
"alias_normalized": "1.6.0.0",
|
||||
"version": "9999999-dev",
|
||||
"package": "erusev/parsedown"
|
||||
}
|
||||
],
|
||||
"minimum-stability": "stable",
|
||||
"stability-flags": {
|
||||
"filp/whoops": 20
|
||||
"erusev/parsedown": 20
|
||||
},
|
||||
"prefer-stable": false,
|
||||
"prefer-lowest": false,
|
||||
|
||||
@@ -516,6 +516,17 @@ form:
|
||||
validate:
|
||||
type: bool
|
||||
|
||||
twig.umask_fix:
|
||||
type: toggle
|
||||
label: PLUGIN_ADMIN.TWIG_UMASK_FIX
|
||||
help: PLUGIN_ADMIN.TWIG_UMASK_FIX_HELP
|
||||
highlight: 0
|
||||
options:
|
||||
1: PLUGIN_ADMIN.YES
|
||||
0: PLUGIN_ADMIN.NO
|
||||
validate:
|
||||
type: bool
|
||||
|
||||
assets:
|
||||
type: section
|
||||
title: PLUGIN_ADMIN.ASSETS
|
||||
@@ -688,6 +699,17 @@ form:
|
||||
validate:
|
||||
type: bool
|
||||
|
||||
images.cache_perms:
|
||||
type: select
|
||||
size: small
|
||||
label: PLUGIN_ADMIN.CACHE_PERMS
|
||||
help: PLUGIN_ADMIN.CACHE_PERMS_HELP
|
||||
highlight: '0755'
|
||||
options:
|
||||
'0755': '0755'
|
||||
'0775': '0775'
|
||||
|
||||
|
||||
images.debug:
|
||||
type: toggle
|
||||
label: PLUGIN_ADMIN.IMAGES_DEBUG
|
||||
@@ -745,13 +767,14 @@ form:
|
||||
|
||||
fields:
|
||||
session.enabled:
|
||||
type: toggle
|
||||
type: hidden
|
||||
label: PLUGIN_ADMIN.ENABLED
|
||||
help: PLUGIN_ADMIN.SESSION_ENABLED_HELP
|
||||
highlight: 1
|
||||
options:
|
||||
1: PLUGIN_ADMIN.YES
|
||||
0: PLUGIN_ADMIN.NO
|
||||
default: true
|
||||
validate:
|
||||
type: bool
|
||||
|
||||
|
||||
@@ -29,6 +29,7 @@ form:
|
||||
|
||||
content:
|
||||
type: markdown
|
||||
showPreview: true
|
||||
validate:
|
||||
type: textarea
|
||||
|
||||
|
||||
@@ -25,6 +25,7 @@ form:
|
||||
|
||||
content:
|
||||
type: markdown
|
||||
showPreview: true
|
||||
|
||||
uploads:
|
||||
type: pagemedia
|
||||
|
||||
@@ -25,6 +25,7 @@ form:
|
||||
|
||||
content:
|
||||
type: markdown
|
||||
showPreview: true
|
||||
|
||||
uploads:
|
||||
type: pagemedia
|
||||
|
||||
@@ -54,26 +54,32 @@ form:
|
||||
default: 'en'
|
||||
help: PLUGIN_ADMIN.LANGUAGE_HELP
|
||||
|
||||
groups:
|
||||
type: selectize
|
||||
size: large
|
||||
label: PLUGIN_ADMIN.GROUPS
|
||||
'@data-options': '\Grav\User\Groups::groups'
|
||||
classes: fancy
|
||||
help: PLUGIN_ADMIN.GROUPS_HELP
|
||||
validate:
|
||||
type: commalist
|
||||
security:
|
||||
title: Security
|
||||
type: section
|
||||
security: admin.super
|
||||
|
||||
access.admin:
|
||||
type: array
|
||||
label: PLUGIN_ADMIN.ADMIN_ACCESS
|
||||
multiple: false
|
||||
validate:
|
||||
type: array
|
||||
fields:
|
||||
groups:
|
||||
type: selectize
|
||||
size: large
|
||||
label: PLUGIN_ADMIN.GROUPS
|
||||
'@data-options': '\Grav\User\Groups::groups'
|
||||
classes: fancy
|
||||
help: PLUGIN_ADMIN.GROUPS_HELP
|
||||
validate:
|
||||
type: commalist
|
||||
|
||||
access.site:
|
||||
type: array
|
||||
label: PLUGIN_ADMIN.SITE_ACCESS
|
||||
multiple: false
|
||||
validate:
|
||||
type: array
|
||||
access.admin:
|
||||
type: array
|
||||
label: PLUGIN_ADMIN.ADMIN_ACCESS
|
||||
multiple: false
|
||||
validate:
|
||||
type: array
|
||||
|
||||
access.site:
|
||||
type: array
|
||||
label: PLUGIN_ADMIN.SITE_ACCESS
|
||||
multiple: false
|
||||
validate:
|
||||
type: array
|
||||
@@ -168,6 +168,10 @@ zip:
|
||||
type: file
|
||||
thumb: media/thumb-zip.png
|
||||
mime: application/zip
|
||||
7z:
|
||||
type: file
|
||||
thumb: media/thumb-7zip.png
|
||||
mime: application/x-7z-compressed
|
||||
gz:
|
||||
type: file
|
||||
thumb: media/thumb-gz.png
|
||||
|
||||
@@ -97,6 +97,7 @@ debugger:
|
||||
images:
|
||||
default_image_quality: 85 # Default image quality to use when resampling images (85%)
|
||||
cache_all: false # Cache all image by default
|
||||
cache_perms: '0755' # MUST BE IN QUOTES!! Default cache folder perms. Usually '0755' or '0775'
|
||||
debug: false # Show an overlay over images indicating the pixel depth of the image when working with retina for example
|
||||
|
||||
media:
|
||||
|
||||
@@ -2,8 +2,9 @@
|
||||
|
||||
// Some standard defines
|
||||
define('GRAV', true);
|
||||
define('GRAV_VERSION', '1.0.0-rc.6');
|
||||
define('GRAV_VERSION', '1.0.5');
|
||||
define('DS', '/');
|
||||
define('GRAV_PHP_MIN', '5.5.9');
|
||||
|
||||
// Directories and Paths
|
||||
if (!defined('GRAV_ROOT')) {
|
||||
|
||||
@@ -50,3 +50,4 @@ NICETIME:
|
||||
FORM:
|
||||
VALIDATION_FAIL: <b>A validáció hibát talált:</b>
|
||||
INVALID_INPUT: Az itt megadott érték érvénytelen:
|
||||
MISSING_REQUIRED_FIELD: Ez a kötelező mező nincs kitöltve:
|
||||
|
||||
@@ -186,7 +186,7 @@ class Assets
|
||||
$this->base_url = $base_url . '/';
|
||||
|
||||
// Register any preconfigured collections
|
||||
foreach ($config->get('system.assets.collections') as $name => $collection) {
|
||||
foreach ($config->get('system.assets.collections', []) as $name => $collection) {
|
||||
$this->registerCollection($name, (array)$collection);
|
||||
}
|
||||
}
|
||||
@@ -203,7 +203,7 @@ class Assets
|
||||
*
|
||||
* @return $this
|
||||
*/
|
||||
public function add($asset, $priority = null, $pipeline = null)
|
||||
public function add($asset, $priority = null, $pipeline = true)
|
||||
{
|
||||
// More than one asset
|
||||
if (is_array($asset)) {
|
||||
@@ -243,7 +243,7 @@ class Assets
|
||||
*
|
||||
* @return $this
|
||||
*/
|
||||
public function addCss($asset, $priority = null, $pipeline = null, $group = null)
|
||||
public function addCss($asset, $priority = null, $pipeline = true, $group = null)
|
||||
{
|
||||
if (is_array($asset)) {
|
||||
foreach ($asset as $a) {
|
||||
@@ -259,16 +259,20 @@ class Assets
|
||||
$asset = $this->buildLocalLink($asset);
|
||||
}
|
||||
|
||||
// Check for existence
|
||||
if ($asset === false) {
|
||||
return $this;
|
||||
}
|
||||
|
||||
$data = [
|
||||
'asset' => $asset,
|
||||
'priority' => intval($priority ?: 10),
|
||||
'order' => count($this->css),
|
||||
'pipeline' => $pipeline ?: true,
|
||||
'pipeline' => (bool) $pipeline,
|
||||
'group' => $group ?: 'head'
|
||||
];
|
||||
|
||||
// check for dynamic array and merge with defaults
|
||||
$count_args = func_num_args();
|
||||
if (func_num_args() == 2) {
|
||||
$dynamic_arg = func_get_arg(1);
|
||||
if (is_array($dynamic_arg)) {
|
||||
@@ -297,7 +301,7 @@ class Assets
|
||||
* @param string $group name of the group
|
||||
* @return $this
|
||||
*/
|
||||
public function addJs($asset, $priority = null, $pipeline = null, $loading = null, $group = null)
|
||||
public function addJs($asset, $priority = null, $pipeline = true, $loading = null, $group = null)
|
||||
{
|
||||
if (is_array($asset)) {
|
||||
foreach ($asset as $a) {
|
||||
@@ -313,17 +317,21 @@ class Assets
|
||||
$asset = $this->buildLocalLink($asset);
|
||||
}
|
||||
|
||||
// Check for existence
|
||||
if ($asset === false) {
|
||||
return $this;
|
||||
}
|
||||
|
||||
$data = [
|
||||
'asset' => $asset,
|
||||
'priority' => intval($priority ?: 10),
|
||||
'order' => count($this->js),
|
||||
'pipeline' => $pipeline ?: true,
|
||||
'pipeline' => (bool) $pipeline,
|
||||
'loading' => $loading ?: '',
|
||||
'group' => $group ?: 'head'
|
||||
];
|
||||
|
||||
// check for dynamic array and merge with defaults
|
||||
$count_args = func_num_args();
|
||||
if (func_num_args() == 2) {
|
||||
$dynamic_arg = func_get_arg(1);
|
||||
if (is_array($dynamic_arg)) {
|
||||
@@ -351,7 +359,7 @@ class Assets
|
||||
*
|
||||
* @return \Grav\Common\Assets
|
||||
*/
|
||||
public function addAsyncJs($asset, $priority = null, $pipeline = null, $group = null)
|
||||
public function addAsyncJs($asset, $priority = null, $pipeline = true, $group = null)
|
||||
{
|
||||
return $this->addJs($asset, $priority, $pipeline, 'async', $group);
|
||||
}
|
||||
@@ -368,7 +376,7 @@ class Assets
|
||||
*
|
||||
* @return \Grav\Common\Assets
|
||||
*/
|
||||
public function addDeferJs($asset, $priority = null, $pipeline = null, $group = null)
|
||||
public function addDeferJs($asset, $priority = null, $pipeline = true, $group = null)
|
||||
{
|
||||
return $this->addJs($asset, $priority, $pipeline, 'defer', $group);
|
||||
}
|
||||
@@ -1124,6 +1132,36 @@ class Assets
|
||||
return $this->addDir($directory, self::JS_REGEX);
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the state of CSS Pipeline
|
||||
*
|
||||
* @param boolean $value
|
||||
*/
|
||||
public function setCssPipeline($value)
|
||||
{
|
||||
$this->css_pipeline = (bool) $value;
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets the state of JS Pipeline
|
||||
*
|
||||
* @param boolean $value
|
||||
*/
|
||||
public function setJsPipeline($value)
|
||||
{
|
||||
$this->js_pipeline = (bool) $value;
|
||||
}
|
||||
|
||||
/**
|
||||
* Explicitly set's a timestamp for assets
|
||||
*
|
||||
* @param $value
|
||||
*/
|
||||
public function setTimestamp($value)
|
||||
{
|
||||
$this->timestamp = '?'.$value;
|
||||
}
|
||||
|
||||
public function __toString()
|
||||
{
|
||||
return '';
|
||||
|
||||
@@ -38,6 +38,8 @@ class Cache extends Getters
|
||||
*/
|
||||
protected $driver;
|
||||
|
||||
protected $driver_name;
|
||||
|
||||
/**
|
||||
* @var bool
|
||||
*/
|
||||
@@ -110,6 +112,10 @@ class Cache extends Getters
|
||||
|
||||
// Set the cache namespace to our unique key
|
||||
$this->driver->setNamespace($this->key);
|
||||
|
||||
// Dump Cache state
|
||||
$grav['debugger']->addMessage('Cache: [' . ($this->enabled ? 'true' : 'false') . '] Driver: [' . $this->driver_name . ']');
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -136,6 +142,8 @@ class Cache extends Getters
|
||||
$driver_name = $setting;
|
||||
}
|
||||
|
||||
$this->driver_name = $driver_name;
|
||||
|
||||
switch ($driver_name) {
|
||||
case 'apc':
|
||||
$driver = new \Doctrine\Common\Cache\ApcCache();
|
||||
|
||||
@@ -113,8 +113,13 @@ class Setup extends Data
|
||||
],
|
||||
];
|
||||
|
||||
public function __construct($environment = 'localhost')
|
||||
public function __construct($container)
|
||||
{
|
||||
$environment = $container['uri']->environment();
|
||||
if (!$environment) {
|
||||
$environment = 'localhost';
|
||||
}
|
||||
|
||||
// Pre-load setup.php which contains our initial configuration.
|
||||
// Configuration may contain dynamic parts, which is why we need to always load it.
|
||||
$file = GRAV_ROOT . '/setup.php';
|
||||
|
||||
@@ -338,8 +338,10 @@ class Blueprint implements \ArrayAccess, ExportInterface
|
||||
|
||||
if ($field['type'] === 'list') {
|
||||
// we loop through list to get the actual field
|
||||
foreach($field['fields'] as $subName => &$subField) {
|
||||
$this->parseFormField($subField);
|
||||
if (isset($field['fields']) && $field['fields']) {
|
||||
foreach($field['fields'] as $subName => &$subField) {
|
||||
$this->parseFormField($subField);
|
||||
}
|
||||
}
|
||||
} else {
|
||||
$this->parseFormField($field);
|
||||
|
||||
@@ -32,7 +32,7 @@ class Validation
|
||||
}
|
||||
|
||||
// special case for files, value is never empty and errors with code 4 instead
|
||||
if (empty($validate['required']) && $field['type'] == 'file' && (isset($value['error']) && ($value['error'] == UPLOAD_ERR_NO_FILE) || in_array(UPLOAD_ERR_NO_FILE, $value['error']))) {
|
||||
if (empty($validate['required']) && $field['type'] == 'file' && (isset($value['error']) && ($value['error'] == UPLOAD_ERR_NO_FILE || in_array(UPLOAD_ERR_NO_FILE, $value['error'])))) {
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -43,7 +43,7 @@ class Validation
|
||||
$type = (string) isset($field['validate']['type']) ? $field['validate']['type'] : $field['type'];
|
||||
$method = 'type'.strtr($type, '-', '_');
|
||||
$name = ucfirst(isset($field['label']) ? $field['label'] : $field['name']);
|
||||
$message = (string) isset($field['validate']['message']) ? $field['validate']['message'] : $language->translate('FORM.INVALID_INPUT', null, true) . ' "' . $language->translate($name) . '"';
|
||||
$message = (string) isset($field['validate']['message']) ? $language->translate($field['validate']['message']) : $language->translate('FORM.INVALID_INPUT', null, true) . ' "' . $language->translate($name) . '"';
|
||||
|
||||
if (method_exists(__CLASS__, $method)) {
|
||||
$success = self::$method($value, $validate, $field);
|
||||
@@ -84,7 +84,7 @@ class Validation
|
||||
}
|
||||
|
||||
// special case for files, value is never empty and errors with code 4 instead
|
||||
if (empty($validate['required']) && $field['type'] == 'file' && (isset($value['error']) && ($value['error'] == UPLOAD_ERR_NO_FILE) || in_array(UPLOAD_ERR_NO_FILE, $value['error']))) {
|
||||
if (empty($validate['required']) && $field['type'] == 'file' && (isset($value['error']) && ($value['error'] == UPLOAD_ERR_NO_FILE || in_array(UPLOAD_ERR_NO_FILE, $value['error'])))) {
|
||||
return null;
|
||||
}
|
||||
|
||||
@@ -283,7 +283,15 @@ class Validation
|
||||
|
||||
protected static function filterFile($value, array $params, array $field)
|
||||
{
|
||||
return (array) $value;
|
||||
if ($field['multiple'] == true) {
|
||||
return (array) $value;
|
||||
}
|
||||
|
||||
if (is_array($value)) {
|
||||
return reset($value);
|
||||
}
|
||||
|
||||
return $value;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -620,7 +628,7 @@ class Validation
|
||||
if (is_string($value)) {
|
||||
$value = trim($value);
|
||||
}
|
||||
|
||||
|
||||
return (bool) $params !== true || !empty($value);
|
||||
}
|
||||
|
||||
|
||||
@@ -15,6 +15,8 @@ class Debugger
|
||||
protected $renderer;
|
||||
protected $enabled;
|
||||
|
||||
protected $timers = [];
|
||||
|
||||
public function __construct()
|
||||
{
|
||||
$this->debugbar = new StandardDebugBar();
|
||||
@@ -98,15 +100,17 @@ class Debugger
|
||||
{
|
||||
if ($name[0] == '_' || $this->grav['config']->get('system.debugger.enabled')) {
|
||||
$this->debugbar['time']->startMeasure($name, $description);
|
||||
$this->timers[] = $name;
|
||||
}
|
||||
return $this;
|
||||
}
|
||||
|
||||
public function stopTimer($name)
|
||||
{
|
||||
if ($name[0] == '_' || $this->grav['config']->get('system.debugger.enabled')) {
|
||||
if (in_array($name, $this->timers) && ($name[0] == '_' || $this->grav['config']->get('system.debugger.enabled'))) {
|
||||
$this->debugbar['time']->stopMeasure($name);
|
||||
}
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
|
||||
@@ -274,6 +274,11 @@ abstract class Folder
|
||||
throw new \RuntimeException('Cannot move non-existing folder.');
|
||||
}
|
||||
|
||||
// Don't do anything if the source is the same as the new target
|
||||
if ($source == $target) {
|
||||
return;
|
||||
}
|
||||
|
||||
// Make sure that path to the target exists before moving.
|
||||
self::create(dirname($target));
|
||||
|
||||
|
||||
@@ -281,6 +281,10 @@ class Installer
|
||||
{
|
||||
$msg = 'Unknown Error';
|
||||
|
||||
if (is_string(self::$error)) {
|
||||
return self::$error;
|
||||
}
|
||||
|
||||
switch (self::$error) {
|
||||
case 0:
|
||||
$msg = 'No Error';
|
||||
@@ -333,7 +337,7 @@ class Installer
|
||||
|
||||
/**
|
||||
* Allows to manually set an error
|
||||
* @param $error the Error code
|
||||
* @param int|string $error the Error code
|
||||
*/
|
||||
|
||||
public static function setError($error)
|
||||
|
||||
@@ -55,7 +55,7 @@ class Grav extends AbstractPackageCollection
|
||||
|
||||
$diffLog = [];
|
||||
foreach ($this->data['changelog'] as $version => $changelog) {
|
||||
preg_match("/[\d\.]+/", $version, $cleanVersion);
|
||||
preg_match("/[\w-\.]+/", $version, $cleanVersion);
|
||||
|
||||
if (!$cleanVersion || version_compare($diff, $cleanVersion[0], ">=")) { continue; }
|
||||
|
||||
|
||||
@@ -1,22 +1,32 @@
|
||||
<?php
|
||||
namespace Grav\Common\GPM;
|
||||
|
||||
use Grav\Common\Grav;
|
||||
|
||||
/**
|
||||
* Class Upgrader
|
||||
*
|
||||
* @package Grav\Common\GPM
|
||||
*/
|
||||
class Upgrader
|
||||
{
|
||||
/**
|
||||
* Remote details about latest Grav version
|
||||
*
|
||||
* @var Packages
|
||||
*/
|
||||
private $remote;
|
||||
|
||||
/**
|
||||
* Internal cache
|
||||
*
|
||||
* @var Iterator
|
||||
*/
|
||||
protected $cache;
|
||||
|
||||
/**
|
||||
* Creates a new GPM instance with Local and Remote packages available
|
||||
*
|
||||
* @param boolean $refresh Applies to Remote Packages only and forces a refetch of data
|
||||
* @param callable $callback Either a function or callback in array notation
|
||||
*/
|
||||
@@ -27,6 +37,7 @@ class Upgrader
|
||||
|
||||
/**
|
||||
* Returns the release date of the latest version of Grav
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function getReleaseDate()
|
||||
@@ -36,6 +47,7 @@ class Upgrader
|
||||
|
||||
/**
|
||||
* Returns the version of the installed Grav
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function getLocalVersion()
|
||||
@@ -45,6 +57,7 @@ class Upgrader
|
||||
|
||||
/**
|
||||
* Returns the version of the remotely available Grav
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function getRemoteVersion()
|
||||
@@ -54,6 +67,7 @@ class Upgrader
|
||||
|
||||
/**
|
||||
* Returns an array of assets available to download remotely
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
public function getAssets()
|
||||
@@ -63,6 +77,7 @@ class Upgrader
|
||||
|
||||
/**
|
||||
* Returns the changelog list for each version of Grav
|
||||
*
|
||||
* @param string $diff the version number to start the diff from
|
||||
*
|
||||
* @return array return the changelog list for each version
|
||||
@@ -72,8 +87,21 @@ class Upgrader
|
||||
return $this->remote->getChangelog($diff);
|
||||
}
|
||||
|
||||
/**
|
||||
* @return bool
|
||||
*/
|
||||
public function meetsRequirements()
|
||||
{
|
||||
if (version_compare(PHP_VERSION, GRAV_PHP_MIN, '<')) {
|
||||
return false;
|
||||
}
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
/**
|
||||
* Checks if the currently installed Grav is upgradable to a newer version
|
||||
*
|
||||
* @return boolean True if it's upgradable, False otherwise.
|
||||
*/
|
||||
public function isUpgradable()
|
||||
@@ -83,6 +111,7 @@ class Upgrader
|
||||
|
||||
/**
|
||||
* Checks if Grav is currently symbolically linked
|
||||
*
|
||||
* @return boolean True if Grav is symlinked, False otherwise.
|
||||
*/
|
||||
|
||||
|
||||
@@ -230,7 +230,6 @@ class Grav extends Container
|
||||
|
||||
$debugger->startTimer('themes', 'Themes');
|
||||
$this['themes']->init();
|
||||
$this->fireEvent('onThemeInitialized');
|
||||
$debugger->stopTimer('themes');
|
||||
|
||||
$task = $this['task'];
|
||||
|
||||
@@ -215,4 +215,26 @@ class Iterator implements \ArrayAccess, \Iterator, \Countable, \Serializable
|
||||
|
||||
return $this;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Sorts elements from the list and returns a copy of the list in the proper order
|
||||
*
|
||||
* @param callable|null $callback
|
||||
*
|
||||
* @param bool $desc
|
||||
*
|
||||
* @return $this|array
|
||||
* @internal param bool $asc
|
||||
*
|
||||
*/
|
||||
public function sort(callable $callback = null, $desc = false)
|
||||
{
|
||||
if (!$callback || !is_callable($callback)) { return $this; }
|
||||
|
||||
$items = $this->items;
|
||||
uasort($items, $callback);
|
||||
|
||||
return !$desc ? $items : array_reverse($items, true);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -352,7 +352,7 @@ class Language
|
||||
if ($this->config->get('system.languages.translations_fallback', true)) {
|
||||
$languages = $this->getFallbackLanguages();
|
||||
} else {
|
||||
$languages = (array)$this->getDefault();
|
||||
$languages = (array)$this->getLanguage();
|
||||
}
|
||||
}
|
||||
} else {
|
||||
|
||||
@@ -3,6 +3,7 @@ namespace Grav\Common\Markdown;
|
||||
|
||||
use Grav\Common\GravTrait;
|
||||
use Grav\Common\Uri;
|
||||
use RocketTheme\Toolbox\Event\Event;
|
||||
|
||||
/**
|
||||
* A trait to add some custom processing to the identifyLink() method in Parsedown and ParsedownExtra
|
||||
@@ -15,9 +16,11 @@ trait ParsedownGravTrait
|
||||
protected $base_url;
|
||||
protected $pages_dir;
|
||||
protected $special_chars;
|
||||
|
||||
protected $twig_link_regex = '/\!*\[(?:.*)\]\((\{([\{%#])\s*(.*?)\s*(?:\2|\})\})\)/';
|
||||
|
||||
public $completeable_blocks = [];
|
||||
public $continueable_blocks = [];
|
||||
|
||||
/**
|
||||
* Initialization function to setup key variables needed by the MarkdownGravLinkTrait
|
||||
*
|
||||
@@ -26,8 +29,10 @@ trait ParsedownGravTrait
|
||||
*/
|
||||
protected function init($page, $defaults)
|
||||
{
|
||||
$grav = self::getGrav();
|
||||
|
||||
$this->page = $page;
|
||||
$this->pages = self::getGrav()['pages'];
|
||||
$this->pages = $grav['pages'];
|
||||
$this->BlockTypes['{'] [] = "TwigTag";
|
||||
$this->base_url = rtrim(self::getGrav()['base_url'] . self::getGrav()['pages']->base(), '/');
|
||||
$this->pages_dir = self::getGrav()['locator']->findResource('page://');
|
||||
@@ -41,8 +46,67 @@ trait ParsedownGravTrait
|
||||
$this->setUrlsLinked($defaults['auto_url_links']);
|
||||
$this->setMarkupEscaped($defaults['escape_markup']);
|
||||
$this->setSpecialChars($defaults['special_chars']);
|
||||
|
||||
$grav->fireEvent('onMarkdownInitialized', new Event(['markdown' => $this]));
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* Be able to define a new Block type or override an existing one
|
||||
*
|
||||
* @param $type
|
||||
* @param $tag
|
||||
*/
|
||||
public function addBlockType($type, $tag, $continueable = false, $completeable = false)
|
||||
{
|
||||
$this->BlockTypes[$type] []= $tag;
|
||||
|
||||
if ($continueable) {
|
||||
$this->continueable_blocks[] = $tag;
|
||||
}
|
||||
|
||||
if ($completeable) {
|
||||
$this->completeable_blocks[] = $tag;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Be able to define a new Inline type or override an existing one
|
||||
*
|
||||
* @param $type
|
||||
* @param $tag
|
||||
*/
|
||||
public function addInlineType($type, $tag)
|
||||
{
|
||||
$this->InlineTypes[$type] []= $tag;
|
||||
$this->inlineMarkerList .= $type;
|
||||
}
|
||||
|
||||
/**
|
||||
* Overrides the default behavior to allow for plugin-provided blocks to be continueable
|
||||
*
|
||||
* @param $Type
|
||||
* @return bool
|
||||
*/
|
||||
protected function isBlockContinueable($Type)
|
||||
{
|
||||
$continueable = in_array($Type, $this->continueable_blocks) || method_exists($this, 'block'.$Type.'Continue');
|
||||
return $continueable;
|
||||
}
|
||||
|
||||
/**
|
||||
* Overrides the default behavior to allow for plugin-provided blocks to be completeable
|
||||
*
|
||||
* @param $Type
|
||||
* @return bool
|
||||
*/
|
||||
protected function isBlockCompleteable($Type)
|
||||
{
|
||||
$completeable = in_array($Type, $this->completeable_blocks) || method_exists($this, 'block'.$Type.'Complete');
|
||||
return $completeable;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Make the element function publicly accessible, Medium uses this to render from Twig
|
||||
*
|
||||
@@ -73,7 +137,7 @@ trait ParsedownGravTrait
|
||||
*/
|
||||
protected function blockTwigTag($Line)
|
||||
{
|
||||
if (preg_match('/[{%|{{|{#].*[#}|}}|%}]/', $Line['body'], $matches)) {
|
||||
if (preg_match('/(?:{{|{%|{#)(.*)(?:}}|%}|#})/', $Line['body'], $matches)) {
|
||||
$Block = array(
|
||||
'markup' => $Line['body'],
|
||||
);
|
||||
@@ -204,6 +268,48 @@ trait ParsedownGravTrait
|
||||
if (isset($excerpt['element']['attributes']['href'])) {
|
||||
$url = parse_url(htmlspecialchars_decode($excerpt['element']['attributes']['href']));
|
||||
|
||||
// if there is a query, then parse it and build action calls
|
||||
if (isset($url['query'])) {
|
||||
$actions = array_reduce(explode('&', $url['query']), function ($carry, $item) {
|
||||
$parts = explode('=', $item, 2);
|
||||
$value = isset($parts[1]) ? $parts[1] : null;
|
||||
$carry[$parts[0]] = $value;
|
||||
|
||||
return $carry;
|
||||
}, []);
|
||||
|
||||
// valid attributes supported
|
||||
$valid_attributes = ['rel', 'target', 'id', 'class', 'classes'];
|
||||
|
||||
// Unless told to not process, go through actions
|
||||
if (array_key_exists('noprocess', $actions)) {
|
||||
unset($actions['noprocess']);
|
||||
} else {
|
||||
// loop through actions for the image and call them
|
||||
foreach ($actions as $attrib => $value) {
|
||||
$key = $attrib;
|
||||
|
||||
if (in_array($attrib, $valid_attributes)) {
|
||||
// support both class and classes
|
||||
if ($attrib == 'classes') {
|
||||
$attrib = 'class';
|
||||
}
|
||||
$excerpt['element']['attributes'][$attrib] = str_replace(',', ' ', $value);
|
||||
unset($actions[$key]);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
$url['query']= http_build_query($actions, null, '&', PHP_QUERY_RFC3986);
|
||||
}
|
||||
|
||||
// if no query elements left, unset query
|
||||
if (empty($url['query'])) {
|
||||
unset ($url['query']);
|
||||
}
|
||||
|
||||
|
||||
// if there is no scheme, the file is local
|
||||
if (!isset($url['scheme']) && (count($url) > 0)) {
|
||||
// convert the URl is required
|
||||
@@ -213,4 +319,16 @@ trait ParsedownGravTrait
|
||||
|
||||
return $excerpt;
|
||||
}
|
||||
|
||||
// For extending this class via plugins
|
||||
public function __call($method, $args)
|
||||
{
|
||||
if (isset($this->$method) === true) {
|
||||
$func = $this->$method;
|
||||
return call_user_func_array($func, $args);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -55,6 +55,7 @@ class ImageFile extends Image
|
||||
$cacheFile .= $this->prettyName;
|
||||
}
|
||||
|
||||
|
||||
$cacheFile .= '.'.$type;
|
||||
|
||||
// If the files does not exists, save it
|
||||
@@ -79,7 +80,9 @@ class ImageFile extends Image
|
||||
|
||||
// Asking the cache for the cacheFile
|
||||
try {
|
||||
$file = $this->cache->getOrCreateFile($cacheFile, $conditions, $generate, $actual);
|
||||
$perms = self::getGrav()['config']->get('system.images.cache_perms', '0755');
|
||||
$perms = octdec($perms);
|
||||
$file = $this->cache->setDirectoryMode($perms)->getOrCreateFile($cacheFile, $conditions, $generate, $actual);
|
||||
} catch (GenerationError $e) {
|
||||
$file = $e->getNewFile();
|
||||
}
|
||||
|
||||
@@ -135,7 +135,7 @@ class ImageMedium extends Medium
|
||||
*/
|
||||
public function url($reset = true)
|
||||
{
|
||||
$output = preg_replace('|^' . GRAV_ROOT . '|', '', $this->saveImage());
|
||||
$output = preg_replace('|^' . preg_quote(GRAV_ROOT) . '|', '', $this->saveImage());
|
||||
|
||||
if ($reset) {
|
||||
$this->reset();
|
||||
|
||||
@@ -137,7 +137,7 @@ class Medium extends Data implements RenderableInterface
|
||||
*/
|
||||
public function url($reset = true)
|
||||
{
|
||||
$output = preg_replace('|^' . GRAV_ROOT . '|', '', $this->get('filepath'));
|
||||
$output = preg_replace('|^' . preg_quote(GRAV_ROOT) . '|', '', $this->get('filepath'));
|
||||
|
||||
if ($reset) {
|
||||
$this->reset();
|
||||
|
||||
@@ -5,6 +5,7 @@ use Exception;
|
||||
use Grav\Common\Filesystem\Folder;
|
||||
use Grav\Common\Config\Config;
|
||||
use Grav\Common\GravTrait;
|
||||
use Grav\Common\Language\Language;
|
||||
use Grav\Common\Utils;
|
||||
use Grav\Common\Cache;
|
||||
use Grav\Common\Twig;
|
||||
@@ -381,7 +382,7 @@ class Page
|
||||
*/
|
||||
public function modifyHeader($key, $value)
|
||||
{
|
||||
$this->header->$key = $value;
|
||||
$this->header->{$key} = $value;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -392,8 +393,7 @@ class Page
|
||||
*/
|
||||
public function summary($size = null)
|
||||
{
|
||||
/** @var Config $config */
|
||||
$config = self::getGrav()['config']->get('site.summary');
|
||||
$config = (array) self::getGrav()['config']->get('site.summary');
|
||||
if (isset($this->header->summary)) {
|
||||
$config = array_merge($config, $this->header->summary);
|
||||
}
|
||||
@@ -728,27 +728,30 @@ class Page
|
||||
* You need to call $this->save() in order to perform the move.
|
||||
*
|
||||
* @param Page $parent New parent page.
|
||||
* @return Page
|
||||
* @return $this
|
||||
*/
|
||||
public function move(Page $parent)
|
||||
{
|
||||
$clone = clone $this;
|
||||
$clone->_action = 'move';
|
||||
$clone->_original = $this;
|
||||
$clone->parent($parent);
|
||||
$clone->id(time().md5($clone->filePath()));
|
||||
if (!$this->_original) {
|
||||
$clone = clone $this;
|
||||
$this->_original = $clone;
|
||||
}
|
||||
|
||||
$this->_action = 'move';
|
||||
$this->parent($parent);
|
||||
$this->id(time().md5($this->filePath()));
|
||||
|
||||
if ($parent->path()) {
|
||||
$clone->path($parent->path() . '/' . $clone->folder());
|
||||
$this->path($parent->path() . '/' . $this->folder());
|
||||
}
|
||||
|
||||
if ($parent->route()) {
|
||||
$clone->route($parent->route() . '/'. $clone->slug());
|
||||
$this->route($parent->route() . '/'. $this->slug());
|
||||
} else {
|
||||
$clone->route(self::getGrav()['pages']->root()->route() . '/'. $clone->slug());
|
||||
$this->route(self::getGrav()['pages']->root()->route() . '/'. $this->slug());
|
||||
}
|
||||
|
||||
return $clone;
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -758,14 +761,14 @@ class Page
|
||||
* You need to call $this->save() in order to perform the move.
|
||||
*
|
||||
* @param Page $parent New parent page.
|
||||
* @return Page
|
||||
* @return $this
|
||||
*/
|
||||
public function copy($parent)
|
||||
{
|
||||
$clone = $this->move($parent);
|
||||
$clone->_action = 'copy';
|
||||
$this->move($parent);
|
||||
$this->_action = 'copy';
|
||||
|
||||
return $clone;
|
||||
return $this;
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -826,7 +829,7 @@ class Page
|
||||
$blueprints = $this->blueprints();
|
||||
$values = $blueprints->filter($this->toArray());
|
||||
if ($values && isset($values['header'])) {
|
||||
$this->header($values['header']);
|
||||
$this->header($values['header']);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1805,11 +1808,13 @@ class Page
|
||||
|
||||
if (isset($routes[$uri_path])) {
|
||||
$child_page = $pages->dispatch($uri->route())->parent();
|
||||
if ($child_page) while (!$child_page->root()) {
|
||||
if ($this->path() == $child_page->path()) {
|
||||
return true;
|
||||
if ($child_page) {
|
||||
while (!$child_page->root()) {
|
||||
if ($this->path() == $child_page->path()) {
|
||||
return true;
|
||||
}
|
||||
$child_page = $child_page->parent();
|
||||
}
|
||||
$child_page = $child_page->parent();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1843,7 +1848,7 @@ class Page
|
||||
/**
|
||||
* Helper method to return a page.
|
||||
*
|
||||
* @param string $url the url of the page
|
||||
* @param string $url the url of the page
|
||||
* @param bool $all
|
||||
*
|
||||
* @return \Grav\Common\Page\Page page you were looking for if it exists
|
||||
@@ -1951,7 +1956,7 @@ class Page
|
||||
* @return mixed
|
||||
* @internal
|
||||
*/
|
||||
protected function evaluate($value)
|
||||
public function evaluate($value)
|
||||
{
|
||||
// Parse command.
|
||||
if (is_string($value)) {
|
||||
@@ -2141,7 +2146,7 @@ class Page
|
||||
*/
|
||||
protected function doRelocation($reorder)
|
||||
{
|
||||
if (empty($this->_original) ) {
|
||||
if (!$this->_original) {
|
||||
return;
|
||||
}
|
||||
|
||||
@@ -2182,7 +2187,7 @@ class Page
|
||||
// Handle all the other pages.
|
||||
$page = $pages->get($path);
|
||||
|
||||
if ($page && $page->exists() && $page->order() != $order+1) {
|
||||
if ($page && $page->exists() && !$page->_action && $page->order() != $order+1) {
|
||||
$page = $page->move($parent);
|
||||
$page->order($order+1);
|
||||
$page->save(false);
|
||||
@@ -2190,11 +2195,12 @@ class Page
|
||||
}
|
||||
}
|
||||
}
|
||||
if ($this->_action == 'move' && $this->_original->exists()) {
|
||||
Folder::move($this->_original->path(), $this->path());
|
||||
}
|
||||
if ($this->_action == 'copy' && $this->_original->exists()) {
|
||||
Folder::copy($this->_original->path(), $this->path());
|
||||
if (is_dir($this->_original->path())) {
|
||||
if ($this->_action == 'move') {
|
||||
Folder::move($this->_original->path(), $this->path());
|
||||
} elseif ($this->_action == 'copy') {
|
||||
Folder::copy($this->_original->path(), $this->path());
|
||||
}
|
||||
}
|
||||
|
||||
if ($this->name() != $this->_original->name()) {
|
||||
@@ -2204,7 +2210,6 @@ class Page
|
||||
}
|
||||
}
|
||||
|
||||
$this->_action = null;
|
||||
$this->_original = null;
|
||||
}
|
||||
|
||||
|
||||
@@ -237,7 +237,7 @@ class Pages
|
||||
/**
|
||||
* Get a page instance.
|
||||
*
|
||||
* @param string $path
|
||||
* @param string $path The filesystem full path of the page
|
||||
* @return Page
|
||||
* @throws \Exception
|
||||
*/
|
||||
@@ -264,7 +264,7 @@ class Pages
|
||||
/**
|
||||
* Dispatch URI to a page.
|
||||
*
|
||||
* @param $url
|
||||
* @param string $url The relative URL of the page
|
||||
* @param bool $all
|
||||
* @return Page|null
|
||||
*/
|
||||
|
||||
@@ -6,6 +6,7 @@ use Grav\Common\Page\Page;
|
||||
use Grav\Common\Config\Config;
|
||||
use RocketTheme\Toolbox\Event\EventDispatcher;
|
||||
use RocketTheme\Toolbox\Event\EventSubscriberInterface;
|
||||
use RocketTheme\Toolbox\File\YamlFile;
|
||||
|
||||
/**
|
||||
* The Plugin object just holds the id and path to a plugin.
|
||||
@@ -182,4 +183,26 @@ class Plugin implements EventSubscriberInterface
|
||||
// Return configurations as a new data config class
|
||||
return new Data($header);
|
||||
}
|
||||
|
||||
/**
|
||||
* Persists to disk the plugin parameters currently stored in the Grav Config object
|
||||
*
|
||||
* @param string $plugin_name The name of the plugin whose config it should store.
|
||||
*
|
||||
* @return true
|
||||
*/
|
||||
public static function saveConfig($plugin_name) {
|
||||
if (!$plugin_name) {
|
||||
return false;
|
||||
}
|
||||
|
||||
$locator = Grav::instance()['locator'];
|
||||
$filename = 'config://plugins/' . $plugin_name . '.yaml';
|
||||
$file = YamlFile::instance($locator->findResource($filename, true, true));
|
||||
$content = Grav::instance()['config']->get('plugins.' . $plugin_name);
|
||||
$file->save($content);
|
||||
$file->free();
|
||||
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -104,8 +104,12 @@ class Plugins extends Iterator
|
||||
continue;
|
||||
}
|
||||
|
||||
$type = $directory->getBasename();
|
||||
$list[$type] = self::get($type);
|
||||
$plugin = $directory->getBasename();
|
||||
$result = self::get($plugin);
|
||||
|
||||
if ($result) {
|
||||
$list[$plugin] = $result;
|
||||
}
|
||||
}
|
||||
}
|
||||
ksort($list);
|
||||
@@ -120,9 +124,9 @@ class Plugins extends Iterator
|
||||
$blueprint->name = $name;
|
||||
|
||||
// Load default configuration.
|
||||
$file = CompiledYamlFile::instance("plugins://{$name}/{$name}.yaml");
|
||||
$file = CompiledYamlFile::instance("plugins://{$name}/{$name}" . YAML_EXT);
|
||||
|
||||
// ensure the plugin exists physically
|
||||
// ensure this is a valid plugin
|
||||
if (!$file->exists()) {
|
||||
return null;
|
||||
}
|
||||
|
||||
@@ -40,7 +40,7 @@ class ConfigServiceProvider implements ServiceProviderInterface
|
||||
|
||||
public static function setup(Container $container)
|
||||
{
|
||||
return new Setup($container['uri']->environment());
|
||||
return new Setup($container);
|
||||
}
|
||||
|
||||
public static function blueprints(Container $container)
|
||||
@@ -108,10 +108,45 @@ class ConfigServiceProvider implements ServiceProviderInterface
|
||||
$files += (new ConfigFileFinder)->locateFiles($paths);
|
||||
$paths = $locator->findResources('plugins://');
|
||||
$files += (new ConfigFileFinder)->setBase('plugins')->locateInFolders($paths, 'languages');
|
||||
$paths = static::pluginFolderPaths($paths, 'languages');
|
||||
$files += (new ConfigFileFinder)->locateFiles($paths);
|
||||
}
|
||||
|
||||
$languages = new CompiledLanguages($cache, $files, GRAV_ROOT);
|
||||
|
||||
return $languages->name("master-{$setup->environment}")->load();
|
||||
}
|
||||
|
||||
/**
|
||||
* Find specific paths in plugins
|
||||
*
|
||||
* @param $plugins
|
||||
* @param $folder_path
|
||||
* @return array
|
||||
*/
|
||||
private static function pluginFolderPaths($plugins, $folder_path)
|
||||
{
|
||||
$paths = [];
|
||||
|
||||
foreach ($plugins as $path) {
|
||||
$iterator = new \DirectoryIterator($path);
|
||||
|
||||
/** @var \DirectoryIterator $directory */
|
||||
foreach ($iterator as $directory) {
|
||||
if (!$directory->isDir() || $directory->isDot()) {
|
||||
continue;
|
||||
}
|
||||
|
||||
// Path to the languages folder
|
||||
$lang_path = $directory->getPathName() . '/' . $folder_path;
|
||||
|
||||
// If this folder exists, add it to the list of paths
|
||||
if (file_exists($lang_path)) {
|
||||
$paths []= $lang_path;
|
||||
}
|
||||
}
|
||||
}
|
||||
return $paths;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -25,6 +25,8 @@ class Themes extends Iterator
|
||||
|
||||
public function __construct(Grav $grav)
|
||||
{
|
||||
parent::__construct();
|
||||
|
||||
$this->grav = $grav;
|
||||
$this->config = $grav['config'];
|
||||
|
||||
@@ -34,13 +36,18 @@ class Themes extends Iterator
|
||||
|
||||
public function init()
|
||||
{
|
||||
/** @var EventDispatcher $events */
|
||||
$events = $this->grav['events'];
|
||||
|
||||
/** @var Themes $themes */
|
||||
$themes = $this->grav['themes'];
|
||||
$themes->configure();
|
||||
|
||||
$this->initTheme();
|
||||
}
|
||||
|
||||
public function initTheme()
|
||||
{
|
||||
/** @var Themes $themes */
|
||||
$themes = $this->grav['themes'];
|
||||
|
||||
try {
|
||||
$instance = $themes->load();
|
||||
} catch (\InvalidArgumentException $e) {
|
||||
@@ -48,10 +55,15 @@ class Themes extends Iterator
|
||||
}
|
||||
|
||||
if ($instance instanceof EventSubscriberInterface) {
|
||||
/** @var EventDispatcher $events */
|
||||
$events = $this->grav['events'];
|
||||
|
||||
$events->addSubscriber($instance);
|
||||
}
|
||||
|
||||
$this->grav['theme'] = $instance;
|
||||
|
||||
$this->grav->fireEvent('onThemeInitialized');
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -74,8 +86,12 @@ class Themes extends Iterator
|
||||
continue;
|
||||
}
|
||||
|
||||
$type = $directory->getBasename();
|
||||
$list[$type] = self::get($type);
|
||||
$theme = $directory->getBasename();
|
||||
$result = self::get($theme);
|
||||
|
||||
if ($result) {
|
||||
$list[$theme] = $result;
|
||||
}
|
||||
}
|
||||
}
|
||||
ksort($list);
|
||||
@@ -100,14 +116,20 @@ class Themes extends Iterator
|
||||
$blueprint = $blueprints->get("{$name}/blueprints");
|
||||
$blueprint->name = $name;
|
||||
|
||||
// Load default configuration.
|
||||
$file = CompiledYamlFile::instance("themes://{$name}/{$name}" . YAML_EXT);
|
||||
|
||||
// ensure this is a valid theme
|
||||
if (!$file->exists()) {
|
||||
return null;
|
||||
}
|
||||
|
||||
// Find thumbnail.
|
||||
$thumb = "themes://{$name}/thumbnail.jpg";
|
||||
if ($path = $this->grav['locator']->findResource($thumb, false)) {
|
||||
$blueprint->set('thumbnail', $this->grav['base_url'] . '/' . $path);
|
||||
}
|
||||
|
||||
// Load default configuration.
|
||||
$file = CompiledYamlFile::instance("themes://{$name}/{$name}" . YAML_EXT);
|
||||
$obj = new Data($file->content(), $blueprint);
|
||||
|
||||
// Override with user configuration.
|
||||
|
||||
@@ -20,6 +20,10 @@ trait WriteCacheFileTrait
|
||||
*/
|
||||
protected function writeCacheFile($file, $content)
|
||||
{
|
||||
if (empty($file)) {
|
||||
return;
|
||||
}
|
||||
|
||||
if (!isset(self::$umask)) {
|
||||
self::$umask = self::getGrav()['config']->get('system.twig.umask_fix', false);
|
||||
}
|
||||
|
||||
@@ -32,6 +32,9 @@ class User extends Data
|
||||
{
|
||||
$locator = self::getGrav()['locator'];
|
||||
|
||||
// force lowercase of username
|
||||
$username = strtolower($username);
|
||||
|
||||
$blueprints = new Blueprints('blueprints://');
|
||||
$blueprint = $blueprints->get('user/account');
|
||||
$file_path = $locator->findResource('account://' . $username . YAML_EXT);
|
||||
|
||||
@@ -2,14 +2,24 @@
|
||||
namespace Grav\Console\Cli;
|
||||
|
||||
use Grav\Common\Filesystem\Folder;
|
||||
use Grav\Console\ConsoleCommand;
|
||||
use Symfony\Component\Console\Command\Command;
|
||||
use Symfony\Component\Console\Input\InputInterface;
|
||||
use Symfony\Component\Console\Input\InputOption;
|
||||
use Symfony\Component\Console\Output\OutputInterface;
|
||||
use Symfony\Component\Console\Formatter\OutputFormatterStyle;
|
||||
|
||||
/**
|
||||
* Class CleanCommand
|
||||
* @package Grav\Console\Cli
|
||||
*/
|
||||
class CleanCommand extends ConsoleCommand
|
||||
class CleanCommand extends Command
|
||||
{
|
||||
/* @var InputInterface $output */
|
||||
protected $input;
|
||||
|
||||
/* @var OutputInterface $output */
|
||||
protected $output;
|
||||
|
||||
/**
|
||||
* @var array
|
||||
*/
|
||||
@@ -83,7 +93,7 @@ class CleanCommand extends ConsoleCommand
|
||||
'vendor/maximebf/debugbar/bower.json',
|
||||
'vendor/maximebf/debugbar/composer.json',
|
||||
'vendor/maximebf/debugbar/.bowerrc',
|
||||
'vendor/maximebf/debugbar/src/Debugbar/Resources/vendor',
|
||||
'vendor/maximebf/debugbar/src/DebugBar/Resources/vendor',
|
||||
'vendor/maximebf/debugbar/demo',
|
||||
'vendor/maximebf/debugbar/docs',
|
||||
'vendor/maximebf/debugbar/tests',
|
||||
@@ -121,28 +131,34 @@ class CleanCommand extends ConsoleCommand
|
||||
'vendor/rockettheme/toolbox/.travis.yml',
|
||||
'vendor/rockettheme/toolbox/composer.json',
|
||||
'vendor/rockettheme/toolbox/phpunit.xml',
|
||||
'vendor/symfony/console/Symfony/Component/Console/composer.json',
|
||||
'vendor/symfony/console/Symfony/Component/Console/phpunit.xml.dist',
|
||||
'vendor/symfony/console/Symfony/Component/Console/.gitignore',
|
||||
'vendor/symfony/console/Symfony/Component/Console/.git',
|
||||
'vendor/symfony/console/Symfony/Component/Console/Tests',
|
||||
'vendor/symfony/event-dispatcher/Symfony/Component/EventDispatcher/.git',
|
||||
'vendor/symfony/event-dispatcher/Symfony/Component/EventDispatcher/.gitignore',
|
||||
'vendor/symfony/event-dispatcher/Symfony/Component/EventDispatcher/composer.json',
|
||||
'vendor/symfony/event-dispatcher/Symfony/Component/EventDispatcher/phpunit.xml.dist',
|
||||
'vendor/symfony/event-dispatcher/Symfony/Component/EventDispatcher/Tests',
|
||||
'vendor/symfony/yaml/Symfony/Component/Yaml/composer.json',
|
||||
'vendor/symfony/yaml/Symfony/Component/Yaml/phpunit.xml.dist',
|
||||
'vendor/symfony/yaml/Symfony/Component/Yaml/.gitignore',
|
||||
'vendor/symfony/yaml/Symfony/Component/Yaml/.git',
|
||||
'vendor/symfony/yaml/Symfony/Component/Yaml/Tests',
|
||||
'vendor/tracy/tracy/.gitattributes',
|
||||
'vendor/tracy/tracy/.travis.yml',
|
||||
'vendor/tracy/tracy/composer.json',
|
||||
'vendor/tracy/tracy/.gitignore',
|
||||
'vendor/tracy/tracy/.git',
|
||||
'vendor/tracy/tracy/examples',
|
||||
'vendor/tracy/tracy/tests',
|
||||
'vendor/symfony/console/composer.json',
|
||||
'vendor/symfony/console/phpunit.xml.dist',
|
||||
'vendor/symfony/console/.gitignore',
|
||||
'vendor/symfony/console/.git',
|
||||
'vendor/symfony/console/Tester',
|
||||
'vendor/symfony/console/Tests',
|
||||
'vendor/symfony/event-dispatcher/.git',
|
||||
'vendor/symfony/event-dispatcher/.gitignore',
|
||||
'vendor/symfony/event-dispatcher/composer.json',
|
||||
'vendor/symfony/event-dispatcher/phpunit.xml.dist',
|
||||
'vendor/symfony/event-dispatcher/Tests',
|
||||
'vendor/symfony/polyfill-iconv/.git',
|
||||
'vendor/symfony/polyfill-iconv/.gitignore',
|
||||
'vendor/symfony/polyfill-iconv/composer.json',
|
||||
'vendor/symfony/polyfill-mbstring/.git',
|
||||
'vendor/symfony/polyfill-mbstring/.gitignore',
|
||||
'vendor/symfony/polyfill-mbstring/composer.json',
|
||||
'vendor/symfony/var-dumper/.git',
|
||||
'vendor/symfony/var-dumper/.gitignore',
|
||||
'vendor/symfony/var-dumper/composer.json',
|
||||
'vendor/symfony/var-dumper/phpunit.xml.dist',
|
||||
'vendor/symfony/var-dumper/Test',
|
||||
'vendor/symfony/var-dumper/Tests',
|
||||
'vendor/symfony/yaml/composer.json',
|
||||
'vendor/symfony/yaml/phpunit.xml.dist',
|
||||
'vendor/symfony/yaml/.gitignore',
|
||||
'vendor/symfony/yaml/.git',
|
||||
'vendor/symfony/yaml/Tests',
|
||||
'vendor/twig/twig/.editorconfig',
|
||||
'vendor/twig/twig/.travis.yml',
|
||||
'vendor/twig/twig/.gitignore',
|
||||
@@ -168,8 +184,10 @@ class CleanCommand extends ConsoleCommand
|
||||
/**
|
||||
* @return int|null|void
|
||||
*/
|
||||
protected function serve()
|
||||
protected function execute(InputInterface $input, OutputInterface $output)
|
||||
{
|
||||
$this->setupConsole($input, $output);
|
||||
|
||||
$this->cleanPaths();
|
||||
}
|
||||
|
||||
@@ -177,12 +195,9 @@ class CleanCommand extends ConsoleCommand
|
||||
{
|
||||
$this->output->writeln('');
|
||||
$this->output->writeln('<red>DELETING</red>');
|
||||
|
||||
$anything = false;
|
||||
|
||||
foreach ($this->paths_to_remove as $path) {
|
||||
$path = ROOT_DIR . $path;
|
||||
|
||||
if (is_dir($path) && @Folder::delete($path)) {
|
||||
$anything = true;
|
||||
$this->output->writeln('<red>dir: </red>' . $path);
|
||||
@@ -191,12 +206,30 @@ class CleanCommand extends ConsoleCommand
|
||||
$this->output->writeln('<red>file: </red>' . $path);
|
||||
}
|
||||
}
|
||||
|
||||
if (!$anything) {
|
||||
$this->output->writeln('');
|
||||
$this->output->writeln('<green>Nothing to clean...</green>');
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Set colors style definition for the formatter.
|
||||
*
|
||||
* @param InputInterface $input
|
||||
* @param OutputInterface $output
|
||||
*/
|
||||
public function setupConsole(InputInterface $input, OutputInterface $output)
|
||||
{
|
||||
$this->input = $input;
|
||||
$this->output = $output;
|
||||
|
||||
$this->output->getFormatter()->setStyle('normal', new OutputFormatterStyle('white'));
|
||||
$this->output->getFormatter()->setStyle('yellow', new OutputFormatterStyle('yellow', null, array('bold')));
|
||||
$this->output->getFormatter()->setStyle('red', new OutputFormatterStyle('red', null, array('bold')));
|
||||
$this->output->getFormatter()->setStyle('cyan', new OutputFormatterStyle('cyan', null, array('bold')));
|
||||
$this->output->getFormatter()->setStyle('green', new OutputFormatterStyle('green', null, array('bold')));
|
||||
$this->output->getFormatter()->setStyle('magenta', new OutputFormatterStyle('magenta', null, array('bold')));
|
||||
$this->output->getFormatter()->setStyle('white', new OutputFormatterStyle('white', null, array('bold')));
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -48,7 +48,7 @@ class SandboxCommand extends ConsoleCommand
|
||||
'/.editorconfig' => '/.editorconfig',
|
||||
'/.gitignore' => '/.gitignore',
|
||||
'/CHANGELOG.md' => '/CHANGELOG.md',
|
||||
'/LICENSE' => '/LICENSE',
|
||||
'/LICENSE.txt' => '/LICENSE.txt',
|
||||
'/README.md' => '/README.md',
|
||||
'/index.php' => '/index.php',
|
||||
'/composer.json' => '/composer.json',
|
||||
@@ -162,7 +162,7 @@ class SandboxCommand extends ConsoleCommand
|
||||
$to = $this->destination . $target;
|
||||
|
||||
$this->output->writeln(' <cyan>' . $source . '</cyan> <comment>-></comment> ' . $to);
|
||||
Folder::rcopy($from, $to);
|
||||
@Folder::rcopy($from, $to);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -21,6 +21,16 @@ class IndexCommand extends ConsoleCommand
|
||||
*/
|
||||
protected $gpm;
|
||||
|
||||
/**
|
||||
* @var
|
||||
*/
|
||||
protected $options;
|
||||
|
||||
/**
|
||||
* @var array
|
||||
*/
|
||||
protected $sortKeys = ['name', 'slug', 'author', 'date'];
|
||||
|
||||
/**
|
||||
*
|
||||
*/
|
||||
@@ -34,6 +44,43 @@ class IndexCommand extends ConsoleCommand
|
||||
InputOption::VALUE_NONE,
|
||||
'Force re-fetching the data from remote'
|
||||
)
|
||||
->addOption(
|
||||
'filter',
|
||||
'F',
|
||||
InputOption::VALUE_REQUIRED | InputOption::VALUE_IS_ARRAY,
|
||||
'Allows to limit the results based on one or multiple filters input. This can be either portion of a name/slug or a regex'
|
||||
)
|
||||
->addOption(
|
||||
'themes-only',
|
||||
'T',
|
||||
InputOption::VALUE_NONE,
|
||||
'Filters the results to only Themes'
|
||||
)
|
||||
->addOption(
|
||||
'plugins-only',
|
||||
'P',
|
||||
InputOption::VALUE_NONE,
|
||||
'Filters the results to only Plugins'
|
||||
)
|
||||
->addOption(
|
||||
'updates-only',
|
||||
'U',
|
||||
InputOption::VALUE_NONE,
|
||||
'Filters the results to Updatable Themes and Plugins only'
|
||||
)
|
||||
->addOption(
|
||||
'sort',
|
||||
's',
|
||||
InputOption::VALUE_REQUIRED | InputOption::VALUE_IS_ARRAY,
|
||||
'Allows to sort (ASC) the results based on one or multiple keys. SORT can be either "name", "slug", "author", "date"',
|
||||
['date']
|
||||
)
|
||||
->addOption(
|
||||
'desc',
|
||||
'D',
|
||||
InputOption::VALUE_NONE,
|
||||
'Reverses the order of the output.'
|
||||
)
|
||||
->setDescription("Lists the plugins and themes available for installation")
|
||||
->setHelp('The <info>index</info> command lists the plugins and themes available for installation')
|
||||
;
|
||||
@@ -44,16 +91,21 @@ class IndexCommand extends ConsoleCommand
|
||||
*/
|
||||
protected function serve()
|
||||
{
|
||||
$this->gpm = new GPM($this->input->getOption('force'));
|
||||
$this->options = $this->input->getOptions();
|
||||
|
||||
$this->gpm = new GPM($this->options['force']);
|
||||
|
||||
$this->data = $this->gpm->getRepository();
|
||||
|
||||
$this->output->writeln('');
|
||||
|
||||
foreach ($this->data as $type => $packages) {
|
||||
$data = $this->filter($this->data);
|
||||
|
||||
foreach ($data as $type => $packages) {
|
||||
$this->output->writeln("<green>" . ucfirst($type) . "</green> [ " . count($packages) . " ]");
|
||||
|
||||
$index = 0;
|
||||
$index = 0;
|
||||
$packages = $this->sort($packages);
|
||||
foreach ($packages as $slug => $package) {
|
||||
$this->output->writeln(
|
||||
// index
|
||||
@@ -108,4 +160,65 @@ class IndexCommand extends ConsoleCommand
|
||||
|
||||
return '';
|
||||
}
|
||||
|
||||
/**
|
||||
* @param $data
|
||||
*
|
||||
* @return mixed
|
||||
*/
|
||||
public function filter($data)
|
||||
{
|
||||
// filtering and sorting
|
||||
if ($this->options['plugins-only']) {
|
||||
unset($data['themes']);
|
||||
}
|
||||
if ($this->options['themes-only']) {
|
||||
unset($data['plugins']);
|
||||
}
|
||||
|
||||
if ($this->options['filter'] || $this->options['updates-only'] || $this->options['desc']) {
|
||||
foreach ($data as $type => $packages) {
|
||||
foreach ($packages as $slug => $package) {
|
||||
$filter = true;
|
||||
|
||||
// Filtering by string
|
||||
if ($this->options['filter']) {
|
||||
$filter = preg_grep('/(' . (implode('|', $this->options['filter'])) . ')/i', [$slug, $package->name]);
|
||||
}
|
||||
|
||||
// Filtering updatables only
|
||||
if ($this->options['updates-only'] && $filter) {
|
||||
$method = ucfirst(preg_replace("/s$/", '', $package->package_type));
|
||||
$filter = $this->gpm->{'is' . $method . 'Updatable'}($package->slug);
|
||||
}
|
||||
|
||||
if (!$filter) {
|
||||
unset($data[$type][$slug]);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
return $data;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param $packages
|
||||
*/
|
||||
public function sort($packages)
|
||||
{
|
||||
foreach ($this->options['sort'] as $key) {
|
||||
$packages = $packages->sort(function ($a, $b) use ($key) {
|
||||
switch ($key) {
|
||||
case 'author':
|
||||
return strcmp($a->{$key}['name'], $b->{$key}['name']);
|
||||
break;
|
||||
default:
|
||||
return strcmp($a->$key, $b->$key);
|
||||
}
|
||||
}, $this->options['desc'] ? true : false);
|
||||
}
|
||||
|
||||
return $packages;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -82,6 +82,18 @@ class SelfupgradeCommand extends ConsoleCommand
|
||||
$remote = $this->upgrader->getRemoteVersion();
|
||||
$release = strftime('%c', strtotime($this->upgrader->getReleaseDate()));
|
||||
|
||||
if (!$this->upgrader->meetsRequirements()) {
|
||||
$this->output->writeln("");
|
||||
$this->output->writeln("<red>ATTENTION:</red>");
|
||||
$this->output->writeln(" Grav has increased the minimum PHP requirement.");
|
||||
$this->output->writeln(" You are currently running PHP <red>" . PHP_VERSION . "</red>, but PHP <green>" . GRAV_PHP_MIN . "</green> is required.");
|
||||
$this->output->writeln(" Additional information: <white>http://getgrav.org/blog/changing-php-requirements-to-5.5</white>");
|
||||
$this->output->writeln("");
|
||||
$this->output->writeln("Selfupgrade aborted.");
|
||||
$this->output->writeln("");
|
||||
exit;
|
||||
}
|
||||
|
||||
if (!$this->upgrader->isUpgradable()) {
|
||||
$this->output->writeln("You are already running the latest version of Grav (v" . $local . ") released on " . $release);
|
||||
exit;
|
||||
|
||||
@@ -1,8 +0,0 @@
|
||||
<?php
|
||||
namespace Grav;
|
||||
|
||||
|
||||
class TestCase extends \PHPUnit_Framework_TestCase
|
||||
{
|
||||
|
||||
}
|
||||
@@ -1,6 +0,0 @@
|
||||
<?php
|
||||
|
||||
error_reporting(E_ALL);
|
||||
date_default_timezone_set(@date_default_timezone_get());
|
||||
require_once __DIR__.'/../../vendor/autoload.php';
|
||||
require_once __DIR__.'/Grav/TestCase.php';
|
||||
@@ -1,18 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<phpunit backupGlobals="false"
|
||||
backupStaticAttributes="false"
|
||||
colors="true"
|
||||
convertErrorsToExceptions="true"
|
||||
convertNoticesToExceptions="true"
|
||||
convertWarningsToExceptions="true"
|
||||
processIsolation="false"
|
||||
stopOnFailure="false"
|
||||
syntaxCheck="false"
|
||||
bootstrap="./bootstrap.php"
|
||||
>
|
||||
<testsuites>
|
||||
<testsuite name="Full Grav Test Suite">
|
||||
<directory>./Grav/</directory>
|
||||
</testsuite>
|
||||
</testsuites>
|
||||
</phpunit>
|
||||
Reference in New Issue
Block a user