return msg
# pylint: disable=R0913
-def show_actions(series, why_selected, boards_selected, output_dir, options,
- board_warnings):
+def show_actions(series, why_selected, boards_selected, output_dir,
+ board_warnings, step, threads, jobs, verbose):
"""Display a list of actions that we would take, if not a dry run.
Args:
boards_selected: Dict of selected boards, key is target name,
value is Board object
output_dir (str): Output directory for builder
- options: Command line options object
board_warnings: List of warnings obtained from board selected
+ step (int): Step increment through commits
+ threads (int): Number of processor threads being used
+ jobs (int): Number of jobs to build at once
+ verbose (bool): True to indicate why each board was selected
"""
col = terminal.Color()
print('Dry run, so not doing much. But I would do this:')
commits = series.commits
else:
commits = None
- print(get_action_summary(False, commits, boards_selected,
- options.step, options.threads, options.jobs))
+ print(get_action_summary(False, commits, boards_selected, step, threads,
+ jobs))
print(f'Build directory: {output_dir}')
if commits:
- for upto in range(0, len(series.commits), options.step):
+ for upto in range(0, len(series.commits), step):
commit = series.commits[upto]
print(' ', col.build(col.YELLOW, commit.hash[:8], bright=False), end=' ')
print(commit.subject)
for arg in why_selected:
if arg != 'all':
print(arg, f': {len(why_selected[arg])} boards')
- if options.verbose:
+ if verbose:
print(f" {' '.join(why_selected[arg])}")
print('Total boards to build for each '
f"commit: {len(why_selected['all'])}\n")
# For a dry run, just show our actions as a sanity check
if options.dry_run:
- show_actions(series, why_selected, selected, output_dir, options,
- board_warnings)
+ show_actions(series, why_selected, selected, output_dir, board_warnings,
+ options.step, options.threads, options.jobs,
+ options.verbose)
return 0
adjust_cfg = cfgutil.convert_list_to_dict(options.adjust_cfg)