Closes #1
This commit is contained in:
2022-11-05 08:42:16 -07:00
parent b65616d1cc
commit c414473b4c
2 changed files with 13 additions and 2 deletions

View File

@ -2,14 +2,18 @@ local util = {}
util.mpc_command = function(command, callback)
awful.spawn.easy_async(
"mpc --host " .. config.mpc.host .. " " .. command,
"mpc --host " .. config.mpc.host .. " "
.. "--port " .. config.mpc.port .. " "
.. command,
callback
)
end
util.mpc_watch = function(command, timeout, callback, widget)
awful.widget.watch(
"mpc --host " .. config.mpc.host .. " " .. command,
"mpc --host " .. config.mpc.host .. " "
.. "--port " .. config.mpc.port .. " "
.. command,
timeout,
callback,
widget