Skip to main content

The PreTeXt Guide

Subsection 5.2.6 Hosting your project: pretext deploy

When you are ready to share your project with the world, you can copy the contents of the output/web (or whatever you called the output of your html build) to any webserver. A convenient free option is to use GitHub Pages 4 , and the CLI makes this especially easy.
If you already track your source files using GitHub, all you need to do is enter the following command:
$ pretext deploy
This copies the contents of the html output folder into docs, commits the changes, and pushes them to GitHub. All you need to do then is ensure that you enable the pages feature in your GitHub repository (Settings, then Pages, then set to deploy from a branch: gh-pages).
If your project is not already tracked on GitHub, the CLI will walk you through the steps you need to get set up.
pages.github.com/