Documentation

GitHub deploy Automatic upload of the build to GitHub

In Animmaster Vite Template you can automatically build your project and upload the final dist folder to a GitHub repository with a single command.

What is GitHub deploy?

Animmaster Vite Template includes a built-in workflow that allows you to automatically upload the production build (dist folder) to a GitHub repository.

This is especially useful for:

  • publishing static websites
  • GitHub Pages deployments
  • quick sharing of project builds

Configuration

To enable GitHub uploading, configure the git section in template.config.js.

template.config.js
git: {
  repo: "https://github.com/username/repository.git",
  branch: "main"
}
Important
The repository must already exist and you must have access rights (push permissions).

Deploy command

To build the project and upload it to GitHub, run:

Terminal
npm run git

This command automatically:

  • runs a production build
  • creates the dist folder
  • pushes the result to the configured branch

Notes & tips

Git authentication
Make sure Git authentication is already configured on your machine (SSH key or credential manager).
Best practice
Use a dedicated branch (for example gh-pages) if you plan to host the project via GitHub Pages.

Download

Automated GitHub deployment is just one of many features in Animmaster Vite Template. Download the template and simplify your production workflow.