Skip to content

Commit 46c39ae

Browse files
committed
Do not set docs source_ref to -latest tags
1 parent 5f657f9 commit 46c39ae

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

Makefile

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -176,7 +176,9 @@ clean_elixir:
176176

177177
#==> Documentation tasks
178178

179-
SOURCE_REF = $(shell tag="$(call GIT_TAG)" revision="$(call GIT_REVISION)"; echo "$${tag:-$$revision}")
179+
SOURCE_REF = $(shell tag="$(call GIT_TAG)"; revision="$(call GIT_REVISION)"; \
180+
if echo "$$tag" | grep -Eq -- '-latest$$'; then tag=""; fi; \
181+
echo "$${tag:-$$revision}")
180182
DOCS_COMPILE = CANONICAL=$(CANONICAL) bin/elixir ../ex_doc/bin/ex_doc "$(1)" "$(VERSION)" "lib/$(2)/ebin" --main "$(3)" --source-url "https://github.com/elixir-lang/elixir" --source-ref "$(call SOURCE_REF)" --logo lib/elixir/pages/images/logo.png --output doc/$(2) --canonical "https://hexdocs.pm/$(2)/$(CANONICAL)" --homepage-url "https://elixir-lang.org/docs.html" $(4)
181183
DOCS_CONFIG = bin/elixir lib/elixir/scripts/docs_config.exs "$(1)"
182184

0 commit comments

Comments
 (0)