File tree Expand file tree Collapse file tree 3 files changed +21
-14
lines changed
Expand file tree Collapse file tree 3 files changed +21
-14
lines changed Original file line number Diff line number Diff line change 66 - id : check-merge-conflict
77 - id : check-toml
88 - id : end-of-file-fixer
9+ exclude : ^examples/transcripts/
910 - id : trailing-whitespace
11+ exclude : ^examples/transcripts/
1012
1113 - repo : https://github.com/astral-sh/ruff-pre-commit
1214 rev : " v0.14.13"
Original file line number Diff line number Diff line change 22"""A sample application for cmd2.
33
44Thanks to cmd2's built-in transcript testing capability, it also serves as a
5- test suite for transcript_example.py when used with the transcript_regex.txt transcript.
5+ test suite for transcript_example.py when used with the transcripts/ transcript_regex.txt transcript.
66
7- Running `python transcript_example.py -t transcript_regex.txt` will run all the commands in
7+ Running `python transcript_example.py -t transcripts/ transcript_regex.txt` will run all the commands in
88the transcript against transcript_example.py, verifying that the output produced matches
99the transcript.
1010"""
Original file line number Diff line number Diff line change 1- # Run this transcript with "python transcript_example.py -t transcript_regex.txt"
1+ # Run this transcript with "python transcript_example.py -t transcripts/ transcript_regex.txt"
22# Anything between two forward slashes, /, is interpreted as a regular expression (regex).
33# The regex for editor will match whatever program you use.
44# regexes on prompts just make the trailing space obvious
5- (Cmd) set
6- allow_style: '/(Terminal|Always|Never)/'
7- always_show_hint: False
8- debug: False
9- echo: False
10- editor: /.*?/
11- feedback_to_output: False
12- max_completion_items: 50
13- maxrepeats: 3
14- quiet: False
15- timing: False
5+ (Cmd) set
6+
7+ Name Value Description
8+ ───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────
9+ allow_style Terminal Allow ANSI text style sequences in output (valid values: Always, Never, Terminal)
10+ always_show_hint False Display tab completion hint even when completion suggestions print
11+ debug False Show full traceback on exception
12+ echo False Echo command issued into output
13+ editor /.*?/ Program used by 'edit'
14+ feedback_to_output False Include nonessentials in '|' and '>' results
15+ max_completion_items 50 Maximum number of CompletionItems to display during tab completion
16+ maxrepeats 3 max repetitions for speak command
17+ quiet False Don't print nonessential feedback
18+ scripts_add_to_history True Scripts and pyscripts add commands to history
19+ timing False Report execution times
20+
You can’t perform that action at this time.
0 commit comments