What is the difference between the two? I could not find any documentation for hugo serve
.
1 Like
According to the source code, serve
is just an alias for server
, so the behavior is the same:
func (b *commandsBuilder) newServerCmdSignaled(stop <-chan bool) *serverCmd {
cc := &serverCmd{stop: stop}
cc.baseBuilderCmd = b.newBuilderCmd(&cobra.Command{
Use: "server",
Aliases: []string{"serve"},
Short: "A high performance webserver",
Long: `Hugo provides its own webserver which builds and serves the site.
While hugo server is high performance, it is a webserver with limited options.
Source code here : https://github.com/gohugoio/hugo/blob/cd4d8202016bd3eb5ed9144c8945edaba73c8cf4/commands/server.go#L74
3 Likes
Okay, good to know. Thanks for responding. Is it something that we can document on the hugo server
page?
2 Likes