Skip to content

Commit

Permalink
Ensure tailwind is available even on runtime: false, closes #87
Browse files Browse the repository at this point in the history
  • Loading branch information
josevalim committed Jun 23, 2023
1 parent 34b0887 commit 68185c7
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
4 changes: 4 additions & 0 deletions lib/mix/tasks/tailwind.ex
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,10 @@ defmodule Mix.Tasks.Tailwind do
switches = [runtime_config: :boolean]
{opts, remaining_args} = OptionParser.parse_head!(args, switches: switches)

if function_exported?(Mix, :ensure_application!, 1) do
Mix.ensure_application!(:inets)
end

if opts[:runtime_config] do
Mix.Task.run("app.config")
else
Expand Down
4 changes: 4 additions & 0 deletions lib/mix/tasks/tailwind.install.ex
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,10 @@ defmodule Mix.Tasks.Tailwind.Install do
end
end

if function_exported?(Mix, :ensure_application!, 1) do
Mix.ensure_application!(:inets)
end

Tailwind.install(base_url)
end
end
Expand Down

0 comments on commit 68185c7

Please sign in to comment.