cloudposse / geodesic

🚀 Geodesic is a DevOps Linux Toolbox in Docker
https://cloudposse.com/accelerate
Apache License 2.0
929 stars 117 forks source link

Initial support for dark mode terminals #933

Closed Nuru closed 2 months ago

Nuru commented 2 months ago

notes

Dark mode

This release brings preliminary support for "dark mode" terminals, and a simplified option for a Terraform workspace prompt. If you find problems, please report them, but we expect the situation will at least be no worse than before.

Mainly, with respect to dark mode terminals, after setting a text color, we do not "revert" by setting the text to black, we now revert by setting foreground and background to terminal defaults.

Similarly, after setting text to bold, we no longer reset all graphics settings, we just unset bold. If this causes a problem in your terminal, you can revert the behavior by setting the environment variable TERM_BOLD_OFF=$(tput sgr0) inside Geodesic.

Terraform workspace in prompt

Geodesic has a legacy option for displaying the current Terraform workspace when in a directory with *.tf files. The prompts used to instruct you what to do if no workspace was selected, assuming you were using the old Cloud Posse tooling based on make and direnv. Those instructions have been removed, and you now have the option of just having the Terraform workspace displayed in the prompt.

Because all the prompt now does is indicate the current Terraform workspace, the environment variable GEODESIC_TERRAFORM_WORKSPACE_PROMPT_ENABLED is no longer used (assumed to be true). The Terraform information display in the prompt remains controlled by the GEODESIC_TF_PROMPT_ENABLED environment variable, which defaults to false.

what

why