Skip to content

Commit

Permalink
chore: remove stacktrace from new message
Browse files Browse the repository at this point in the history
  • Loading branch information
zachdaniel committed Jan 22, 2025
1 parent e3537c0 commit ae01f20
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions lib/mix/task.ex
Original file line number Diff line number Diff line change
Expand Up @@ -235,14 +235,16 @@ defmodule Igniter.Mix.Task do
if last && String.ends_with?(last, ",") do
arg_name = String.replace(to_string(k), "_", "-")

raise """
Mix.shell().error("""
Found trailing comma in `--#{arg_name}` at `#{last}`
Please remove the trailing comma.
On some platforms, argument parsing requires quotes around argument values containing commas.
So instead of `--#{arg_name} foo,bar`, you may need `--#{arg_name} "foo,bar"`
"""
""")

exit({:shutdown, 1})
end
end)
|> Enum.flat_map(&String.split(&1, ",", trim: true))
Expand Down

0 comments on commit ae01f20

Please sign in to comment.