From 902eac89d2f5ede624d3af7225864c98f16aae67 Mon Sep 17 00:00:00 2001 From: Johannes Findeisen Date: Mon, 21 Oct 2013 02:53:58 +0200 Subject: [PATCH] new jobs list output with colors... yeah! --- linspector/frontends/lish.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/linspector/frontends/lish.py b/linspector/frontends/lish.py index c1e848f..2c83a14 100644 --- a/linspector/frontends/lish.py +++ b/linspector/frontends/lish.py @@ -169,7 +169,10 @@ class LishCommander(Exit): def do_jobs(self, text): if text == "list": for job in self.interface.jobs: - print job.pretty_string() + job_dict = self.interface.get_job_info_dict(job) + print GREEN + job_dict["Job"] + END + ": Hostgroup: " + job_dict["Hostgroup"] + \ + ": Host: " + job_dict["Host"] + ": Service: " + job_dict["Service"] + \ + ": Next run: " + job_dict["Next run"] + ": Enabled: " + job_dict["Enabled"] else: self.print_color(RED, "Invalid or missing parameter") self.help_jobs()