bento
bento copied to clipboard
Make `bento check` paging behavior configurable in global config
Is your feature request related to a problem? Please describe. I would like to be able to dump all the results to the console, even if there are more than can fit on a single page. Otherwise, my terminal gets taken hostage, and if I leave the result viewer, I can't scroll up and review the result checks without re-executing bento check (annoying if it takes a few seconds to generate the results each time).
(Maybe this is currently possible? If so, just let me know and feel free to close the issue.)
Describe the solution you'd like I understand the current approach may be preferable in cases where the output is huge and you don't want to obliterate a new user's terminal history. But it would be nice if there was a way to manually override this.
I would be fine if this required passing a command line argument; I typically run commands like this via a Makefile so I don't mind if it takes extra arguments since I wouldn't typically typing them anyway. I just want the ability to prevent it from going to the scrollable viewer.
@dmontagu Thank you for the feedback, as always. Does the following command solve your issue?
$ bento check --no-pager
@nbrahms Is there an environment variable or setting to change this default for our users?
Yes! Thanks!
I noticed this is documented in the result of bento check --help
. I didn't realize that was an option -- might be nice to add a message indicating that you can get help for individual commands to the overall help.
For example, here's the help output by openapi-generator
:
❯ openapi-generator help
usage: openapi-generator-cli <command> [<args>]
The most commonly used openapi-generator-cli commands are:
config-help Config help for chosen lang
generate Generate code with the specified generator.
help Display help information
list Lists the available generators
meta MetaGenerator. Generator for creating a new template set and configuration for Codegen. The output will be based on the language you specify, and includes default templates to include.
validate Validate specification
version Show version information
See 'openapi-generator-cli help <command>' for more information on a specific
command.
Docker's help also ends with something similar:
❯ docker --help
Usage: docker [OPTIONS] COMMAND
A self-sufficient runtime for containers
...
... millions of commands
...
Run 'docker COMMAND --help' for more information on a command.
@dmontagu Good point. I'll rewrite the title of this request.
@dlukeomalley ... I'm a big fan of a config setting (in global user config)?
On Wed, Nov 6, 2019 at 1:39 PM dlukeomalley [email protected] wrote:
@dmontagu https://github.com/dmontagu Thank you for the feedback, as always. Does the following command solve your issue?
$ bento check --no-pager
@nbrahms https://github.com/nbrahms Is there an environment variable or setting to change this default for our users?
— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/returntocorp/bento/issues/153?email_source=notifications&email_token=AATACB2JLZMHSKQBPO5HEGLQSM2SRA5CNFSM4JJ5JKR2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEDICPHI#issuecomment-550512541, or unsubscribe https://github.com/notifications/unsubscribe-auth/AATACB4AIRAJNWCXMIC5E6TQSM2SRANCNFSM4JJ5JKRQ .
@nbrahms Going to change the title back. I think @dmontagu's --help
point is a good one, but isn't the core of the issue (I've opened a seperate issue to address that, see #166).
Let's continue to use this ticket to discuss the default paging behavior, I've only heard people be confused by it so far. Think it's selection bias?
@nbrahms Updating the title again. I'm comfortable with the default behavior, and like your suggestion that this is globally configurable.