attempt software update check

testing testing is this thing on
This commit is contained in:
ntoff 2017-04-20 01:36:10 +10:00
parent 74a2936c1c
commit 77aecca4f5

View File

@ -13,10 +13,33 @@ class EstopPlugin(octoprint.plugin.AssetPlugin,
)
def get_template_configs(self):
return [
dict(type="sidebar", name="Emergency STOP!", icon="fa fa-times", template="estop_sidebar.jinja2", styles=["display: none"], data_bind="visible: loginState.isUser")
dict(type="sidebar", name="Emergency STOP!", icon="fa icon-print", template="estop_sidebar.jinja2", styles=["display: none"], data_bind="visible: loginState.isUser")
]
__plugin_name__ = "Emergency Stop Button"
__plugin_implementation__ = EstopPlugin()
def get_update_information(self):
return dict(
skeleton=dict(
displayName="Emergency Stop Button",
displayVersion=self._plugin_version,
# version check: github repository
type="github_release",
user="ntoff",
repo="OctoPrint-Estop",
current=self._plugin_version,
# update method: pip
pip="https://github.com/ntoff/OctoPrint-Estop/archive/{target_version}.zip"
)
)
__plugin_name__ = "Emergency Stop Button"
def __plugin_load__():
global __plugin_implementation__
__plugin_implementation__ = __plugin_implementation__ = EstopPlugin()
global __plugin_hooks__
__plugin_hooks__ = {
"octoprint.plugin.softwareupdate.check_config": __plugin_implementation__.get_update_information
}