Skip to content

Commit

Permalink
repl: fix color detection on windows
Browse files Browse the repository at this point in the history
  • Loading branch information
nolta committed Mar 26, 2014
1 parent 0487222 commit f9d3a8b
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion base/Terminals.jl
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,8 @@ module Terminals
stop_reading(t::UnixTerminal) = stop_reading(t.in_stream)


hascolor(t::UnixTerminal) = (beginswith(t.term_type,"xterm") || success(`tput setaf 0`))
@unix_only hascolor(t::UnixTerminal) = (beginswith(t.term_type,"xterm") || success(`tput setaf 0`))
@windows_only hascolor(t::UnixTerminal) = true
#writemime(t::UnixTerminal, ::MIME"text/plain", x) = writemime(t.out_stream, MIME("text/plain"), x)
end
importall .Unix
Expand Down

0 comments on commit f9d3a8b

Please sign in to comment.