OpenAPI spec task: Load pleroma application to get version info
For whatever reason it seems to pick up the version without loading the app on my machine, but not on the CI.
This commit is contained in:
parent
fc42e714e2
commit
f13f5d9303
1 changed files with 2 additions and 0 deletions
|
@ -1,5 +1,7 @@
|
||||||
defmodule Mix.Tasks.Pleroma.OpenapiSpec do
|
defmodule Mix.Tasks.Pleroma.OpenapiSpec do
|
||||||
def run([path]) do
|
def run([path]) do
|
||||||
|
# Load Pleroma application to get version info
|
||||||
|
Application.load(:pleroma)
|
||||||
spec = Pleroma.Web.ApiSpec.spec(server_specific: false) |> Jason.encode!()
|
spec = Pleroma.Web.ApiSpec.spec(server_specific: false) |> Jason.encode!()
|
||||||
File.write(path, spec)
|
File.write(path, spec)
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in a new issue