Skip to content

Commit 12e052e

Browse files
author
José Valim
committed
Revert "Warn if no status after eof"
This reverts commit fca45d8.
1 parent ee56234 commit 12e052e

File tree

1 file changed

+6
-13
lines changed

1 file changed

+6
-13
lines changed

lib/mix/lib/mix/shell.ex

Lines changed: 6 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -89,25 +89,18 @@ defmodule Mix.Shell do
8989
end
9090

9191
port = Port.open({:spawn, shell_command(command)},
92-
[:stream, :binary, :exit_status, :hide, :use_stdio, :eof, {:env, env}|args])
92+
[:stream, :binary, :exit_status, :hide, :use_stdio, {:env, env}|args])
9393

94-
do_cmd(port, command, callback)
94+
do_cmd(port, callback)
9595
end
9696

97-
defp do_cmd(port, command, callback) do
97+
defp do_cmd(port, callback) do
9898
receive do
9999
{^port, {:data, data}} ->
100100
callback.(data)
101-
do_cmd(port, command, callback)
102-
{^port, :eof} ->
103-
receive do
104-
{^port, {:exit_status, status}} ->
105-
status
106-
after
107-
5_000 ->
108-
IO.puts :stderr, "warning: did not receive exit status after command: #{command}"
109-
0
110-
end
101+
do_cmd(port, callback)
102+
{^port, {:exit_status, status}} ->
103+
status
111104
end
112105
end
113106

0 commit comments

Comments
 (0)