Advertisement
robofred310

__init__.py

Oct 22nd, 2021
118
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 1.06 KB | None | 0 0
  1. # -*- coding: utf-8 -*-
  2. from __future__ import absolute_import, unicode_literals
  3.  
  4. import octoprint.plugin
  5.  
  6. class HofstraPlugin(
  7.     octoprint.plugins.StartupPlugin,
  8.     octoprint.plugins.TemplatePlugin,
  9.     octoprint.plugins.SettingsPlugin,
  10.     octoprint.plugin.AssetPlugin):
  11.  
  12.     def on_after_startup(self):
  13.         self._logger.info("This is the hofstra C&C")
  14.  
  15.     def get_settings_defaults(self):
  16.         return dict(url="https://yahoo.com")
  17.  
  18.     def get_template_configs(self):
  19.         return[
  20.             dict(type="navbar", custom_bindings=False),
  21.             dict(type="settings", custom_bindings=False),
  22.             dict(type="sidebar", custom_bindings=True)
  23.         ]
  24.  
  25.     def get_assets(self):
  26.         return dict(
  27.             js=["js/hofstra.js"],
  28.             css=["css/hofstra.css"],
  29.             less=["less/hofstra.less"]
  30.         )
  31.  
  32. __plugin_name__ = "hofstra"
  33. __plugin_version__ = "1.0.0"
  34. __plugin_description__ = "Let's hofstra It together in OctoPrint"
  35. __plugin_pythoncompat__ = ">=2.7,<4"
  36. __plugin_implementation__ = HofstraPlugin()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement