diff --git a/base.py b/base.py index 37a6430..9986ddb 100644 --- a/base.py +++ b/base.py @@ -146,11 +146,14 @@ class ServiceManager: nr = section.get(self.group) if nr is not None: nr = '%02d' % int(nr) - self.commands[ins] = command.replace('~', expanduser('~')) services = self.get_services(section) env = {k: get_subs(section, k, ins, nr) for k in section if k.isupper()} result[ins] = services self.env[ins] = env + cmd = command.replace('~', expanduser('~')) + if cmd.startswith('PY '): + cmd = env.get('PY', 'python3') + cmd[2:] + self.commands[ins] = cmd self.info = result #def get_cmdpats(self, groups):