mirror of https://gitee.com/bigwinds/arangodb
115 lines
4.1 KiB
Makefile
115 lines
4.1 KiB
Makefile
# -*- mode: Makefile; -*-
|
|
|
|
## -----------------------------------------------------------------------------
|
|
## --SECTION-- DOCUMENTATION
|
|
## -----------------------------------------------------------------------------
|
|
|
|
################################################################################
|
|
### @brief install man pages
|
|
################################################################################
|
|
|
|
dist_man_MANS += \
|
|
Documentation/man/man1/arangob.1 \
|
|
Documentation/man/man1/arangodump.1 \
|
|
Documentation/man/man1/arangoimp.1 \
|
|
Documentation/man/man1/arangorestore.1 \
|
|
Documentation/man/man1/arangosh.1 \
|
|
Documentation/man/man8/rcarangod.8 \
|
|
Documentation/man/man8/arangod.8 \
|
|
Documentation/man/man8/arango-dfdb.8 \
|
|
Documentation/man/man8/foxx-manager.8
|
|
|
|
################################################################################
|
|
### @brief man pages
|
|
################################################################################
|
|
|
|
.PHONY: man
|
|
|
|
man:
|
|
for section in 1 8; do \
|
|
for i in `ls Documentation/man$$section`; do \
|
|
sed -f Documentation/Scripts/man.sed \
|
|
-e "s/\<SECTION\>/$$section/" \
|
|
-e "s/\<COMMAND\>/$$i/g" \
|
|
-e "s/DATE/`date`/g" Documentation/man$$section/$$i \
|
|
> Documentation/man/man$$section/$$i.$$section; \
|
|
done; \
|
|
done
|
|
|
|
################################################################################
|
|
### @brief generate json for swagger REST-API
|
|
################################################################################
|
|
|
|
.PHONY: swagger
|
|
|
|
swagger:
|
|
(python \
|
|
@srcdir@/Documentation/Scripts/generateSwagger.py \
|
|
@srcdir@ \
|
|
@srcdir@/js/apps/system/_admin/aardvark/APP/api-docs api-docs \
|
|
) > @srcdir@/js/apps/system/_admin/aardvark/APP/api-docs.json
|
|
|
|
## -----------------------------------------------------------------------------
|
|
## --SECTION-- EXAMPLES
|
|
## -----------------------------------------------------------------------------
|
|
|
|
################################################################################
|
|
### @brief generate examples
|
|
################################################################################
|
|
|
|
.PHONY: examples
|
|
|
|
examples:
|
|
@rm -f /tmp/arangodb.examples
|
|
|
|
python @srcdir@/Documentation/Scripts/generateExamples.py \
|
|
--outputDir @builddir@/Documentation/Examples \
|
|
--onlyThisOne "$(FILTER_EXAMPLE)" \
|
|
--outputFile /tmp/arangosh.examples.js \
|
|
--arangoshSetup @srcdir@/Documentation/Examples/setup-arangosh.js \
|
|
@srcdir@/js/actions \
|
|
@srcdir@/js/client \
|
|
@srcdir@/js/common \
|
|
@srcdir@/js/server \
|
|
@srcdir@/js/apps/system/_api/gharial/APP \
|
|
@srcdir@/Documentation/Books/Users \
|
|
@srcdir@/arangod/RestHandler \
|
|
@srcdir@/arangod/V8Server
|
|
|
|
if test -z "$(server.endpoint)"; then \
|
|
$(MAKE) start-server PID=$(PID) \
|
|
SERVER_START="--server.endpoint tcp://$(VOCHOST):$(VOCPORT) --server.disable-authentication true" \
|
|
PROTO=http ;\
|
|
@builddir@/bin/arangosh \
|
|
-s \
|
|
-c @srcdir@/etc/relative/arangosh.conf \
|
|
--server.password "" \
|
|
--server.endpoint tcp://$(VOCHOST):$(VOCPORT) \
|
|
--javascript.execute /tmp/arangosh.examples.js ;\
|
|
else \
|
|
@builddir@/bin/arangosh \
|
|
-s \
|
|
-c @srcdir@/etc/relative/arangosh.conf \
|
|
--server.password "" \
|
|
--server.endpoint $(server.endpoint) \
|
|
--javascript.execute /tmp/arangosh.examples.js ;\
|
|
fi
|
|
|
|
examples-inspect-file:
|
|
@echo "generating /tmp/allExamples.html"
|
|
@(printf "<html><head></head><body><pre>\n"; \
|
|
for thisExample in Documentation/Examples/*.generated; do \
|
|
printf "<hr>\n<h3>$$thisExample</h3>\n"; \
|
|
cat $$thisExample; \
|
|
done; \
|
|
printf "</pre></body></html>") > /tmp/allExamples.html
|
|
|
|
## -----------------------------------------------------------------------------
|
|
## --SECTION-- END-OF-FILE
|
|
## -----------------------------------------------------------------------------
|
|
|
|
## Local Variables:
|
|
## mode: outline-minor
|
|
## outline-regexp: "^\\(### @brief\\|## --SECTION--\\|# -\\*- \\)"
|
|
## End:
|