fix(module/shell): expand user directory in command spec

Make sure that ~/ is expanded to the user's home directory in the
command specified for the shell module.

fixes #1002
This commit is contained in:
tobi-wan-kenobi 2023-10-26 08:54:13 +02:00
parent c4a3f488aa
commit 05622f985a

View file

@ -41,6 +41,7 @@ class Module(core.module.Module):
super().__init__(config, theme, core.widget.Widget(self.get_output))
self.__command = self.parameter("command", 'echo "no command configured"')
self.__command = os.path.expanduser(self.__command)
self.__async = util.format.asbool(self.parameter("async"))
if self.__async: