commands: Add "hugo build" as an alias for "hugo"

Closes #11391
This commit is contained in:
Bjørn Erik Pedersen 2024-09-30 09:11:24 +02:00
parent 1158e63072
commit 0450d69fc6
6 changed files with 142 additions and 4 deletions

View file

@ -1,6 +1,6 @@
# Test the gen commands.
# Note that adding new commands will require updating the NUM_COMMANDS value.
env NUM_COMMANDS=43
env NUM_COMMANDS=44
hugo gen -h
stdout 'A collection of several useful generators\.'

View file

@ -0,0 +1,20 @@
# Test the hugo build command (alias for hugo)
hugo build
stdout 'Pages.*|1'
stdout 'Total in'
checkfile public/index.html
checkfile public/p1/index.html
grep 'IsServer: false;IsProduction: true' public/index.html
-- hugo.toml --
baseURL = "http://example.org/"
disableKinds = ["RSS", "sitemap", "robotsTXT", "404", "taxonomy", "term"]
-- layouts/index.html --
Home|IsServer: {{ hugo.IsServer }};IsProduction: {{ hugo.IsProduction }}|
-- layouts/_default/single.html --
Title: {{ .Title }}
-- content/p1.md --
---
title: "P1"
---