bumblebee-status/bumblebee/modules/time.py
Tobias Witek e895400589 [modules] Add battery indicator plugin
Add a plugin that displays the remaining battery power in %. This also
introduces the concept of arguments that can be passed to a module
during startup by delimiting the module name with ":", for example:

-m battery:BAT1 to query the BAT1 device.

Note that this works to an arbitray length, i.e. if a module accepts 3
parameters: -m <modulename>:<A>:<B>:<C>

The module gets the arguments as list.
2016-10-30 18:10:25 +01:00

11 lines
300 B
Python

import datetime
import bumblebee.module
class Module(bumblebee.module.Module):
def __init__(self, theme, args):
super(Module, self).__init__(theme, args)
def data(self):
return datetime.datetime.now().strftime("%x %X")
# vim: tabstop=8 expandtab shiftwidth=4 softtabstop=4