Actions Hugo screenshot

Actions Hugo

Author Avatar Theme by Peaceiris
Updated: 15 Nov 2024
1490 Stars

GitHub Actions for Hugo Setup Hugo quickly and build your site fast. Hugo extended, Hugo Modules, Linux (Ubuntu), macOS, and Windows are supported.

Overview

GitHub Actions for Hugo is a project that provides an action for installing Hugo, a popular static site generator, in a virtual machine on GitHub Actions. This action supports Hugo extended version, Hugo Modules, and is compatible with Linux (Ubuntu), macOS, and Windows. It has recently migrated to a JavaScript (TypeScript) action, eliminating the need to build or pull a Hugo docker image. This change has significantly improved the execution time of the action. The project is actively developed and has reached a stable state.

Features

  • Support for Multiple Operating Systems: The action can be run on Ubuntu, macOS, and Windows.
  • Hugo Extended Version: The action supports the installation of Hugo extended version.
  • Hugo Modules Support: The action is compatible with Hugo Modules, allowing users to utilize this feature in their Hugo projects.
  • Quick Execution: Thanks to the migration to a JavaScript action, the installation process now takes only a few seconds, significantly improving the overall execution time.

Installation

To install the GitHub Actions for Hugo, you can follow these steps:

  1. Create a workflow file in your repository’s .github/workflows directory. For example, .github/workflows/gh-pages.yml.
  2. Add the necessary configurations to the workflow file, such as specifying the operating system and Hugo version.
  3. Use the provided examples and tips in the documentation to customize your workflow based on your project’s requirements.

Summary

GitHub Actions for Hugo is a project that provides an action for installing Hugo in a virtual machine on GitHub Actions. It supports multiple operating systems and enables users to leverage the features of Hugo extended version and Hugo Modules. The recent migration to a JavaScript (TypeScript) action has drastically improved the execution time of the action. With easy installation and extensive documentation, this project is a valuable asset for Hugo users on GitHub Actions.