From d31f2ce0bec276d54c2a2cfe70c2764aee4503d8 Mon Sep 17 00:00:00 2001 From: Michael Stapelberg Date: Thu, 1 Apr 2010 20:34:03 +0200 Subject: [PATCH] install i3status with cap_net_admin capability, document it --- Makefile | 2 ++ man/i3status.man | 5 +++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/Makefile b/Makefile index e84d0cd..883bcdd 100644 --- a/Makefile +++ b/Makefile @@ -53,6 +53,8 @@ install: install -m 755 -d $(DESTDIR)/etc install -m 755 -d $(DESTDIR)/usr/share/man/man1 install -m 755 i3status $(DESTDIR)/usr/bin/i3status + # Allow network configuration for getting the link speed + which setcap && setcap cap_net_admin=ep $(DESTDIR)/usr/bin/i3status install -m 644 i3status.conf $(DESTDIR)/etc/i3status.conf install -m 644 man/i3status.1 $(DESTDIR)/usr/share/man/man1 diff --git a/man/i3status.man b/man/i3status.man index a747c73..74493b9 100644 --- a/man/i3status.man +++ b/man/i3status.man @@ -62,7 +62,7 @@ wireless wlan0 { } ethernet eth0 { - # if you use %speed, i3status requires root privileges + # if you use %speed, i3status requires the cap_net_admin capability format = "E: %ip (%speed)" } @@ -150,7 +150,8 @@ connected. === Ethernet Gets the IP address and (if possible) the link speed of the given ethernet -interface. Getting the link speed requires root privileges. +interface. Getting the link speed requires the cap_net_admin capability. Set +it using +setcap cap_net_admin=ep $(which i3status)+. *Example order*: +ethernet eth0+ -- 2.39.5