-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Pluginkit compatibility (composer installer)
Merge pull request #4 from bnomei/master: pluginkit and other improvements
- Loading branch information
Showing
26 changed files
with
1,867 additions
and
50 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
[*.{css,scss,less,js,json,ts,sass,html,hbs,mustache,phtml,html.twig,md,yml}] | ||
charset = utf-8 | ||
indent_style = space | ||
indent_size = 2 | ||
end_of_line = lf | ||
insert_final_newline = true | ||
trim_trailing_whitespace = true | ||
insert_final_newline = true | ||
|
||
[*.md] | ||
indent_size = 4 | ||
trim_trailing_whitespace = false | ||
|
||
[site/templates/**.php] | ||
indent_size = 2 | ||
|
||
[site/snippets/**.php] | ||
indent_size = 2 | ||
|
||
[package.json,.{babelrc,editorconfig,eslintrc,lintstagedrc,stylelintrc}] | ||
indent_style = space | ||
indent_size = 2 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,2 +1,26 @@ | ||
# OS files | ||
.DS_Store | ||
vendor | ||
.php_cs.cache | ||
|
||
/vendor/**/.markdown | ||
|
||
# files of Composer dependencies that are not needed for the plugin | ||
/vendor/**/.* | ||
/vendor/**/*.json | ||
/vendor/**/*.txt | ||
/vendor/**/*.md | ||
/vendor/**/*.yml | ||
/vendor/**/*.yaml | ||
/vendor/**/*.xml | ||
/vendor/**/*.dist | ||
/vendor/**/readme.php | ||
/vendor/**/LICENSE | ||
/vendor/**/COPYING | ||
/vendor/**/VERSION | ||
/vendor/**/docs/* | ||
/vendor/**/example/* | ||
/vendor/**/examples/* | ||
/vendor/**/test/* | ||
/vendor/**/tests/* | ||
/vendor/**/php4/* | ||
/vendor/getkirby/composer-installer |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
<?php | ||
|
||
$finder = PhpCsFixer\Finder::create() | ||
->exclude('vendor') | ||
->exclude('kirby') | ||
->in(__DIR__) | ||
; | ||
|
||
return PhpCsFixer\Config::create() | ||
->setRules([ | ||
'@PSR2' => true, | ||
]) | ||
->setFinder($finder) | ||
; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,14 @@ | ||
{ | ||
"name": "bvdputte/kirby-log", | ||
"description": "Logging utility for Kirby - based on katzgrau/KLogger", | ||
"version": "0.0.1", | ||
"version": "1.0.0", | ||
"license": "MIT", | ||
"type": "kirby-plugin", | ||
"require": { | ||
"getkirby/composer-installer": "^1.1", | ||
"katzgrau/klogger": "^1.2" | ||
}, | ||
"autoload": { | ||
"files": [ | ||
"config.php" | ||
], | ||
"psr-4": { | ||
"bvdputte\\kirbyLog\\": "src/" | ||
} | ||
|
@@ -19,5 +18,9 @@ | |
"name": "Bart Vandeputte", | ||
"email": "[email protected]" | ||
} | ||
] | ||
], | ||
"config": { | ||
"optimize-autoloader": true, | ||
"sort-packages": true | ||
} | ||
} |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,25 @@ | ||
<?php | ||
|
||
require_once __DIR__ . '/vendor/autoload.php'; | ||
@include_once __DIR__ . '/vendor/autoload.php'; | ||
|
||
Kirby::plugin('bvdputte/kirbylog', [ | ||
'options' => [ | ||
'logfolder' => 'kirbylogs', | ||
'logname' => 'kirbylog.log', | ||
'defaultloglevel' => 'info' | ||
], | ||
]); | ||
|
||
/* | ||
A little Kirby helper function | ||
*/ | ||
if (! function_exists("kirbyLog")) { | ||
function kirbyLog($name = null, $opts = []) | ||
{ | ||
$logName = $name ?? kirby()->option("bvdputte.kirbylog.logname"); | ||
|
||
$kirbyLog = new bvdputte\kirbyLog\Logger($logName, $opts); | ||
|
||
return $kirbyLog; | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
<?php | ||
|
||
// autoload.php @generated by Composer | ||
|
||
require_once __DIR__ . '/composer/autoload_real.php'; | ||
|
||
return ComposerAutoloaderInit9dfc62fa15f5312aa86488031097cc96::getLoader(); |
Oops, something went wrong.