Commit Graph

33 Commits

Author SHA1 Message Date
Udo Spallek
5099227027 Use len() for lists instead of count() for #447 2016-09-28 22:30:19 +02:00
ncoop
2505468515 Notification support for aptget. 2016-06-22 23:57:40 -07:00
ncoop
f03926ed71 Put yaourt docs into code blocks; 80 char width. 2016-06-22 22:44:34 -07:00
ncoop
9d907732f1 Update notifications for pacman, cower, yaourt.
These modules are also runnable directly from terminal.
2016-06-22 22:44:25 -07:00
ncoop
ae1274d5d3 Makes update count algo less wrong. 2016-06-04 21:30:24 -07:00
ncoop
b73dbb1a35 Return early if the check threw an error. 2016-06-04 20:53:12 -07:00
ncoop
5272e10208 Dump data by running as __main__. 2016-06-04 20:32:33 -07:00
ncoop
48273a8205 Unknown update list gives empty string. 2016-06-04 19:54:21 -07:00
ncoop
51675430b1 Notification icon is customizable, and can be None 2016-06-04 19:54:21 -07:00
ncoop
d7d372ff5d Added format_summary option
By default, same as format
2016-06-04 19:54:21 -07:00
ncoop
7fb0794f45 Now returns both the count and a notification body 2016-06-04 19:54:21 -07:00
ncoop
616c68b0f0 Notification displayed on rightclick by default
Notification summary shows the count
Notification icon is `software-update-available`
notif_body concatenates raw or prepared output from all backends

Backends that don't yet output to notif_body should have harmless empty string

Also, linted according to flake8
Corrected typo
2016-06-04 19:54:20 -07:00
ncoop
52ef0e07df Not all lines after the second are updates.
There are 14 here:

```
Last metadata expiration check: 1:16:29 ago on Sat Apr  9 01:14:36 2016.

google-chrome-stable.x86_64            49.0.2623.112-1             google-chrome
kernel.x86_64                          4.4.6-301.fc23              updates
kernel-core.x86_64                     4.4.6-301.fc23              updates
kernel-debug-devel.x86_64              4.4.6-301.fc23              updates
kernel-devel.x86_64                    4.4.6-301.fc23              updates
kernel-headers.x86_64                  4.4.6-301.fc23              updates
kernel-modules.x86_64                  4.4.6-301.fc23              updates
kernel-modules-extra.x86_64            4.4.6-301.fc23              updates
openssh.x86_64                         7.2p2-2.fc23                updates
openssh-askpass.x86_64                 7.2p2-2.fc23                updates
openssh-clients.x86_64                 7.2p2-2.fc23                updates
openssh-server.x86_64                  7.2p2-2.fc23                updates
webkitgtk3.x86_64                      2.4.10-2.fc23               updates
Obsoleting Packages
kernel-headers.x86_64                  4.4.6-301.fc23              updates
    kernel-headers.x86_64              4.4.6-300.fc23              @updates
```
2016-04-09 03:35:45 -07:00
ncoop
c33a798b86 Simple 'dnf check-updates' backend for updates 2016-04-09 03:35:45 -07:00
Erik Johnson
4867afeda1 Change color_no_updates to None to default to i3bar color
If ``statusline`` is not set in ``~/.config/i3/config``, it defaults to
``#ffffff`` (white). Therefore, the default behavior of the updates
module in this case is to show white for both ``color_no_updates``
(system is up-to-date) and ``color_working`` (update check in progress).

However, if one sets ``statusline`` in their ``~/.config/i3/config``,
then the color will be white when the system is up-to-date, forcing the
user to manually set ``color_no_updates`` if they would prefer it match
their default i3bar color.

This commit changes the default value of ``color_no_updates`` to
``None`` so that it matches the default i3bar unless overridden.
2016-03-25 00:29:19 -05:00
Erik Johnson
2a886ffa1e Fix KeyError when using backend-specific updates formatter
When a backend-specific formatter (i.e. ``{Pacman}``, ``{Cower}``, etc.)
is used, and the initial "working" status is set, the loop in which the
update totals is compiled has not yet run, leading to a KeyError.

This commit fixes the traceback by setting initial values of "?" for
these formatters before the initial "working" status is set.
2016-03-16 21:47:14 -05:00
enkore
58ca67109c Change default mode to standalone=True 2016-02-12 14:12:43 +01:00
enkore
57be3c45a9 updates: add an individual formatter for every backend 2016-02-01 13:11:58 +01:00
enkore
d7af5c762f updates: new formula®
Start an extra worker ourselves, then use a condition to notify it
of explicit update requests
2016-02-01 12:48:56 +01:00
enkore
39e2c64570 updates: allow display of a "working/busy" message 2016-02-01 12:20:30 +01:00
schroeji
e70a199d69 Removed indentation in docstring. 2015-09-25 23:06:38 +02:00
schroeji
18062dd416 Moved the docstring and added usage examples. 2015-09-25 20:22:26 +02:00
schroeji
e9835070e2 Fix for Travis CI 2015-09-25 11:15:56 +02:00
schroeji
f577bd2bf9 Added aur_only mode for yaourt backend 2015-09-21 13:08:05 +02:00
schroeji
1e6e42a3d8 Fixed for Travis CI 2015-09-17 13:42:22 +02:00
schroeji
e6d88abaae Added yaourt backend for the updates script. 2015-09-17 12:10:49 +02:00
Lukáš Mandák
3a69a5d0eb Fixed typo. 2015-06-03 20:06:16 +02:00
Lukáš Mandák
96ef3656c8 Simplified pacman and cower backends.
Fixed bug in `aptget` backend.
2015-06-03 16:43:24 +02:00
Lukáš Mandák
3496a7bae5 Checks for internet connection before running backends. 2015-06-03 12:19:17 +02:00
Lukáš Mandák
0b507807bc Updated docs. 2015-06-02 23:22:49 +02:00
Lukáš Mandák
7d48a00b1e Updated docs. 2015-06-02 22:49:12 +02:00
Lukáš Mandák
b47f099dcf Added backend for apt-get. 2015-06-02 19:40:18 +02:00
Lukáš Mandák
a42d78c5c5 Added Update indicator module with pacman and cower backends. 2015-06-01 12:55:47 +02:00