From 3104af29d12392dcfaabc6d23ca96193c063f601 Mon Sep 17 00:00:00 2001 From: Kolan Sh Date: Sat, 29 Jul 2017 12:48:28 +0300 Subject: [PATCH] Do not start many alsamixer instances. --- rc.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rc.lua b/rc.lua index cf139f3..b428fd9 100644 --- a/rc.lua +++ b/rc.lua @@ -269,7 +269,7 @@ local volicon = wibox.widget.imagebox() volicon:set_image(beautiful.widget_vol) volicon:buttons( awful.util.table.join( - awful.button({ }, 1, function () awful.util.spawn("urxvt -e alsamixer --view=all") end), + awful.button({ }, 1, function () os.execute("pgrep alsamixer || urxvt -e alsamixer --view=all &") end), awful.button({ }, 4, function () os.execute("pgrep -x amixer || amixer set Master 1%+") end), awful.button({ }, 5, function () os.execute("pgrep -x amixer || amixer set Master 1%-") end) )