mehran
mehran

Reputation: 198

how to change Git Bash options for terminal to xterm-256color

I want to change the color of the bash but I dont know how to.

I tried with right clicking the bash but this just gave me the properties. Here a screenshot of my git bash: my console

Upvotes: 2

Views: 4874

Answers (3)

t0r0X
t0r0X

Reputation: 4752

The screenshot in the question suggests it is about "Git Bash" (Windows specific, see https://gitforwindows.org/).

For some reasons I had once to explicitly set the TERM environment variable to the value xterm. That broke the output in "Git Bash" sessions which were started embedded in IntelliJ IDEA ("Terminal" tool), exactly like described in the posted question. The solution was to set the TERM environment variable either to xterm-256color (!) or to the default value (default for "Git Bash"), which is cygwin.

Small before/after example: enter image description here

If you need/want to permanently set the new value for the TERM environment variable, the best solution would be to add export TERM=xterm-256color to your ~/.bashrc file.

Upvotes: 1

this worked for Laravel 6. *

composer require symfony/console:4.3.4

Upvotes: 1

Javier C.
Javier C.

Reputation: 8257

If you are using Git Bash on Windows you can changue color with these steeps:

  • Open a Git bash windows and click on the upper left corner of the windows frame.
  • In the menu that will be appear click on Properties -> Colors and check Screen Text and remenber the color that is currently assigned to this checkbox.
  • Select the new color clicking on the color box.
  • Change the Blue/Red/Green values for the selected color.
  • Screen Text checkbox is now still the color so click on the original color that you have remembered.

The changes are permanent and only for the shortcut you have used to start Git Bash.

Upvotes: 1

Related Questions