Proposals and ideas to modernize the CLI of easybuild to improve usability
From various discussion the 2 main points that came up are:
-
UI/UX: Improve the CLI by using more modern CLI packages for python such as Click or Typer
A PoC for this is already present in
Where the options of the existing argparse based CLI are extracted and used to generate a new click CLI with the only purpose of providing improved UI, both in help/wrong_option and for tracebacks, with rich + rich_click and automatic tab completion for bash, zsh and fish coming from click
-
CLI with sub-commands: re-design the existing CLI to be more modular making use of sub-commands
From my side i think Click would be a better choice w.r.t Typer:
- More established package with better ecosystem
- Allow more powerful customization (would probably also be possible in
Typer but using click)
- EG, not sure it Typer has its own way to implement/use contexts which i think will be required
- Stylistically, i think using decorators to build the CLI is more readable than jamming the info into annotated typehints, but that might be my inexperience with Typer
Proposals and ideas to modernize the CLI of easybuild to improve usability
From various discussion the 2 main points that came up are:
UI/UX: Improve the CLI by using more modern CLI packages for python such as Click or Typer
A PoC for this is already present in
click#4961Where the options of the existing
argparsebased CLI are extracted and used to generate a newclickCLI with the only purpose of providing improved UI, both in help/wrong_option and for tracebacks, withrich+rich_clickand automatic tab completion forbash,zshandfishcoming from clickCLI with sub-commands: re-design the existing CLI to be more modular making use of sub-commands
click: develop...Crivella:easybuild-framework:cli2From my side i think
Clickwould be a better choice w.r.tTyper:Typerbut usingclick)