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

[resotocore] Help text is hard to read in Ubuntu Terminal #652

Closed
iainelder opened this issue Feb 12, 2022 · 4 comments · Fixed by #661
Closed

[resotocore] Help text is hard to read in Ubuntu Terminal #652

iainelder opened this issue Feb 12, 2022 · 4 comments · Fixed by #661
Labels
bug Something isn't working

Comments

@iainelder
Copy link

Description

In logs section I've pasted a text version of this screenshot.

The screenshot shows how the text renders with colors in Ubuntu Terminal.

The messages that start with hashes such as "# Show all available kinds." are almost impossible to read because the background is dark blue and the text is slightly darker blue.

image

Version

2.0.0a16

Environment

Ubuntu 20.04.3 LTS

Steps to Reproduce

  1. Start an Ubuntu Terminal session.
  2. Start resh using docker run.
  3. Run a help command such as help kind.
  4. Struggle to see the darker blue text on a dark blue background.

Logs

> help kind
kind: Retrieves information about the graph data kinds.                                                  

┌───────────────────────────────────────────────────────────────────────────────────────────────────────┐
│ kind [-p property_path] [name]                                                                        │
└───────────────────────────────────────────────────────────────────────────────────────────────────────┘

kind gives information about the available graph data kinds.                                             


                                                 Options                                                 

 • -p [Optional] property_path: lookup the kind for the defined property path. This will do a reverse    
   lookup and search all kinds for the specified property path.                                          


                                               Parameters                                                

 • name [Optional]: show available information about the kind with provided name.                        


                                                Examples                                                 

┌───────────────────────────────────────────────────────────────────────────────────────────────────────┐
│                                                                                                       │
│ # Show all available kinds.                                                                           │> kind                                                                                                │
│ access_key                                                                                            │
│ .                                                                                                     │
│ .                                                                                                     │
│ zone                                                                                                  │
│                                                                                                       │
│ # Show details about a specific kind.                                                                 │> kind graph_root                                                                                     │
│ name: graph_root                                                                                      │
│ bases:                                                                                                │
│ - graph_root                                                                                          │
│ properties:                                                                                           │
│ - description: The name of this node.                                                                 │
│   kind: string                                                                                        │
│   name: name                                                                                          │
│   required: false                                                                                     │
│ - description: All attached tags of this node.                                                        │
│   kind: dictionary[string, string]                                                                    │
│   name: tags                                                                                          │
│   required: false                                                                                     │
│                                                                                                       │
│ # Lookup the type of the given property path in the model.                                            │> kind -p reported.tags.owner                                                                         │
│ name: string                                                                                          │
│ runtime_kind: string                                                                                  │
└───────────────────────────────────────────────────────────────────────────────────────────────────────┘
>

Additional Context

No response

@iainelder iainelder added the bug Something isn't working label Feb 12, 2022
@lloesche lloesche changed the title Help text is hard to read in Ubuntu Terminal [resotocore] Help text is hard to read in Ubuntu Terminal Feb 13, 2022
@aquamatthias
Copy link
Member

@iainelder thanks for the report. We need to take a look into the color scheme.
As a workaround for the time being: you can start the resotoshell with the --no-color option.

@aquamatthias
Copy link
Member

I installed ubuntu and tried myself.

image

My terminal supports 256 colors. Above detail looks like this.

> echo $TERM
xterm-256color

Rendered with standard colors it looks like this:
image
which seems to be close to unreadable.

@iainelder What kind of terminal do you have (what is the TERM env set to?).

I would propose a change, which would look like this:

Standard:
image

256 Colors:
image

True Colors:
image

@iainelder
Copy link
Author

iainelder commented Feb 15, 2022

I should add that I'm running all the resh commands in the Docker container version resoto:2.0.0a16.

@iainelder What kind of terminal do you have (what is the TERM env set to?).

In my Ubuntu terminal:

$ echo $TERM
xterm-256color

In the resoto Docker container:

root@e909714648ba:/# echo $TERM
xterm

If in the container I set TERM=xterm-256color then the output is more readable.

image

Does the default setting in the container need to be changed?

@aquamatthias
Copy link
Member

Mmh typically the TERM variable should be set by the terminal emulator.
In case of docker, it will set the TERM variable to xterm (see environment-variables)
When exec into the docker container you can define env vars like: -eTERM - this will set the env var to the current value.

@lloesche any other idea?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants