checkrestart: Improve readability of the DEBUG output when running commands
Add a space between Running: and the command.
Print the command with spaces instead of Python syntax.
Paul Wise
7 years ago
174 | 174 | |
175 | 175 | dpkgQuery = ["dpkg-query", "--search"] + list(programs.keys()) |
176 | 176 | if verbose: |
177 | print("[DEBUG] Running:%s" % dpkgQuery) | |
177 | print("[DEBUG] Running: %s" % ' '.join(dpkgQuery)) | |
178 | 178 | dpkgProc = subprocess.Popen(dpkgQuery, shell=False, stdout=subprocess.PIPE, stderr=subprocess.PIPE, |
179 | 179 | env = lc_all_c_env) |
180 | 180 | while True: |
236 | 236 | for package in list(packages.values()): |
237 | 237 | dpkgQuery = ["dpkg-query", "--listfiles", package.name] |
238 | 238 | if verbose: |
239 | print("[DEBUG] Running:%s" % dpkgQuery) | |
239 | print("[DEBUG] Running: %s" % ' '.join(dpkgQuery)) | |
240 | 240 | dpkgProc = subprocess.Popen(dpkgQuery, stdout=subprocess.PIPE, stderr=subprocess.STDOUT, |
241 | 241 | env = lc_all_c_env) |
242 | 242 | while True: |
426 | 426 | # If it exists, run dpkg-query |
427 | 427 | dpkgQuery = ["dpkg-query", "--search", f ] |
428 | 428 | if verbose: |
429 | print("[DEBUG] Running:%s" % dpkgQuery) | |
429 | print("[DEBUG] Running: %s" % ' '.join(dpkgQuery)) | |
430 | 430 | dpkgProc = subprocess.Popen(dpkgQuery, stdout=subprocess.PIPE, stderr=subprocess.STDOUT, |
431 | 431 | env = lc_all_c_env, close_fds=True) |
432 | 432 | dpkgProc.wait() |
433 | 433 | if verbose: |
434 | print("[DEBUG] Running:%s" % dpkgQuery) | |
434 | print("[DEBUG] Running: %s" % ' '.join(dpkgQuery)) | |
435 | 435 | for line in dpkgProc.stdout.readlines(): |
436 | 436 | line = line.strip() |
437 | 437 | if line.find('no path found matching pattern ' + f) > 0: |