From 6ee5dd3866ae0c3bdee4d4151fc48f8f8df1ad7d Mon Sep 17 00:00:00 2001 From: Matt Wilson Date: Tue, 28 Jul 2026 13:44:13 +1000 Subject: [PATCH] chore: markdown consistencies --- README.md | 14 +++---- examples/duplicate_aliases.md | 28 ++++++------- examples/flag_and_option_specifications.md | 46 +++++++++++----------- examples/multiple_options.md | 2 +- examples/sections.md | 38 +++++++++--------- examples/show_usage_and_version.md | 26 ++++++------ examples/typed_options.md | 26 ++++++------ 7 files changed, 90 insertions(+), 90 deletions(-) diff --git a/README.md b/README.md index f55e743..2105de1 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,5 @@ # CLASP.Python -**C**ommand-**L**ine **A**rgument **S**orting and **P**arsing for Python +**C**ommand-**L**ine **A**rgument **S**orting and **P**arsing, for Python ![Language](https://img.shields.io/badge/Python-3776AB?style=flat&logo=python&logoColor=white) [![License](https://img.shields.io/badge/License-BSD_3--Clause-blue.svg)](https://opensource.org/licenses/BSD-3-Clause) @@ -17,11 +17,11 @@ - [Components](#components) - [Examples](#examples) - [Project Information](#project-information) - - [Where to get help](#where-to-get-help) - - [Contribution guidelines](#contribution-guidelines) - - [Dependencies](#dependencies) - - [Related projects](#related-projects) - - [License](#license) + - [Where to get help](#where-to-get-help) + - [Contribution guidelines](#contribution-guidelines) + - [Dependencies](#dependencies) + - [Related projects](#related-projects) + - [License](#license) ## Introduction @@ -37,7 +37,7 @@ Python version. Install via **pip** or **pip3**, as in: ``` -$ pip3 install pyclasp +pip3 install pyclasp ``` Use via **import**: diff --git a/examples/duplicate_aliases.md b/examples/duplicate_aliases.md index 46e3097..d94404d 100644 --- a/examples/duplicate_aliases.md +++ b/examples/duplicate_aliases.md @@ -50,7 +50,7 @@ else: If executed with the arguments ``` -$ python examples/multiple_options.py --help +python examples/multiple_options.py --help ``` it gives the following output on the standard output stream: @@ -60,23 +60,23 @@ USAGE: duplicate_aliases.py [ ... flags and options ... ] flags/options: - -c - --compile - None + -c + --compile + None - -d - --debug - None + -d + --debug + None - -c - --execute - None + -c + --execute + None - --help - Shows usage and terminates + --help + Shows usage and terminates - --version - Shows version and terminates + --version + Shows version and terminates ``` and it gives the following output on the standard error stream: diff --git a/examples/flag_and_option_specifications.md b/examples/flag_and_option_specifications.md index 437fe6f..bd62916 100644 --- a/examples/flag_and_option_specifications.md +++ b/examples/flag_and_option_specifications.md @@ -87,13 +87,13 @@ if (unused): If executed with no arguments ``` - python examples/flag_and_option_specifications.py +python3 examples/flag_and_option_specifications.py ``` or (in a Unix shell): ``` - ./examples/flag_and_option_specifications.py + ./examples/flag_and_option_specifications.py ``` it gives the output: @@ -106,7 +106,7 @@ it gives the output: If executed with the arguments ``` - python examples/flag_and_option_specifications.py --help +python examples/flag_and_option_specifications.py --help ``` it gives the output: @@ -120,25 +120,25 @@ USAGE: flag_and_option_specifications.py [ ... flags and options ... ] flags/options: - -d - --debug - runs in Debug mode + -d + --debug + runs in Debug mode - -c --verbosity=chatty - -v - --verbosity= - specifies the verbosity - where one of: - terse - quiet - silent - chatty + -c --verbosity=chatty + -v + --verbosity= + specifies the verbosity + where one of: + terse + quiet + silent + chatty - --help - Shows usage and terminates + --help + Shows usage and terminates - --version - Shows version and terminates + --version + Shows version and terminates ``` ### Specify flags and options in long-form @@ -146,7 +146,7 @@ flags/options: If executed with the arguments ``` - python examples/flag_and_option_specifications.py --debug --verbosity=silent +python examples/flag_and_option_specifications.py --debug --verbosity=silent ``` it gives the output: @@ -161,7 +161,7 @@ Debug mode is specified If executed with the arguments ``` - python examples/flag_and_option_specifications.py -v silent -d +python3 examples/flag_and_option_specifications.py -v silent -d ``` it gives the (same) output: @@ -176,7 +176,7 @@ Debug mode is specified If executed with the arguments ``` - python examples/flag_and_option_specifications.py -c -d +python3 examples/flag_and_option_specifications.py -c -d ``` it gives the output: @@ -191,7 +191,7 @@ Debug mode is specified If executed with the arguments ``` - python examples/flag_and_option_specifications.py -dc +python3 examples/flag_and_option_specifications.py -dc ``` it gives the (same) output: diff --git a/examples/multiple_options.md b/examples/multiple_options.md index 2f3e51c..cda9e6c 100644 --- a/examples/multiple_options.md +++ b/examples/multiple_options.md @@ -86,7 +86,7 @@ if (unused): If executed with the arguments ``` - python examples/multiple_options.py -z -z -e cpp -e cxx -e cxx -z +python3 examples/multiple_options.py -z -z -e cpp -e cxx -e cxx -z ``` it gives the output: diff --git a/examples/sections.md b/examples/sections.md index 25637bd..dbd9f4f 100644 --- a/examples/sections.md +++ b/examples/sections.md @@ -83,13 +83,13 @@ sys.stdout.write("no flags specified\n"); If executed with no arguments ``` - python examples/sections.py +python3 examples/sections.py ``` or (in a Unix shell): ``` - ./examples/sections.py +./examples/sections.py ``` it gives the output: @@ -103,7 +103,7 @@ no flags specified If executed with the arguments ``` - python examples/sections.py --help +python3 examples/sections.py --help ``` it gives the output: @@ -117,24 +117,24 @@ USAGE: sections.py [ ... flags and options ... ] flags/options: - Behaviour: + Behaviour: - -v - --verbosity= - specifies the verbosity - where one of: - terse - quiet - silent - chatty + -v + --verbosity= + specifies the verbosity + where one of: + terse + quiet + silent + chatty - Standard: + Standard: - --help - Shows usage and terminates + --help + Shows usage and terminates - --version - Shows version and terminates + --version + Shows version and terminates ``` ### Show version @@ -142,7 +142,7 @@ flags/options: If executed with the arguments ``` - python examples/sections.py --version +python3 examples/sections.py --version ``` it gives the output: @@ -156,7 +156,7 @@ sections.py 0.0.1 If executed with the arguments ``` - python examples/sections.py --unknown=value +python3 examples/sections.py --unknown=value ``` it gives the output (on the standard error stream): diff --git a/examples/show_usage_and_version.md b/examples/show_usage_and_version.md index 6934a80..2fc5d2b 100644 --- a/examples/show_usage_and_version.md +++ b/examples/show_usage_and_version.md @@ -24,10 +24,10 @@ VERSION = [ 0, 0, 2 ] INFO_LINES = ( - 'CLASP.Python examples', - ':version:', - "Illustrates use of CLASP.Python's clasp.show_usage() and clasp.show_version() methods", - '', + "CLASP.Python examples", + ':version:', + "Illustrates use of CLASP.Python's clasp.show_usage() and clasp.show_version() methods", + '', ) # Specify specifications, parse, and checking standard flags @@ -70,13 +70,13 @@ sys.stdout.write("no flags specified\n"); If executed with no arguments ``` - python examples/show_usage_and_version.py +python3 examples/show_usage_and_version.py ``` or (in a Unix shell): ``` - ./examples/show_usage_and_version.py +./examples/show_usage_and_version.py ``` it gives the output: @@ -90,7 +90,7 @@ no flags specified If executed with the arguments ``` - python examples/show_usage_and_version.py --help +python3 examples/show_usage_and_version.py --help ``` it gives the output: @@ -104,11 +104,11 @@ USAGE: show_usage_and_version.py [ ... flags and options ... ] flags/options: - --help - Shows usage and terminates + --help + Shows usage and terminates - --version - Shows version and terminates + --version + Shows version and terminates ``` ### Show version @@ -116,7 +116,7 @@ flags/options: If executed with the arguments ``` - python examples/show_usage_and_version.py --version +python3 examples/show_usage_and_version.py --version ``` it gives the output: @@ -130,7 +130,7 @@ show_usage_and_version.py 0.0.2 If executed with the arguments ``` - python examples/show_usage_and_version.py --unknown=value +python3 examples/show_usage_and_version.py --unknown=value ``` it gives the output (on the standard error stream): diff --git a/examples/typed_options.md b/examples/typed_options.md index 2020a32..7b11e44 100644 --- a/examples/typed_options.md +++ b/examples/typed_options.md @@ -85,13 +85,13 @@ if (unused): If executed with no arguments ``` - python examples/typed_options.py +python3 examples/typed_options.py ``` or (in a Unix shell): ``` - ./examples/typed_options.py +./examples/typed_options.py ``` it gives the output: @@ -105,7 +105,7 @@ try specifying the '--length' option; use --help for usage If executed with the arguments ``` - python examples/typed_options.py --help +python3 examples/typed_options.py --help ``` it gives the output: @@ -119,15 +119,15 @@ USAGE: typed_options.py [ ... flags and options ... ] flags/options: - --help - Shows usage and terminates + --help + Shows usage and terminates - --version - Shows version and terminates + --version + Shows version and terminates - -l - --length= - specifies the length + -l + --length= + specifies the length ``` ### Specify a valid length @@ -135,7 +135,7 @@ flags/options: If executed with the arguments ``` - python examples/typed_options.py --length=10 +python3 examples/typed_options.py --length=10 ``` it gives the output: @@ -149,7 +149,7 @@ You specified length with the value: 10 (of type ). The string that If executed with the arguments ``` - python examples/typed_options.py --length= +python3 examples/typed_options.py --length= ``` it gives the output (on the standard error stream): @@ -165,7 +165,7 @@ with an exit code of 1 If executed with the arguments ``` - python examples/typed_options.py --length=abc +python3 examples/typed_options.py --length=abc ``` it gives the output (on the standard error stream):