You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
Deze repo is gearchiveerd. U kunt bestanden bekijken en het klonen, maar niet pushen of problemen/pull-requests openen.
 
 
 
 
 
 

25 regels
456 B

  1. import sys
  2. import os
  3. import subprocess
  4. def main():
  5. if len(sys.argv) < 2:
  6. sys.exit("Usage: build.py NUMBER")
  7. number = sys.argv[1]
  8. os.makedirs("build", exist_ok=True)
  9. cmd = []
  10. if sys.platform == "darwin":
  11. # From mactex
  12. cmd.append("texi2pdf")
  13. else:
  14. cmd.append("pdflatex")
  15. cmd.append(f"../python-{number}")
  16. subprocess.run(cmd, cwd="build", check=True)
  17. if __name__ == "__main__":
  18. main()