mirror of
https://github.com/Mibew/boilerplate-plugin.git
synced 2025-02-05 08:44:42 +03:00
Use YAML config for the core
This commit is contained in:
parent
11a597163b
commit
96b6df84ce
19
Plugin.php
19
Plugin.php
@ -24,14 +24,19 @@
|
||||
* "<mibew root>/plugins/<Vendor Name>/Mibew/Plugin/<Plugin name>/Plugin.php"
|
||||
* file. Names of plugin and directories/files are case sensitive!
|
||||
*
|
||||
* To turn the plugin on add the following to <mibew root>/libs/config.php
|
||||
* To turn the plugin on add its definition to the following to "plugins"
|
||||
* structure in <mibew root>/configs/config.yml if the "plugins" structure looks
|
||||
* like:
|
||||
* <code>
|
||||
* $plugins_list[] = array(
|
||||
* 'name' => 'Mibew:Boilerplate',
|
||||
* 'config' => array(
|
||||
* 'very_important_value' => '$3.50',
|
||||
* );
|
||||
* );
|
||||
* plugins: []
|
||||
* </code>
|
||||
* it will become:
|
||||
* <code>
|
||||
* plugins:
|
||||
* -
|
||||
* name: "Mibew:Boilerplate"
|
||||
* config:
|
||||
* very_important_value: "$3.50"
|
||||
* </code>
|
||||
*/
|
||||
|
||||
|
16
README.md
16
README.md
@ -7,14 +7,14 @@ It does nothing but can be used as a template for a real plugin.
|
||||
1. Download files of the plugin.
|
||||
2. Create folder "```<Mibew root>```/plugins/Mibew/Mibew/Plugin/Boilerplate" (case does matter).
|
||||
3. Put files of the plugins to the just created folder.
|
||||
4. Add the following lines to the end of "```<Mibew root>```/libs/config.php":
|
||||
```php
|
||||
$plugins_list[] = array(
|
||||
'name' => 'Mibew:Boilerplate',
|
||||
'config' => array(
|
||||
'very_important_value' => '$3.50',
|
||||
),
|
||||
);
|
||||
4. Add plugins defenition to "plugins" structure in "```<Mibew root>```/configs/config.yml".
|
||||
If the "plugins" stucture looks like ```plugins: []``` it will become:
|
||||
```yaml
|
||||
plugins:
|
||||
-
|
||||
name: "Mibew:Boilerplate"
|
||||
config:
|
||||
very_important_value: "$3.50"
|
||||
```
|
||||
|
||||
## License
|
||||
|
Loading…
Reference in New Issue
Block a user