diff --git a/lib/mix/task.ex b/lib/mix/task.ex index 5d905ef..0865d01 100644 --- a/lib/mix/task.ex +++ b/lib/mix/task.ex @@ -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))