diff options
author | nodiscc <nodiscc@gmail.com> | 2020-09-12 12:38:05 +0000 |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-09-12 12:38:05 +0000 |
commit | e809908f9e593b2cec11f72849caa1dae6394451 (patch) | |
tree | b26f77ec59b7c25800599d751212db72cfc65870 /doc/md/Plugins.md | |
parent | 6128ab6a55430a2b705be31ff417c0c552a0db1f (diff) | |
parent | 97870f35121bed42ac126652d81bc43416b44356 (diff) | |
download | Shaarli-e809908f9e593b2cec11f72849caa1dae6394451.tar.gz Shaarli-e809908f9e593b2cec11f72849caa1dae6394451.tar.zst Shaarli-e809908f9e593b2cec11f72849caa1dae6394451.zip |
Merge pull request #1389 from shaarli/doc-rework-setup
doc: rework installation/setup guides, general refactoring
Diffstat (limited to 'doc/md/Plugins.md')
-rw-r--r-- | doc/md/Plugins.md | 61 |
1 files changed, 22 insertions, 39 deletions
diff --git a/doc/md/Plugins.md b/doc/md/Plugins.md index 3e261815..a9f5f1a8 100644 --- a/doc/md/Plugins.md +++ b/doc/md/Plugins.md | |||
@@ -1,14 +1,13 @@ | |||
1 | ## Plugin installation | 1 | # Plugins |
2 | 2 | ||
3 | There is a bunch of plugins shipped with Shaarli, where there is nothing to do to install them. | 3 | ## Installation |
4 | 4 | ||
5 | If you want to install a third party plugin: | 5 | For plugins shipped with Shaarli, no installation is required. |
6 | 6 | ||
7 | - Download it. | 7 | If you want to install a third party plugin, download it to the `plugins` directory in Shaarli's installation folder: |
8 | - Put it in the `plugins` directory in Shaarli's installation folder. | ||
9 | - Make sure you put it correctly: | ||
10 | 8 | ||
11 | ``` | 9 | ```bash |
10 | # example directory structure | ||
12 | | index.php | 11 | | index.php |
13 | | plugins/ | 12 | | plugins/ |
14 | |---| custom_plugin/ | 13 | |---| custom_plugin/ |
@@ -17,63 +16,47 @@ If you want to install a third party plugin: | |||
17 | 16 | ||
18 | ``` | 17 | ``` |
19 | 18 | ||
20 | * Make sure your webserver can read and write the files in your plugin folder. | 19 | Make sure your webserver can read and write the files in your plugin folder. |
21 | 20 | ||
22 | ## Plugin configuration | ||
23 | 21 | ||
24 | In Shaarli's administration page (`Tools` link), go to `Plugin administration`. | 22 | ## Configuration |
25 | 23 | ||
26 | Here you can enable and disable all plugins available, and configure them. | 24 | From Shaarli's administration page (`Tools` link), go to `Plugin administration`. Here you can enable and disable all plugins available, and configure them. |
27 | 25 | ||
28 | ![administration screenshot](https://camo.githubusercontent.com/5da68e191969007492ca0fbeb25f3b2357b748cc/687474703a2f2f692e696d6775722e636f6d2f766837544643712e706e67) | 26 | ![administration screenshot](https://camo.githubusercontent.com/5da68e191969007492ca0fbeb25f3b2357b748cc/687474703a2f2f692e696d6775722e636f6d2f766837544643712e706e67) |
29 | 27 | ||
30 | ## Plugin order | 28 | |
29 | ## Order | ||
31 | 30 | ||
32 | In the plugin administration page, you can move enabled plugins to the top or bottom of the list. The first plugins in the list will be processed first. | 31 | In the plugin administration page, you can move enabled plugins to the top or bottom of the list. The first plugins in the list will be processed first. |
33 | 32 | ||
34 | This is important in case plugins are depending on each other. Read plugins README details for more information. | 33 | This is important in case plugins depend on each other. Read plugins READMEs for more information. |
35 | 34 | ||
36 | **Use case**: The (non existent) plugin `shaares_footer` adds a footer to every shaare in Markdown syntax. It needs to be processed *before* (higher in the list) the Markdown plugin. Otherwise its syntax won't be translated in HTML. | 35 | **Use case**: The (non existent) plugin `shaares_footer` adds a footer to every shaare in Markdown syntax. It needs to be processed *before* (higher in the list) the Markdown plugin. Otherwise its syntax won't be translated in HTML. |
37 | 36 | ||
38 | ## File mode | ||
39 | 37 | ||
40 | Enabled plugin are stored in your `config.json.php` parameters file, under the `array`: | 38 | ## Configuration file |
41 | 39 | ||
42 | ```php | 40 | Enabled plugins are stored in your [Configuration file](Shaarli-configuration). |
43 | $GLOBALS['config']['ENABLED_PLUGINS'] | ||
44 | ``` | ||
45 | 41 | ||
46 | You can edit them manually here. | 42 | ## Usage |
47 | Example: | ||
48 | 43 | ||
49 | ```php | 44 | ### Official plugins |
50 | $GLOBALS['config']['ENABLED_PLUGINS'] = array( | ||
51 | 'qrcode', | ||
52 | 'archiveorg', | ||
53 | 'wallabag', | ||
54 | 'markdown', | ||
55 | ); | ||
56 | ``` | ||
57 | |||
58 | ### Plugin usage | ||
59 | |||
60 | #### Official plugins | ||
61 | 45 | ||
62 | Usage of each plugin is documented in it's README file: | 46 | Usage of each plugin is documented in it's README file: |
63 | 47 | ||
64 | * `addlink-toolbar`: Adds the addlink input on the linklist page | 48 | * `addlink-toolbar`: Adds the addlink input on the Shaares list page |
65 | * `archiveorg`: For each link, add an Archive.org icon | 49 | * `archiveorg`: For each Shaare, add a link to the archived page on Archive.org |
66 | * `default_colors`: Override default theme colors. | 50 | * `default_colors`: Override default theme colors. |
67 | * `isso`: Let visitor comment your shaares on permalinks with Isso. | 51 | * `isso`: Let visitor comment your shaares on permalinks with Isso. |
68 | * [`markdown`](https://github.com/shaarli/Shaarli/blob/master/plugins/markdown/README.md): Render shaare description with Markdown syntax. | 52 | * [`markdown`](https://github.com/shaarli/Shaarli/blob/master/plugins/markdown/README.md): Render shaare description with Markdown syntax. |
69 | * `piwik`: A plugin that adds Piwik tracking code to Shaarli pages. | 53 | * `piwik`: A plugin that adds Piwik tracking code to Shaarli pages. |
70 | * [`playvideos`](https://github.com/shaarli/Shaarli/blob/master/plugins/playvideos/README.md): Add a button in the toolbar allowing to watch all videos. | 54 | * [`playvideos`](https://github.com/shaarli/Shaarli/blob/master/plugins/playvideos/README.md): Add a button in the toolbar allowing to watch all videos. |
71 | * `pubsubhubbub`: Enable PubSubHubbub feed publishing | 55 | * `pubsubhubbub`: Enable PubSubHubbub feed publishing |
72 | * `qrcode`: For each link, add a QRCode icon. | 56 | * `qrcode`: For each Shaare, add a QRCode icon. |
73 | * [`wallabag`](https://github.com/shaarli/Shaarli/blob/master/plugins/wallabag/README.md): For each link, add a Wallabag icon to save it in your instance. | 57 | * [`wallabag`](https://github.com/shaarli/Shaarli/blob/master/plugins/wallabag/README.md): For each Shaare, add a Wallabag icon to save it in your instance. |
74 | |||
75 | 58 | ||
76 | 59 | ||
77 | #### Third party plugins | 60 | ### Third party plugins |
78 | 61 | ||
79 | See [Community & related software](https://shaarli.readthedocs.io/en/master/Community-&-Related-software/) | 62 | See [Community & related software](https://shaarli.readthedocs.io/en/master/Community-and-Related-software/) |