Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CLI usability improvements #20

Closed
wants to merge 13 commits into from
Closed

Conversation

bertfrees
Copy link
Member

@bertfrees bertfrees commented Nov 30, 2018

  • Better rendering of markdown (see blackterm)
  • Short vs. long descriptions of script inputs/options: get long descriptions with dp2 help COMMAND --verbose or dp2 help COMMAND OPTION
  • Show possible values of "choice" type of options
  • Show default values of options
  • Validate script options
  • Separate mandatory from non-mandatory options
  • ...

... until we have found a better solution for
#13.

subrepo:
  subdir:   "libs/go-subcommand"
  merged:   "4b3fc5651c"
upstream:
  origin:   "https://github.com/capitancambio/go-subcommand.git"
  branch:   "master"
  commit:   "4b3fc5651c"
git-subrepo:
  version:  "0.3.1"
  origin:   "https://github.com/ingydotnet/git-subrepo"
  commit:   "a7ee886"
... until we have found a better solution for
#13.

subrepo:
  subdir:   "libs/blackterm"
  merged:   "8446c9dfde"
upstream:
  origin:   "https://github.com/capitancambio/blackterm.git"
  branch:   "master"
  commit:   "8446c9dfde"
git-subrepo:
  version:  "0.3.1"
  origin:   "???"
  commit:   "???"
- Separate paragraphs with empty lines
- Align list items
- Support (fenced) code blocks
- Underline links (automatically makes them clickable in some terminal emulators)
- Change coloring of code spans
- Change coloring of (single, double and triple) emphasized text
See #18.

Also check that input files exist when in localfs mode.
and show the name of the data type for other options.

See #19
including the full descriptions of the options, the possible values,
and the default values.

To show the detailed help of a script:

    dp2 help COMMAND --verbose

To show the detailed help of a single option:

    dp2 help COMMAND OPTION
Copy link
Member

@rdeltour rdeltour left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

Note: I didn't review the details of the datatype validation code.

Do you intend to submit the improvements to go-subcommand and blackterm as PRs to the upstream projects?

@bertfrees
Copy link
Member Author

Do you intend to submit the improvements to go-subcommand and blackterm as PRs to the upstream projects?

Maybe. I kind of like including the dependencies in this project, because currently there is no proper way to declare the dependencies. pipeline-cli-go just downloads the latest master of its dependencies when building. This has two drawbacks:

  • You can't make a change in blackterm or go-subcommand and then test this change in pipeline-cli-go.
  • If the master branch of blackterm or go-subcommand is updated it may break pipeline-cli-go.

See also #13

@rdeltour
Copy link
Member

See also #13

Right yeah I had seen that.
If it works as is, and you feel it won't be a maintenance issue, then go for it by all means! An intermediary solution might be to fork the projects in daisy, so that at least we control breaking changes.

@bertfrees bertfrees added this to the v1.12.0 milestone Feb 5, 2019
bertfrees added a commit that referenced this pull request Feb 5, 2019
@bertfrees
Copy link
Member Author

Merged in 77ea314

@bertfrees bertfrees closed this Feb 5, 2019
@bertfrees bertfrees deleted the super/cli-improvements branch February 5, 2019 17:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants