Skip to content

Plugin API

Gobinath edited this page May 29, 2021 · 1 revision

Safe Eyes is designed to be extensible using its plugin API. The core engine is only responsible to manage breaks and schedule them according to the interval configurations. All other features including the break screen are plugins and can be controlled from the plugins tab. This section covers the new plugin API introduced in Safe Eyes 3.0.0 for anyone willing to write their own plugin for Safe Eyes. Third-party developers are welcomed to submit your plugins to the official plugins repository: safeeyes-plugins

Skeleton of Plugin

System plugins are in the /usr/lib/python3/dist-packages/safeeyes/plugins directory. Third party plugins must be installed into the ~/.config/safeeyes/plugins directory. A plugin must have a unique lower alphabetic folder name which is the id of the plugin and the following files to be accepted as a plugin:

~/.config/safeeyes/plugins
                      |-<pluginid>
                              |- config.json
                              |- icon.png
                              |- plugin.py
                              |- dependency_checker.py (optional)

[WIP]

Clone this wiki locally