Skip to content

Instantly share code, notes, and snippets.

@Lapin0t
Last active August 18, 2017 19:11
Show Gist options
  • Save Lapin0t/8dc59871072539411a46979929ecea58 to your computer and use it in GitHub Desktop.
Save Lapin0t/8dc59871072539411a46979929ecea58 to your computer and use it in GitHub Desktop.
whipper CLI mockup
related ideas:
- the code should only query a config which would has been populated by
command-line args or by some config file
- sync the config and the CLI so that everything can be set from CLI or in
config file with somewhat the same names
---
$ whipper --help
whipper vX.X
usage: whipper <command> [<args>]
Whipper is blabla description
optional arguments:
-h, --help show this help message and exit
-C, --config config file to use
-R, --record record API requests for playback << is this needed?
commands:
rip rip the inserted CD
info retrieve info about the inserted CD
drives list attached drives
analyze analyze drive read offset and caching behavior
retag retag image files
verify verify image
---
$ whipper rip --help
usage: whipper rip [<args>] [OUTPUT]
Rip the inserted CD. blabla
positional arguments:
OUTPUT
optional arguments:
-h, --help
-l, --logger
-d, --drive
-r, --release-id
-w, --working-directory
-t, --toc-pickle << do we need this?
-c, --country
-a, --auto-tag << negation of --prompt (because of true default), better name?
-o, --read-offset
-x, --force-overread
-e, --eject << eject if successful (or maybe default to true?)
--track-template << should this be config-only?
--disc-template << should this be config-only?
--no-unknown
--no-cdr
---
$ whipper info --help
usage: whipper info [<args>]
Retrieve information about the inserted CD.
optional arguments:
-h, --help
-t, --toc-pickle << do we need this?
-a, --auto-tag
-c, --country
-d, --drive
---
$ whipper drives --help
usage: whipper drives [--help]
List available CD-DA drives.
optional arguments:
-h, --help
---
$ whipper analyze --help
usage: whipper analyze [<args>]
Analyze drive read offset and caching behavior.
optional arguments:
-h, --help
-d, --drive
-f, --offsets
---
$ whipper retag --help
usage: whipper retag [<args>] CUEFILE
positional arguments:
CUEFILE
optional arguments:
-h, --help
-r, --release-id
-c, --country
-a, --auto-tag
---
$ whipper verify --help
usage: whipper verify CUEFILE [CUEFILE [...]]
positional arguments:
CUEFILE
optional arguments:
-h, --help
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment