Skip to content

Commit

Permalink
Update doc builder
Browse files Browse the repository at this point in the history
  • Loading branch information
josevalim committed Mar 1, 2024
1 parent 6dc00f7 commit 73d510c
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions mix.exs
Original file line number Diff line number Diff line change
Expand Up @@ -62,12 +62,13 @@ defmodule MakeupElixir.Mixfile do
ex_doc = Path.join(Mix.path_for(:escripts), "ex_doc")

unless File.exists?(ex_doc) do
raise "cannot build docs because escript for ex_doc is not installed"
raise "cannot build docs because escript for ex_doc is not installed, run \"mix escript.install hex ex_doc\""
end

paths = Path.join(Mix.Project.build_path(), "lib/*/ebin")
args = ["MakeupElixir", @version, Mix.Project.compile_path()]
opts = ~w[--main Makeup.Lexers.ElixirLexer --source-ref v#{@version} --source-url #{@url}]
System.cmd(ex_doc, args ++ opts)
System.cmd(ex_doc, args ++ ["--paths", paths] ++ opts)
Mix.shell().info("Docs built successfully")
end
end

0 comments on commit 73d510c

Please sign in to comment.