]> git.sur5r.net Git - i3/i3status/log
i3/i3status
5 years agoAdded %interface to the ethernet options 302/head
Max Christian Pohle [Fri, 24 Aug 2018 21:43:35 +0000 (23:43 +0200)]
Added %interface to the ethernet options

5 years agoMerge pull request #301 from wmarvel/issue300
Ingo Bürk [Wed, 1 Aug 2018 11:49:27 +0000 (13:49 +0200)]
Merge pull request #301 from wmarvel/issue300

Fix for issue 300: Correctly print usage for cpu 10

5 years agoFix for issue 300: Correctly print usage for cpu 10 301/head
= [Tue, 31 Jul 2018 05:27:13 +0000 (00:27 -0500)]
Fix for issue 300: Correctly print usage for cpu 10

5 years agoMerge pull request #296 from Stunkymonkey/include-order
Ingo Bürk [Mon, 16 Jul 2018 14:18:06 +0000 (16:18 +0200)]
Merge pull request #296 from Stunkymonkey/include-order

switch to clang 3.8 & ignore include sort order

5 years agoMerge pull request #299 from tuxillo/patch-2
Ingo Bürk [Mon, 16 Jul 2018 14:13:47 +0000 (16:13 +0200)]
Merge pull request #299 from tuxillo/patch-2

Detect interface type on DragonFly BSD

5 years agoDetect interface type on DragonFly BSD 299/head
Antonio Huete Jimenez [Sun, 15 Jul 2018 20:55:01 +0000 (20:55 +0000)]
Detect interface type on DragonFly BSD

5 years agoMerge pull request #298 from tuxillo/patch-1
Ingo Bürk [Sun, 15 Jul 2018 19:47:26 +0000 (21:47 +0200)]
Merge pull request #298 from tuxillo/patch-1

Do not use pulseaudio for DragonFly BSD

5 years agoDo not use pulseaudio for DragonFly BSD 298/head
Antonio Huete Jimenez [Sat, 14 Jul 2018 20:22:55 +0000 (20:22 +0000)]
Do not use pulseaudio for DragonFly BSD

5 years agoclang-format-3.8 fix travis error 296/head
Felix Buehler [Fri, 13 Jul 2018 14:28:22 +0000 (16:28 +0200)]
clang-format-3.8 fix travis error

5 years agoMerge pull request #297 from Stunkymonkey/percent-first
Ingo Bürk [Fri, 13 Jul 2018 13:17:51 +0000 (15:17 +0200)]
Merge pull request #297 from Stunkymonkey/percent-first

able to print percentage

5 years agofix clang errors
Felix Buehler [Sun, 8 Jul 2018 11:59:21 +0000 (13:59 +0200)]
fix clang errors

5 years agoable to print percentage 297/head
Felix Buehler [Sat, 2 Jun 2018 00:32:25 +0000 (02:32 +0200)]
able to print percentage

its now possible to have percentage before and after a variable. except
for the date. But percentage with dates does not make much sense to me, so
i skipped it.

5 years agoMerge pull request #256 from oyvinht/master
Ingo Bürk [Fri, 13 Jul 2018 10:31:04 +0000 (12:31 +0200)]
Merge pull request #256 from oyvinht/master

Read multiple batteries on DragonFly BSD.

5 years agoMerge pull request #295 from Stunkymonkey/fix-min_width-docs
Ingo Bürk [Fri, 13 Jul 2018 10:27:28 +0000 (12:27 +0200)]
Merge pull request #295 from Stunkymonkey/fix-min_width-docs

fix min_width doc

5 years agoswitch to clang 3.8 & ignore sort oder of includes
Felix Buehler [Sun, 8 Jul 2018 11:44:02 +0000 (13:44 +0200)]
switch to clang 3.8 & ignore sort oder of includes

5 years agofix min_width doc 295/head
Felix Buehler [Sat, 7 Jul 2018 20:57:39 +0000 (22:57 +0200)]
fix min_width doc

5 years agoMerge pull request #294 from Stunkymonkey/remove_memory_discussion
Ingo Bürk [Sat, 30 Jun 2018 04:52:58 +0000 (06:52 +0200)]
Merge pull request #294 from Stunkymonkey/remove_memory_discussion

forgot to remove memory discussion from man page (it is implemented)

5 years agoforgot to remove memory discussion from man page (it is implemented) 294/head
Felix Buehler [Fri, 29 Jun 2018 22:52:59 +0000 (00:52 +0200)]
forgot to remove memory discussion from man page (it is implemented)

5 years agoMerge pull request #292 from Stunkymonkey/format_quality
Ingo Bürk [Fri, 29 Jun 2018 21:10:53 +0000 (23:10 +0200)]
Merge pull request #292 from Stunkymonkey/format_quality

add format_quality option in wireless

5 years agoadd format_quality option in wireless 292/head
Felix Buehler [Thu, 28 Jun 2018 20:16:37 +0000 (22:16 +0200)]
add format_quality option in wireless

5 years agoMerge pull request #293 from Stunkymonkey/hide_seconds_battery
Ingo Bürk [Fri, 29 Jun 2018 20:49:52 +0000 (22:49 +0200)]
Merge pull request #293 from Stunkymonkey/hide_seconds_battery

hide seconds in battery by default

5 years agoMerge pull request #291 from duskCoder/cap_net_admin
Ingo Bürk [Fri, 29 Jun 2018 20:43:39 +0000 (22:43 +0200)]
Merge pull request #291 from duskCoder/cap_net_admin

Stop requiring CAP_NET_ADMIN

5 years agohide seconds in battery by default 293/head
Felix Buehler [Fri, 29 Jun 2018 11:35:20 +0000 (13:35 +0200)]
hide seconds in battery by default

5 years agoStop requiring CAP_NET_ADMIN 291/head
Olivier Gayot [Wed, 20 Jun 2018 16:09:41 +0000 (18:09 +0200)]
Stop requiring CAP_NET_ADMIN

Since the following commit in the Linux kernel tree

  0fdc100bdc4b ethtool: allow non-netadmin to query settings

it is no longer necessary to have the CAP_NET_ADMIN capability to query
a device speed using ioctl(..., SIOCETHTOOL) in conjonction with the
ETHTOOL_GSET ethtool command.

The mentioned commit landed first in the 2.6.37 version of the Kernel.
This version is no longer maintained nowdays.

Since it is not necessary anymore, it is strongly prefered from a
security standpoint to drop the CAP_NET_ADMIN capability from the
binary.

Signed-off-by: Olivier Gayot <olivier.gayot@sigexec.com>
5 years agoMerge pull request #290 from duskCoder/changes
Ingo Bürk [Fri, 22 Jun 2018 11:55:09 +0000 (13:55 +0200)]
Merge pull request #290 from duskCoder/changes

Fix potential issues & avoid unnecessary instructions

5 years agoPrevent potential crash if glob() fails 290/head
Olivier Gayot [Wed, 20 Jun 2018 11:41:59 +0000 (13:41 +0200)]
Prevent potential crash if glob() fails

Calling globfree(NULL) is undefined behaviour. In Linux (glibc), it
results in a segmentation fault.

It is also undefined behaviour to call globfree(&pglob) if a previous
call to glob(&pglob) returned an error.

Signed-off-by: Olivier Gayot <olivier.gayot@sigexec.com>
5 years agoFix potential memory leak on Linux
Olivier Gayot [Wed, 20 Jun 2018 09:58:10 +0000 (11:58 +0200)]
Fix potential memory leak on Linux

The function slurp_all_batteries(), on Linux, allocates memory
dynamically

Signed-off-by: Olivier Gayot <olivier.gayot@sigexec.com>
5 years agoFix invalid handling of glob() errors on Linux
Olivier Gayot [Wed, 20 Jun 2018 09:42:59 +0000 (11:42 +0200)]
Fix invalid handling of glob() errors on Linux

The manual of glob(3) says that the function returns 0 on successful
completion. Any other integer value should be considered an error, not
only negative integers.

In practice, *BSD systems use negative values but Linux uses positive
integers.

Signed-off-by: Olivier Gayot <olivier.gayot@sigexec.com>
5 years agoFix use of undefined macro __OpenBSD__
Olivier Gayot [Tue, 19 Jun 2018 17:25:15 +0000 (19:25 +0200)]
Fix use of undefined macro __OpenBSD__

Compiling on Linux with -Wundef produces the following warning:

  warning: "__OpenBSD__" is not defined, evaluates to 0 [-Wundef]

Signed-off-by: Olivier Gayot <olivier.gayot@sigexec.com>
5 years agoAvoid assigning a new value to a var before using the old value
Olivier Gayot [Wed, 13 Jun 2018 07:53:50 +0000 (09:53 +0200)]
Avoid assigning a new value to a var before using the old value

Signed-off-by: Olivier Gayot <olivier.gayot@sigexec.com>
5 years agoMake sure the arguments passed to printf/die(...) match the format
Olivier Gayot [Tue, 12 Jun 2018 07:41:44 +0000 (09:41 +0200)]
Make sure the arguments passed to printf/die(...) match the format

Signed-off-by: Olivier Gayot <olivier.gayot@sigexec.com>
5 years agoNo longer use a temporary buffer in the die() function
Olivier Gayot [Mon, 11 Jun 2018 22:52:29 +0000 (00:52 +0200)]
No longer use a temporary buffer in the die() function

Before the following change

  f947d0a Breaks configfiles! Major refactoring of i3status, see below

The die(fmt, ...) function was outputting the reason to the status bar
in addition to stderr. For this reason, it was meaningful to create a
temporary string according to the format string and then passing it
around to the different functions.

Nowadays, we only display the error message to stderr so calling
fprintf(stderr, ...) is much simpler.

Signed-off-by: Olivier Gayot <olivier.gayot@sigexec.com>
5 years agoMerge pull request #289 from bebehei/testsuite
Ingo Bürk [Wed, 20 Jun 2018 06:39:59 +0000 (08:39 +0200)]
Merge pull request #289 from bebehei/testsuite

Testsuite

5 years agoShow differing results, if testcase fails 289/head
Benedikt Heine [Tue, 19 Jun 2018 15:15:28 +0000 (17:15 +0200)]
Show differing results, if testcase fails

5 years agoRun all travis tests and expose the final result as exit code
Benedikt Heine [Tue, 19 Jun 2018 14:58:15 +0000 (16:58 +0200)]
Run all travis tests and expose the final result as exit code

5 years agoExpose the testsuite in the Makefile
Benedikt Heine [Tue, 19 Jun 2018 14:56:48 +0000 (16:56 +0200)]
Expose the testsuite in the Makefile

5 years agoFail the tests, if i3status actually crashes
Benedikt Heine [Tue, 19 Jun 2018 14:44:37 +0000 (16:44 +0200)]
Fail the tests, if i3status actually crashes

5 years agoMerge pull request #287 from eplanet/emeric/man_typo
Ingo Bürk [Sat, 16 Jun 2018 12:49:09 +0000 (14:49 +0200)]
Merge pull request #287 from eplanet/emeric/man_typo

Fix man typo

5 years agoFix man typo 287/head
eplanet [Thu, 14 Jun 2018 20:09:03 +0000 (22:09 +0200)]
Fix man typo

5 years agoMerge pull request #286 from duskCoder/#283
Ingo Bürk [Mon, 11 Jun 2018 20:18:53 +0000 (22:18 +0200)]
Merge pull request #286 from duskCoder/#283

Fix issue #283 (shown IP belonging to wrong network interface)

5 years agoFix shown IP address belonging to wrong interface 286/head
Olivier Gayot [Mon, 4 Jun 2018 17:59:15 +0000 (19:59 +0200)]
Fix shown IP address belonging to wrong 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>
5 years agoSimplify the algorithm used to determine the IP address
Olivier Gayot [Mon, 4 Jun 2018 17:59:09 +0000 (19:59 +0200)]
Simplify the algorithm used to determine the IP address

Signed-off-by: Olivier Gayot <olivier.gayot@sigexec.com>
5 years agoMerge pull request #282 from Stunkymonkey/mem-support
Ingo Bürk [Tue, 22 May 2018 04:57:45 +0000 (06:57 +0200)]
Merge pull request #282 from Stunkymonkey/mem-support

fix wrong memory-documentation

5 years agofix wrong memory-documentation 282/head
Felix Buehler [Tue, 22 May 2018 00:07:28 +0000 (02:07 +0200)]
fix wrong memory-documentation

5 years agoMerge pull request #270 from Stunkymonkey/mem-support
Ingo Bürk [Sat, 19 May 2018 20:08:42 +0000 (22:08 +0200)]
Merge pull request #270 from Stunkymonkey/mem-support

initial support of memory-usage for linux

5 years agoMerge pull request #281 from eplanet/fix_warnings
Orestis [Tue, 15 May 2018 11:46:06 +0000 (14:46 +0300)]
Merge pull request #281 from eplanet/fix_warnings

Fix MacOS build

5 years agoFix MacOS build 281/head
eplanet [Tue, 15 May 2018 11:34:36 +0000 (13:34 +0200)]
Fix MacOS build

5 years agorelease v2.12 2.12
Michael Stapelberg [Fri, 11 May 2018 09:06:00 +0000 (11:06 +0200)]
release v2.12

5 years agoSimplify the memory thresholds 270/head
Benedikt Heine [Mon, 16 Apr 2018 16:18:50 +0000 (18:18 +0200)]
Simplify the memory thresholds

5 years agoRename ram variables consistently
Benedikt Heine [Mon, 16 Apr 2018 13:41:13 +0000 (15:41 +0200)]
Rename ram variables consistently

6 years agoImplement support for memory-usage on Linux
Felix Buehler [Tue, 20 Mar 2018 14:35:28 +0000 (15:35 +0100)]
Implement support for memory-usage on Linux

6 years agoMerge pull request #275 from winks/patch-2
Ingo Bürk [Sun, 8 Apr 2018 13:53:19 +0000 (15:53 +0200)]
Merge pull request #275 from winks/patch-2

Fix NULL value on OpenBSD when there is no acpitz0

6 years agoFix NULL value on OpenBSD when there is no acpitz0 275/head
Florian Anderiasch [Fri, 6 Apr 2018 17:54:12 +0000 (19:54 +0200)]
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.

6 years agoMerge pull request #213 from dlrobertson/addr_description
Ingo Bürk [Thu, 29 Mar 2018 10:50:56 +0000 (12:50 +0200)]
Merge pull request #213 from dlrobertson/addr_description

Show IP address when address has a label

6 years agoShow IP address when address has a label 213/head
Dan Robertson [Wed, 22 Mar 2017 00:39:49 +0000 (00:39 +0000)]
Show IP address when address has a label

If an address has been added with a label, ensure the correct address is
shown.

6 years agoRead multiple batteries on DragonFly BSD. 256/head
Øyvin Halfdan Thuv [Wed, 13 Dec 2017 12:46:50 +0000 (13:46 +0100)]
Read multiple batteries on DragonFly BSD.

Using ACPI to read individual battery information instead of just
accumulations from sysctl.

6 years agoMerge pull request #264 from foutaise/master
Ingo Bürk [Tue, 27 Mar 2018 07:27:43 +0000 (09:27 +0200)]
Merge pull request #264 from foutaise/master

Make iface_type() work on FreeBSD

6 years agoMerge branch 'master' into master 264/head
Ingo Bürk [Tue, 27 Mar 2018 07:26:55 +0000 (09:26 +0200)]
Merge branch 'master' into master

6 years agoMerge pull request #251 from tomaskrizek/man-eth-wireless-format
Ingo Bürk [Tue, 27 Mar 2018 07:10:51 +0000 (09:10 +0200)]
Merge pull request #251 from tomaskrizek/man-eth-wireless-format

man: explicitly use format_up/format_down in ethernet, wireless conf

6 years agoMerge pull request #243 from jasperla/fei_error
Ingo Bürk [Tue, 27 Mar 2018 07:07:53 +0000 (09:07 +0200)]
Merge pull request #243 from jasperla/fei_error

Remove overly aggressive #error

6 years agoMerge pull request #266 from moreais/master
Ingo Bürk [Mon, 12 Feb 2018 15:32:01 +0000 (16:32 +0100)]
Merge pull request #266 from moreais/master

OpenBSD: fix volume display on some hardware

6 years agoOpenBSD: fix volume display on some hardware 266/head
Carlin Bingham [Mon, 12 Feb 2018 13:12:04 +0000 (02:12 +1300)]
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.

6 years agoMake iface_type() work on FreeBSD
Gerome Fournier [Wed, 7 Feb 2018 10:26:34 +0000 (11:26 +0100)]
Make iface_type() work on FreeBSD

6 years agoMerge pull request #262 from foutaise/master
Ingo Bürk [Tue, 6 Feb 2018 11:56:53 +0000 (12:56 +0100)]
Merge pull request #262 from foutaise/master

Add check for interval value

6 years agoAdd check for interval value 262/head
foutaise [Tue, 6 Feb 2018 11:30:04 +0000 (12:30 +0100)]
Add check for interval value

6 years agoMerge pull request #261 from tylerbrazier/no-sloc
Ingo Bürk [Sat, 3 Feb 2018 08:36:36 +0000 (09:36 +0100)]
Merge pull request #261 from tylerbrazier/no-sloc

Remove SLOC comment from man page

6 years agoRemove SLOC comment from man page 261/head
Tyler Brazier [Fri, 2 Feb 2018 19:05:46 +0000 (13:05 -0600)]
Remove SLOC comment from man page

This changed happened for the readme in
73620dc876d7f76b9a6771048c5ad0ade94e5bd7

6 years agoTreat zero battery capacity as "not available" (#259)
johcgt [Sun, 28 Jan 2018 14:37:51 +0000 (14:37 +0000)]
Treat zero battery capacity as "not available" (#259)

`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.

6 years agoMerge pull request #255 from eplanet/update_readme
Ingo Bürk [Tue, 12 Dec 2017 17:07:19 +0000 (18:07 +0100)]
Merge pull request #255 from eplanet/update_readme

Get rid of the SLOC comment

6 years agoGet rid of the SLOC comment 255/head
eplanet [Mon, 11 Dec 2017 21:50:16 +0000 (22:50 +0100)]
Get rid of the SLOC comment

6 years agoUpdate comment as in #247 (#254)
Emeric Planet [Mon, 11 Dec 2017 11:16:00 +0000 (12:16 +0100)]
Update comment as in #247 (#254)

6 years agoAdd IPv6 address when IPv4 isn't available (#247)
Emeric Planet [Mon, 11 Dec 2017 10:38:31 +0000 (11:38 +0100)]
Add IPv6 address when IPv4 isn't available (#247)

6 years agoMerge pull request #253 from eplanet/always_reload_tz
Ingo Bürk [Sat, 9 Dec 2017 15:17:42 +0000 (16:17 +0100)]
Merge pull request #253 from eplanet/always_reload_tz

Call tzset at each time print

6 years agoCall tzset at each time print 253/head
eplanet [Sat, 9 Dec 2017 14:48:18 +0000 (15:48 +0100)]
Call tzset at each time print

6 years agoMerge pull request #252 from GuyOfThePery/patch-1
Ingo Bürk [Sat, 9 Dec 2017 12:36:27 +0000 (13:36 +0100)]
Merge pull request #252 from GuyOfThePery/patch-1

Fixed minor typos

6 years agoFixed minor typos 252/head
GuyOfThePery [Sat, 9 Dec 2017 11:24:11 +0000 (13:24 +0200)]
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."

6 years agoman: explicitly use format_up/format_down in ethernet, wireless conf 251/head
Tomas Krizek [Sun, 3 Dec 2017 13:46:54 +0000 (14:46 +0100)]
man: explicitly use format_up/format_down in ethernet, wireless conf

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>
6 years agoAdd network test cases (#246)
Emeric Planet [Mon, 20 Nov 2017 18:51:48 +0000 (19:51 +0100)]
Add network test cases (#246)

6 years agoMerge pull request #237 from kousu/215-battery
Michael Stapelberg [Fri, 6 Oct 2017 05:53:58 +0000 (22:53 -0700)]
Merge pull request #237 from kousu/215-battery

Be more cautious about handling invalid battery measurements.

6 years agoFix CPU unit tests (#239) 237/head
Emeric Planet [Tue, 29 Aug 2017 17:01:30 +0000 (19:01 +0200)]
Fix CPU unit tests (#239)

Support any amount of available cores on testing machine.

6 years agoMakefile: make PKG_CONFIG overridable (patch by Helmut Grohne)
Michael Stapelberg [Mon, 18 Sep 2017 06:30:48 +0000 (08:30 +0200)]
Makefile: make PKG_CONFIG overridable (patch by Helmut Grohne)

6 years agoRemove overly aggressive #error 243/head
Jasper Lievisse Adriaanse [Mon, 4 Sep 2017 11:24:54 +0000 (13:24 +0200)]
Remove overly aggressive #error

Change-Id: I8c20606d386d713cac51b620d1fcdb479a3622fe

6 years agoFix CPU unit tests (#239)
Emeric Planet [Tue, 29 Aug 2017 17:01:30 +0000 (19:01 +0200)]
Fix CPU unit tests (#239)

Support any amount of available cores on testing machine.

6 years agoRepair test case.
kousu [Thu, 24 Aug 2017 21:57:16 +0000 (17:57 -0400)]
Repair test case.

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.

6 years agoBe more cautious about handling invalid battery measurements.
kousu [Thu, 24 Aug 2017 08:11:18 +0000 (04:11 -0400)]
Be more cautious about handling invalid battery measurements.

6 years agoUse local timezone for battery %emptytime (#236)
Emeric Planet [Sat, 19 Aug 2017 12:56:30 +0000 (14:56 +0200)]
Use local timezone for battery %emptytime (#236)

7 years agoMerge pull request #219 from flammi/master
Ingo Bürk [Sun, 16 Apr 2017 05:43:30 +0000 (07:43 +0200)]
Merge pull request #219 from flammi/master

Add check for virtual ethernet devices

7 years agoAdd battery capacity parsing (#216)
Emeric Planet [Thu, 13 Apr 2017 19:46:21 +0000 (21:46 +0200)]
Add battery capacity parsing (#216)

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

7 years agoAdded braces 219/head
Fabian Franzen [Thu, 13 Apr 2017 10:51:29 +0000 (12:51 +0200)]
Added braces

Added braces to the if-statement as requested.

7 years agoFix memory leak/Use BEGINS_WITH macro
Fabian Franzen [Wed, 12 Apr 2017 11:11:34 +0000 (13:11 +0200)]
Fix memory leak/Use BEGINS_WITH macro

The orignal proposed code had a memory leak when returning true.
Furthermore I included the handy BEGINS_WITH macro of i3 which makes the
code (IMHO) a lot more readable.

7 years agoAdd check for virtual ethernet devices
Fabian Franzen [Wed, 12 Apr 2017 01:30:28 +0000 (03:30 +0200)]
Add check for virtual ethernet devices

The _first_ option for ethernet devices now uses the link in sysfs to determine
if it's a real device or just a virtual one (i.e veth** devices created by docker).

7 years agoMultiple CPU support for cpu_usage (#209)
eplanet [Sun, 26 Mar 2017 10:54:07 +0000 (12:54 +0200)]
Multiple CPU support for cpu_usage (#209)

This change addresses the issue #199 asking for multiple CPU support. It
takes an arbitrary CPU number and outputs its usage using the same
arithmetics as for CPU aggregation. It currently doesn't support
FreeBSD.

7 years agoMerge pull request #211 from ixjlyons/issue210
Ingo Bürk [Thu, 16 Mar 2017 13:27:21 +0000 (14:27 +0100)]
Merge pull request #211 from ixjlyons/issue210

disk: don't remove trailing slash if path is a single character

7 years agodisk: don't remove trailing slash if path is a single character 211/head
Kenneth Lyons [Fri, 10 Mar 2017 19:24:56 +0000 (11:24 -0800)]
disk: don't remove trailing slash if path is a single character

7 years agoMerge pull request #208 from stapelberg/warning
Ingo Bürk [Wed, 8 Mar 2017 21:26:33 +0000 (22:26 +0100)]
Merge pull request #208 from stapelberg/warning

remove useless checks (we use char, not unsigned char)

7 years agoMerge pull request #207 from stapelberg/disk_info
Ingo Bürk [Wed, 8 Mar 2017 21:25:51 +0000 (22:25 +0100)]
Merge pull request #207 from stapelberg/disk_info

disk: sanitize trailing slashes

7 years agoremove useless checks (we use char, not unsigned char) 208/head
Michael Stapelberg [Wed, 8 Mar 2017 18:24:09 +0000 (19:24 +0100)]
remove useless checks (we use char, not unsigned char)

fixes compilation warnings

7 years agodisk: sanitize trailing slashes 207/head
Michael Stapelberg [Wed, 8 Mar 2017 18:19:03 +0000 (19:19 +0100)]
disk: sanitize trailing slashes

fixes #200

7 years agoMerge pull request #202 from jasperla/openbsd_fdleak
Ingo Bürk [Tue, 7 Feb 2017 19:47:06 +0000 (20:47 +0100)]
Merge pull request #202 from jasperla/openbsd_fdleak

Plug an fd leak in the OpenBSD-specific code for _first_

7 years agoMerge pull request #201 from jasperla/openbsd_bat_info
Ingo Bürk [Tue, 7 Feb 2017 19:45:36 +0000 (20:45 +0100)]
Merge pull request #201 from jasperla/openbsd_bat_info

Suppress printing :00 seconds of remaining battery lifetime