Skip to content

Commit

Permalink
Fix #345 change colours to be bold and reset instead of white and gre…
Browse files Browse the repository at this point in the history
…y. This makes the colour output readable with both light and dark terminal backgrounds.
  • Loading branch information
urbanadventurer committed Nov 4, 2020
1 parent 4257078 commit 54fcbaf
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions lib/colour.rb
Original file line number Diff line number Diff line change
Expand Up @@ -68,9 +68,12 @@ def dark_cyan(text)
end

def white(text)
colorize(text, "\e[1m\e[37m")
# quick patch for issue #345 so it's readable with a white terminal background
# not white, but bold
colorize(text, "\e[1m")
end

def grey(text)
colorize(text, "\e[37m")
# not grey, but reset
colorize(text, "\e[0m\e[22m")
end

0 comments on commit 54fcbaf

Please sign in to comment.