Makefile 1.2 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. .PHONY: all cont continuous clean publish
  2. LATEXMK= latexmk -outdir=./build -pdf
  3. all:
  4. $(LATEXMK) book.tex
  5. cont: continuous
  6. continuous:
  7. $(LATEXMK) -pvc book.tex
  8. clean:
  9. $(LATEXMK) -C book.tex
  10. rm -f book.log book.aux book.bbl book.lof book.out book.toc book.blg book.pdf
  11. # Build with a fixed snapshot of NixPkgs 17.03. Known-to-work.
  12. # For a very clean version, run git clean -fxd followed by this:
  13. #
  14. # This may take a long time and build a complete version of texlive.
  15. # Since it is fixed-in-time it may not have binary caches available and
  16. # may need to build from source.
  17. nix:
  18. NIX_PATH=nixpkgs=https://github.com/NixOS/nixpkgs-channels/archive/51a83266d164195698f04468d90d2c6238ed3491.tar.gz $(MAKE) nix-head
  19. # This is a compromise. Build faster by using a binary cache, but
  20. # still allow minor version patches by pointing at the head of a
  21. # (dynamic) channel.
  22. nix-fast:
  23. NIX_PATH=nixpkgs=https://github.com/NixOS/nixpkgs-channels/archive/nixos-17.03.tar.gz $(MAKE) nix-head
  24. # Build with whatever version of nixpkgs is in the users environment:
  25. nix-head:
  26. nix-shell --pure --run make
  27. # Specific to Fall16:
  28. publish:
  29. scp build/book.pdf tank.soic.indiana.edu:p523-web/book.pdf