Updated docs.
This commit is contained in:
parent
b47f099dcf
commit
7d48a00b1e
@ -7,10 +7,10 @@ Module reference
|
||||
:System: `clock`_ - `disk`_ - `load`_ - `mem`_ - `cpu_usage`_
|
||||
:Audio: `alsa`_ - `pulseaudio`_
|
||||
:Hardware: `battery`_ - `backlight`_ - `temp`_
|
||||
:Network: `network`_
|
||||
:Network: `network`_
|
||||
:Music: `now_playing`_ - `mpd`_
|
||||
:Websites & stuff: `weather`_ - `bitcoin`_ - `reddit`_ - `parcel`_
|
||||
:Other: `mail`_ - `pyload`_ - `text`_
|
||||
:Other: `mail`_ - `pyload`_ - `text`_ - `updates`_
|
||||
:Advanced: `file`_ - `regex`_ - `runwatch`_ - `shell`_
|
||||
|
||||
.. autogen:: i3pystatus Module
|
||||
@ -25,3 +25,12 @@ Mail Backends
|
||||
.. autogen:: i3pystatus.mail SettingsBase
|
||||
|
||||
.. nothin'
|
||||
|
||||
.. _updatebackends:
|
||||
|
||||
Update Backends
|
||||
---------------
|
||||
|
||||
.. autogen:: i3pystatus.updates SettingsBase
|
||||
|
||||
.. nothin'
|
||||
|
@ -2,33 +2,39 @@ from i3pystatus import SettingsBase, IntervalModule, formatp
|
||||
|
||||
|
||||
class Backend(SettingsBase):
|
||||
"""
|
||||
TODO: doc
|
||||
"""
|
||||
|
||||
settings = ()
|
||||
updates = 0
|
||||
|
||||
|
||||
class Updates(IntervalModule):
|
||||
"""
|
||||
Generic update checker
|
||||
Generic update checker.
|
||||
To use select appropriate backend(s) for your system.
|
||||
For list of all available backends see :ref:`updatebackends`.
|
||||
|
||||
Left clicking on the module will refresh the count of upgradeable packages.
|
||||
This may be used to dismiss the notification after updating your system.
|
||||
|
||||
.. rubric:: Available formatters
|
||||
|
||||
* `{count}` — Sum of all available updates from all backends.
|
||||
|
||||
TODO: doc
|
||||
"""
|
||||
|
||||
interval = 60 * 5 # 5 minutes
|
||||
interval = 3600
|
||||
|
||||
settings = (
|
||||
("backends", "List of backends used to check for updates."),
|
||||
("format", ""),
|
||||
("format_no_updates", ""),
|
||||
("color", ""),
|
||||
("color_no_updates", ""),
|
||||
("backends", "Required list of backends used to check for updates."),
|
||||
("format", "String shown when updates are availible. May contain formatters."),
|
||||
("format_no_updates", "String that is shown if no updates are available. If not set the module will be hidden if no updates are available."),
|
||||
"color",
|
||||
"color_no_updates",
|
||||
("interval", "Default interval is set to one hour."),
|
||||
)
|
||||
required = ("backends",)
|
||||
|
||||
backends = None
|
||||
format = "U {count}"
|
||||
format = "Updates: {count}"
|
||||
format_no_updates = None
|
||||
color = "#00DD00"
|
||||
color_no_updates = "#FFFFFF"
|
||||
|
@ -1,11 +1,12 @@
|
||||
from i3pystatus.core.command import run_through_shell
|
||||
|
||||
from i3pystatus.updates import Backend
|
||||
|
||||
|
||||
class Cower(Backend):
|
||||
"""
|
||||
Checks for updates in Arch User Repositories using the `cower` AUR helper.
|
||||
|
||||
Depends on cower AUR agent - https://github.com/falconindy/cower
|
||||
"""
|
||||
|
||||
@property
|
||||
|
@ -1,12 +1,11 @@
|
||||
from i3pystatus.core.command import run_through_shell
|
||||
|
||||
from i3pystatus.updates import Backend
|
||||
|
||||
|
||||
class Pacman(Backend):
|
||||
"""
|
||||
Checks for updates in Arch Linux pacman repositories using the
|
||||
`checkupdates` script.
|
||||
Checks for updates in Arch Linux repositories using the
|
||||
`checkupdates` script which is part of the `pacman` package.
|
||||
"""
|
||||
|
||||
@property
|
||||
|
Loading…
Reference in New Issue
Block a user