Improve script output formatting
This commit is contained in:
@@ -54,7 +54,7 @@ services = [
|
||||
name='github',
|
||||
src_config_path='examples/github-minimal.yml',
|
||||
dst_config_path='.github/workflows/example.yml',
|
||||
badge_md='',
|
||||
badge_md='[](https://github.com/joerick/cibuildwheel/actions)',
|
||||
),
|
||||
CIService(
|
||||
name='travis-ci',
|
||||
@@ -96,7 +96,7 @@ def run_example_ci_configs():
|
||||
|
||||
run(['git', 'add', example_project], check=True)
|
||||
run(['git', 'commit', '-m', textwrap.dedent(f'''
|
||||
Test example minimal configs.
|
||||
Test example minimal configs
|
||||
|
||||
Testing files: {[s.src_config_path for s in services]}
|
||||
Generated from branch: {previous_branch}
|
||||
@@ -106,17 +106,17 @@ def run_example_ci_configs():
|
||||
|
||||
print('---')
|
||||
print()
|
||||
print('**Examples test run**')
|
||||
print()
|
||||
print(f'Branch: [{branch_name}](https://github.com/joerick/cibuildwheel/tree/{branch_name})')
|
||||
print()
|
||||
print('| Service | Config | Status |')
|
||||
print('|---|---|---|')
|
||||
print('> **Examples test run**')
|
||||
print('> ')
|
||||
print(f'> Branch: [{branch_name}](https://github.com/joerick/cibuildwheel/tree/{branch_name})')
|
||||
print('> ')
|
||||
print('> | Service | Config | Status |')
|
||||
print('> |---|---|---|')
|
||||
for service in services:
|
||||
badge = service.badge_md.format(branch=branch_name, branch_escaped=quote(branch_name, safe=''))
|
||||
print(f'| {service.name} | {service.src_config_path} | {badge} |')
|
||||
print()
|
||||
print('Generated by `bin/run_example_ci_config.py`')
|
||||
print(f'> | {service.name} | `{service.src_config_path}` | {badge} |')
|
||||
print('> ')
|
||||
print('> Generated by `bin/run_example_ci_config.py`')
|
||||
print()
|
||||
print('---')
|
||||
finally:
|
||||
|
||||
Reference in New Issue
Block a user