Skip to content

Commit

Permalink
Handling missing_option errors
Browse files Browse the repository at this point in the history
  • Loading branch information
kojix2 committed Apr 10, 2024
1 parent 3b88cd5 commit c44fd7f
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/deepl/parser.cr
Original file line number Diff line number Diff line change
Expand Up @@ -250,6 +250,12 @@ module DeepL
STDERR.puts self
exit(1)
end

missing_option do |flag|
STDERR.puts "[deepl-cli] ERROR: #{flag} expects an argument."
STDERR.puts self
exit(1)
end
end

def parse(args)
Expand Down

0 comments on commit c44fd7f

Please sign in to comment.