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

[Q] How to change colors in atom termination terminal. #110

Open
pisulski opened this issue May 22, 2020 · 5 comments
Open

[Q] How to change colors in atom termination terminal. #110

pisulski opened this issue May 22, 2020 · 5 comments
Labels
question ❓ Further information is requested

Comments

@pisulski
Copy link

xxx@xxx:~/.atom/packages/termination/styles$
Please help me to do it.
I want to change color for path line in terminal.
Similar function to platformio-ide-terminal.

Regards

@pisulski pisulski added the question ❓ Further information is requested label May 22, 2020
@Mi-la-la
Copy link

Mi-la-la commented Dec 24, 2020

I had the same question, and you're the only person I found online who was asking for this. I couldn't find any answers, so I set about working it out and eventually found the following steps to be successful. I use the Homebrew theme.

The-joker below suggested editing the style.less sheet rather than my initial suggestion of editing the homebrew.less file directly, so the answer is revised.

The first two steps here worked on MacOS:

  • Open Atom, then open styles.less
    • On MacOS, go to 'Atom' then 'Stylesheets'
    • On Windows, go to 'File' then 'Stylesheets'
  • Add in the following lines, and edit the rgb values to the colours you like, then save.
// change Termination theme colours
.termination .homebrew { // change .homebrew to the name of your theme
  background-color: rgb(0, 0, 0);
  color: rgb(255, 128, 0);

  ::selection {
    background-color: rgba(7, 30, 155, .99);
  }

  .terminal-cursor {
    background-color: rgb(255,128,0);
  }
}

I still can't make the above work with the Windows 10, so have left the rest of the directions for W10 here for the time being.

  • Open Atom settings for Termination, then click 'View Code' (alternatively, navigate to ~/.atom/packages/termination).
  • Navigate to folder /lib/themes/homebrew.coffee.
  • Edit line 13 from red: #xxxxxx to red: '#yyyyyy' where yyyyyy is the HEX colour code that you would like your text to be. Make sure the # doesn't get missed.
  • Restart Atom.
  • This change will reset with updates.

Let me know how this works out for you, @pisulski.

PS Easy RGB to Hex Converter: https://duckduckgo.com/?q=rgb+to+hex&ia=answer

PS the-joker below has suggested using Terminus, which does't really answer the original question but may well be a reasonable option for the original poster. Termination still has over 64k installs vs the 24k for Terminus, so I reckon this message is still worth leaving here in case anyone else is interested in how to do this.

@the-j0k3r
Copy link
Member

the-j0k3r commented Dec 27, 2020

The solution is never to actually edit any source files, any such edits are unsupported and will be lost on next update, the solution is always to use style.less in Atom, the same as described in the projects readme https://github.com/bus-stop/Termination#themes

this works on all supported platforms.

@Mi-la-la
Copy link

Thank you, this is very useful advice.

I have successfully added the code which overrides the /styles/themes/homebrew.less settings. I will update the original post to reflect this way of doing things.

Still, I can't work out how to override the /lib/themes/homebrew.coffee setting which is needed to make the colour change work in Windows 10 - any advice you have on this would be really welcome!

@the-j0k3r
Copy link
Member

the-j0k3r commented Dec 27, 2020

Idk if termination refreshes the styles automatically, you may need to close any open terminals and reopen to see the change,

I dont use termination but I know it works in terminus/x-terminal just fine automatically.

@Fred-Barclay
Copy link
Collaborator

Styles are refreshed automatically, but sometimes some old bits are left behind so it's usually cleanest to just close and reopen the terminals.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
question ❓ Further information is requested
Development

No branches or pull requests

4 participants