Let Commander handle bad args after printing of deprecation warning. Fixes #1040.

This commit is contained in:
Parker Moore 2013-05-07 13:15:03 +02:00
parent 7dccb6c996
commit d0a9948eed
1 changed files with 0 additions and 2 deletions

View File

@ -20,14 +20,12 @@ module Jekyll
if args.size > 0 && args.first =~ /^--/ && !%w[--help --version].include?(args.first)
Jekyll::Logger.error "Deprecation:", "Jekyll now uses subcommands instead of just \
switches. Run `jekyll help' to find out more."
exit(1)
end
end
def self.deprecation_message(args, deprecated_argument, message)
if args.include?(deprecated_argument)
Jekyll::Logger.error "Deprecation:", message
exit(1)
end
end
end