Error message is red

This commit is contained in:
Parker Moore 2013-04-13 20:27:44 +02:00
parent ef9d8ddb7d
commit ef51b0f9e4
2 changed files with 11 additions and 1 deletions

View File

@ -17,7 +17,7 @@ module Jekyll
def self.deprecation_message(args, deprecated_argument, message)
if args.include?(deprecated_argument)
Jekyll.warn "Deprecation:", message
Jekyll.error "Deprecation:", message
exit(1)
end
end

View File

@ -20,6 +20,16 @@ module Jekyll
$stderr.puts (Jekyll.message(topic, message)).yellow
end
# Public: Print a jekyll error message to stderr
#
# topic - the topic of the message, e.g. "Configuration file", "Deprecation", etc.
# message - the message detail
#
# Returns nothing
def error(topic, message)
$stderr.puts (Jekyll.message(topic, message)).red
end
# Public: Build a Jekyll topic method
#
# topic - the topic of the message, e.g. "Configuration file", "Deprecation", etc.