Skip to content

Instantly share code, notes, and snippets.

@ehowe
Created January 16, 2012 18:15
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ehowe/1622119 to your computer and use it in GitHub Desktop.
Save ehowe/1622119 to your computer and use it in GitHub Desktop.
require 'readline'
input = Readline.readline("\[\e[32;01m\]Prompt is green and bold >\[\e[0m\]")
puts input
#Output will be []Prompt is green >[]
#Prompt will actually be green and bold, so the colors are working, just not the escaping.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment