From 5eb8887e94952341d342bf3f7dfed9cd0edb5af9 Mon Sep 17 00:00:00 2001 From: clsr Date: Tue, 2 Nov 2021 17:27:19 +0000 Subject: Update to v1.5.0 --- PKGBUILD | 4 ++-- config.mk | 12 +++++++++--- 2 files changed, 11 insertions(+), 5 deletions(-) diff --git a/PKGBUILD b/PKGBUILD index f487cfc..07a4e05 100644 --- a/PKGBUILD +++ b/PKGBUILD @@ -1,7 +1,7 @@ # Maintainer: clsr pkgname=dwmclock -pkgver=1.4.0 +pkgver=1.5.0 pkgrel=1 pkgdesc="Time and battery charge display for dwm" arch=('x86_64') @@ -10,7 +10,7 @@ license=('custom:Public Domain') depends=('libx11') source=("https://git.clsr.net/util/dwmclock/snapshot/dwmclock-$pkgver.tar.gz" config.mk) -sha256sums=('95bdfc61593566f8f43452f2941a8fcdc3bbc3f6edd9007196b4b6d70adb3ae5' +sha256sums=('c410f6b0ff6fcb055d5e08289c84956cb901f703648565d2d8cd147c9db25223' 'SKIP') prepare() { diff --git a/config.mk b/config.mk index a9dfe19..cfd6766 100644 --- a/config.mk +++ b/config.mk @@ -3,19 +3,25 @@ # enable battery charge display CFLAGS += -DBATTERY +# the string to match when the battery is charging; comment out to disable charging detection +CFLAGS += -DCHARGING=\"Charging\\n\" + +# enable battery power usage display; needs POWER_NOW or CURRENT_NOW+VOLTAGE_NOW +#CFLAGS += -DPOWER + # set this to the correct path for your current system CFLAGS += -DENERGY_FULL=\"/sys/class/power_supply/BAT0/energy_full\" CFLAGS += -DENERGY_NOW=\"/sys/class/power_supply/BAT0/energy_now\" CFLAGS += -DSTATUS=\"/sys/class/power_supply/BAT0/status\" - -# the string to match when the battery is charging; comment out to disable charging detection -CFLAGS += -DCHARGING=\"Charging\\n\" +CFLAGS += -DPOWER_NOW=\"/sys/class/power_supply/BAT0/power_now\" # possible alternative on some systems #CFLAGS += -DENERGY_FULL=\"/sys/class/power_supply/BAT0/charge_full\" #CFLAGS += -DENERGY_NOW=\"/sys/class/power_supply/BAT0/charge_now\" #CFLAGS += -DSTATUS=\"/sys/class/power_supply/ADP1/online\" #CFLAGS += -DCHARGING=\"1\\n\" +#CFLAGS += -DCURRENT_NOW=\"/sys/class/power_supply/BAT0/current_now\" +#CFLAGS += -DVOLTAGE_NOW=\"/sys/class/power_supply/BAT0/voltage_now\" # every how many seconds to refresh the battery charge display CFLAGS += -DBAT_REFRESH_SECONDS=10 -- cgit