Makefile 888 B

12345678910111213141516171819202122232425262728293031323334353637383940
  1. PHONY := all
  2. include .env
  3. export $(shell sed 's/=.*//' .env)
  4. BASEDIR=$(CURDIR)
  5. INPUTDIR=$(BASEDIR)
  6. OUTPUTDIR=$(BASEDIR)/doc
  7. SSH_HOST=$(ENV_HOST)
  8. SSH_PORT=$(ENV_PORT)
  9. SSH_USER=$(ENV_USER)
  10. SSH_TARGET_DIR=$(ENV_TARGET_DIR)
  11. all: generate publish
  12. help:
  13. @echo ' Makefile for cv upload '
  14. @echo ' '
  15. @echo ' Usage: '
  16. @echo ' make publish Upload cv to server... '
  17. @echo ' make clean Clean cv '
  18. @echo ' '
  19. clear:
  20. rm -rf doc/
  21. find . -name "*.info" -delete
  22. find . -name "*.html" -delete
  23. generate:
  24. makeinfo --html doc.texi
  25. publish: generate
  26. rsync -e "ssh -p $(SSH_PORT)" -P -rvzc --delete $(OUTPUTDIR)/ $(SSH_USER)@$(SSH_HOST):$(SSH_TARGET_DIR)/
  27. test:
  28. env
  29. .PHONY: $(PHONY)