Merge pull request #47 from pierre87/newkernelmodule

new module that displays current kernel version
This commit is contained in:
tobi-wan-kenobi 2017-03-03 19:11:56 +01:00 committed by GitHub
commit 64386098b6
2 changed files with 16 additions and 0 deletions

View file

@ -0,0 +1,13 @@
import bumblebee.input
import bumblebee.output
import bumblebee.engine
class Module(bumblebee.engine.Module):
def __init__(self, engine, config):
super(Module, self).__init__(engine, config,
bumblebee.output.Widget(full_text=self.output)
)
self._release_name = bumblebee.util.execute("uname -r")[:-1]
def output(self, widget):
return self._release_name

View file

@ -38,6 +38,9 @@
"muted": { "prefix": "" }, "muted": { "prefix": "" },
"unmuted": { "prefix": "" } "unmuted": { "prefix": "" }
}, },
"kernel": {
"prefix": "\uf17c"
},
"nic": { "nic": {
"wireless-up": { "prefix": "" }, "wireless-up": { "prefix": "" },
"wireless-down": { "prefix": "" }, "wireless-down": { "prefix": "" },