| Age | Commit message (Collapse) | Author | 
|---|
|  |  | 
|  | Fix issue #283 (shown IP belonging to wrong network interface) | 
|  | The following commit:
  6a75ea9 Show IP address when address has a label
introduced a way to show the IP address of an interface when a label is
associated to the IP.
When a label is associated to an IP, the structure returned by
getifaddrs() has the label concatenated to the interface name in the
.ifa_name field as in the following example:
    struct ifaddrs ifaddr = {
       .ifa_name = "eth0:mylabel",
    };
As a consequence, using a strict comparison between the interface name
and the .ifa_name field yields a falsy result. However, checking if the
.ifa_name starts with the interface name (e.g. eth0) does not work
either because other network interfaces can have a name which starts
with eth0.
This commit solves the issue by stripping out the optional label from
the .ifa_name field before making a strict comparison with the interface
name.
Fix #283
Signed-off-by: Olivier Gayot <olivier.gayot@sigexec.com> | 
|  | Signed-off-by: Olivier Gayot <olivier.gayot@sigexec.com> | 
|  | fix wrong memory-documentation | 
|  |  | 
|  | initial support of memory-usage for linux | 
|  | Fix MacOS build | 
|  |  | 
|  |  | 
|  |  | 
|  |  | 
|  |  | 
|  | Fix NULL value on OpenBSD when there is no acpitz0 | 
|  | Using %degrees on OpenBSD resulted in garbage values if sysctl doesn't
know about any cpu temperature sensors. | 
|  | Show IP address when address has a label | 
|  | If an address has been added with a label, ensure the correct address is
shown. | 
|  | Make iface_type() work on FreeBSD | 
|  |  | 
|  | man: explicitly use format_up/format_down in ethernet, wireless conf | 
|  | Remove overly aggressive #error | 
|  | OpenBSD: fix volume display on some hardware | 
|  | On some hardware the AUDIO_MIXER_READ ioctl requires the current number
of channels to be set, and the mute device found needs to be checked if
it belongs to the master output device. | 
|  |  | 
|  | Add check for interval value | 
|  |  | 
|  | Remove SLOC comment from man page | 
|  | This changed happened for the readme in
73620dc876d7f76b9a6771048c5ad0ade94e5bd7 | 
|  | `print_battery_info` computes `batt_info.percentage_remaining` by
dividing batt_info.remaining by `full`. If `full` is `0` then the
battery remaining will be reported as "inf".
Before this, it tries to set `full` to either the design capacity or to
the last known good charge. It determines if these values are available
by checking whether their fields in `batt_info` are non-negative. As it
initialized `batt_info` with values of `-1`, a non-negative value
implies that something has provided a value.
`slurp_all_batteries` and `add_battery_info` however initialize these
fields to zero, so if these functions are called then
`batt_info.full_design` will always be used.
This means that on systems that don't provide a value for design
capacity the percentage remaining will be reported as "inf", unless the
user has set `last_full_capacity` to `true` in their `i3status.conf`.
This patch changes `print_battery_info` to expect values for the battery
capacity to be strictly greater than zero. This seems reasonable as a
battery with a capacity of zero isn't useful.
An alternative solution would be to change `slurp_all_batteries` and
`add_battery_info` to initialize `batt_info` with `-1`, as
`print_battery_info` does. This is less appealing as `add_battery_info`
is accumulating the values, so using `-1` would introduce off-by-one
errors without additional code to avoid them. | 
|  | Get rid of the SLOC comment | 
|  |  | 
|  |  | 
|  |  | 
|  | Call tzset at each time print | 
|  |  | 
|  | Fixed minor typos | 
|  | "you can chose" -> "you can choose"
"You can either disable the default separator altogether setting it to the empty string." -> " You can also disable the default separator altogether by setting it to the empty string." | 
|  | Clearly indicate format_up and format_down are used for configuring ethernet
and wireless sections instead of format.
Signed-off-by: Tomas Krizek <tomas.krizek@mailbox.org> | 
|  |  | 
|  | Be more cautious about handling invalid battery measurements. | 
|  | Support any amount of available cores on testing machine. | 
|  |  | 
|  | Change-Id: I8c20606d386d713cac51b620d1fcdb479a3622fe | 
|  | Support any amount of available cores on testing machine. | 
|  | This was introduced in #236. It looks like Travis never ran on that PR?
Anyway it's blocking me submitting this now so I'm fixing it. | 
|  |  | 
|  |  | 
|  | Add check for virtual ethernet devices | 
|  | The Linux power supply class defines three entries to provide battery status.
One of them wasn't used: POWER_SUPPLY_CAPACITY.
https://www.kernel.org/doc/Documentation/power/power_supply_class.txt | 
|  | Added braces to the if-statement as requested. |