lib/edge/console.rb in edge_framework-0.0.3 vs lib/edge/console.rb in edge_framework-0.1.0
- old
+ new
@@ -1,10 +1,15 @@
module Edge
class Console
def colorize(text, color_code)
- "\033[#{color_code}m#{text}\033[0m"
+ "\e[#{color_code}m#{text}\e[0m"
end
def red(text); colorize(text, 31); end
def green(text); colorize(text, 32); end
+ def yellow(text); colorize(text, 33); end
+ def blue(text); colorize(text, 34); end
+ def magenta(text); colorize(text, 35); end
+ def cyan(text); colorize(text, 36); end
+
end
end
\ No newline at end of file