MCPcopy Create free account
hub / github.com/apache/solr / run_with_log_tail

Function run_with_log_tail

dev-tools/scripts/releaseWizard.py:1451–1466  ·  view source on GitHub ↗
(command, cwd, logfile=None, tail_lines=10, tee=False, live=False, shell=None, capture_output=False)

Source from the content-addressed store, hash-verified

1449
1450
1451def run_with_log_tail(command, cwd, logfile=None, tail_lines=10, tee=False, live=False, shell=None, capture_output=False):
1452 fh = sys.stdout
1453 if logfile:
1454 logdir = os.path.dirname(logfile)
1455 if not os.path.exists(logdir):
1456 os.makedirs(logdir)
1457 fh = open(logfile, 'w')
1458
1459 rc, captured_output = run_follow(command, cwd, fh=fh, tee=tee, live=live, shell=shell, capture_output=capture_output)
1460
1461 if logfile:
1462 fh.close()
1463 if not tee and tail_lines and tail_lines > 0:
1464 tail_file(logfile, tail_lines)
1465
1466 return rc, captured_output
1467
1468
1469def ask_yes_no(text):

Callers 1

runMethod · 0.85

Calls 4

run_followFunction · 0.85
tail_fileFunction · 0.85
existsMethod · 0.65
closeMethod · 0.65

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…