Generate docs for apps
All checks were successful
Build documentation / build-and-deploy (push) Successful in 2m46s
All checks were successful
Build documentation / build-and-deploy (push) Successful in 2m46s
This commit is contained in:
20
make/user.mk
20
make/user.mk
@@ -13,6 +13,18 @@ include ../$(platform)/flags.mk
|
||||
|
||||
FORMAT ?= clang-format -i $$(git ls-files '*.c' '*.h')
|
||||
|
||||
DOCS_COLLECT ?= $$(git ls-files '*.c' '*.h')
|
||||
|
||||
DOCS ?= \
|
||||
rm -rf docs; \
|
||||
clang-doc --format=md --output docs -p . $(DOCS_COLLECT); \
|
||||
for f in ./docs/GlobalNamespace/*.md; \
|
||||
do sed -i '/^\# Global Namespace/d' "$$f"; \
|
||||
done; \
|
||||
rm -rf ../docs/apps/$(app); \
|
||||
mkdir -p ../docs/apps/$(app); \
|
||||
cp ./docs/GlobalNamespace/*.md ../docs/apps/$(app);
|
||||
|
||||
all: $(app)
|
||||
|
||||
$(app): $(extra_deps) $(o)
|
||||
@@ -30,4 +42,10 @@ clean:
|
||||
format:
|
||||
$(FORMAT)
|
||||
|
||||
.PHONY: all clean format
|
||||
docs:
|
||||
$(DOCS)
|
||||
|
||||
compiledb:
|
||||
bear --output compile_commands.json -- make platform=$(platform) all
|
||||
|
||||
.PHONY: all clean format docs compiledb
|
||||
|
||||
Reference in New Issue
Block a user