
A powerful MCP (Model Control Protocol) server for managing Hugo static site generator.
概览
A powerful MCP (Model Control Protocol) server for managing Hugo static site generator. This server provides a comprehensive set of tools for creating, managing, and deploying Hugo sites. - Python 3.10+ - uv (Python package manager) - Git (Highly recommended) 2. Add server to your config (make sure uv has been installed before): Remember to replace "/ABSOLUTE/PATH/TO/PARENT/FOLDER/hugo-mcp" to your installation path The Hugo MCP server provides a set of tools that can be used to manage Hugo sites. Each tool has specific parameters and returns a structured response. 1. Start the server manually (If needed): 2. Connect to the server using an MCP client. 3. Use the tools to manage your Hugo sites.
README
以下为原文 README 节选,完整内容请查看原文。
Hugo MCP Server
A powerful MCP (Model Control Protocol) server for managing Hugo static site generator. This server provides a comprehensive set of tools for creating, managing, and deploying Hugo sites.
Table of Contents
Installation
Prerequisites
- Python 3.10+
- uv (Python package manager)
- Git (Highly recommended)
Installing the Hugo MCP Server
-
Clone the repository:
git clone https://github.com/sunnycloudyang/hugo-mcp.git -
Add server to your config (make sure
uvhas been installed before):{ "mcpServers": { "hugo-mcp": { "command": "uv", "args": [ "--directory", "/ABSOLUTE/PATH/TO/PARENT/FOLDER/hugo-mcp", "run", "main.py" ] } } }Remember to replace “/ABSOLUTE/PATH/TO/PARENT/FOLDER/hugo-mcp” to your installation path
-
Enalble this mcp server and try it!
Usage
The Hugo MCP server provides a set of tools that can be used to manage Hugo sites. Each tool has specific parameters and returns a structured response.
Basic Usage
-
Start the server manually (If needed):
uv run main.py -
Connect to the server using an MCP client.
-
Use the tools to manage your Hugo sites.
Tools
Environment Setup Tools
check_hugo_installation
Description: Check if Hugo is installed and get its version.
Parameters: None
Returns:
{
"status": "success",
"version": "Hugo Static Site Generator v0.92.0/extended linux/amd64 BuildDate=unknown"
}
Error Response:
{
"status": "error",
"message": "Hugo is not installed or not in PATH"
}
Prerequisites: None
Actions After Success: None
Actions After Failure: Install Hugo using the install_hugo tool.
install_hugo
Description: Install Hugo using the appropriate method for the current OS.
Parameters:
version(optional): The version of Hugo to install. Defaults to “latest”.
Returns:
{
"status": "success",
"message": "Hugo installed via Homebrew"
}
Error Response:
{
"status": "error",
"message": "Installation failed: Command 'brew install hugo' returned non-zero exit status 1."
}
Prerequisites: Appropriate package manager (Homebrew, apt, dnf, yum) must be installed.
Actions After Success: Hugo is installed and ready to use.
安装
This server does not publish a one-line install command.
Open the repository installation guide 新手?先看 mcpskill.org 教程 →配置
{
"mcpServers": {
"hugo-mcp": {
"command": "uv",
"args": [
"--directory",
"/ABSOLUTE/PATH/TO/PARENT/FOLDER/hugo-mcp",
"run",
"main.py"
]
}
}
}