From c414473b4cf74aff709dc019149b46344ea3fd03 Mon Sep 17 00:00:00 2001 From: Mark Date: Sat, 5 Nov 2022 08:42:16 -0700 Subject: [PATCH] Cleanup Closes #1 --- config-template.lua | 7 +++++++ modules/mpc/util.lua | 8 ++++++-- 2 files changed, 13 insertions(+), 2 deletions(-) diff --git a/config-template.lua b/config-template.lua index 016d9b6..a4abdf4 100755 --- a/config-template.lua +++ b/config-template.lua @@ -86,6 +86,11 @@ config.core = { continuous_tag_updates = true, + -- Format: + -- {command, icon-name} + -- + -- Icons files are in assets/apps, + -- Icon names are defined in assts/apps.lua. bar_shortcuts = { { "thunar", @@ -119,7 +124,9 @@ config.mpc = { enabled = true, -- If your MPC server has a password, do "passwd@host" + -- Default port is 6600, you probably won't need to change it. host = "localhost", + port = 6600, -- Fixed width of the mpc widget width = 250, diff --git a/modules/mpc/util.lua b/modules/mpc/util.lua index 6607ee8..5189a3a 100644 --- a/modules/mpc/util.lua +++ b/modules/mpc/util.lua @@ -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