id = "hugo" name = "Hugo" description = "Hugo is a static site generator." homepage = "https://gohugo.io" executables = ["hugo"] [commands] format = 1 label = "Build site" description = "Build the site in the current directory into the destination folder. Use the subcommand tabs for the dev server and new content; modules, imports and generators are left out." quality = "ai-draft" base = "fig:hugo" parser = { end_of_options = "--", interleave = "permute", long_equals = true, short_attached = true, short_bundles = false } [[commands.source]] id = "fig" kind = "completion" url = "https://github.com/withfig/autocomplete/blob/master/src/hugo.ts" license = "MIT" [[commands.field]] id = "minify" label = "Minify output" type = "boolean" option = ["--minify"] sources = ["fig"] [[commands.field]] id = "build_drafts" label = "Include drafts" type = "boolean" option = ["--buildDrafts"] sources = ["fig"] [[commands.field]] id = "build_future" label = "Include future-dated content" type = "boolean" option = ["--buildFuture"] sources = ["fig"] [[commands.field]] id = "gc" label = "Clean unused cache files after build" type = "boolean" option = ["--gc"] sources = ["fig"] [[commands.field]] id = "base_url" label = "Base URL" type = "url" option = ["--baseURL"] sources = ["fig"] [[commands.field]] id = "destination" label = "Destination directory" type = "path" option = ["--destination"] path = { kind = "directory", role = "output" } sources = ["fig"] [[commands.field]] id = "clean_destination" label = "Remove stale files from destination" type = "boolean" option = ["--cleanDestinationDir"] effect = "delete" sources = ["fig"] [[commands.field]] id = "environment" label = "Environment" type = "string" option = ["--environment"] suggestions = [{ value = "production", label = "production" }, { value = "development", label = "development" }] sources = ["fig"] [[commands.task]] id = "production" label = "Production build" fields = ["minify", "gc", "environment"] required = [] set = { minify = [true], gc = [true] } [[commands.group]] id = "basic" label = "Basic" fields = ["minify", "build_drafts", "build_future", "base_url", "destination"] [[commands.group]] id = "advanced" label = "Advanced" fields = ["gc", "clean_destination", "environment"] [[commands.subcommand]] path = ["server"] label = "Run dev server" description = "Serve the site locally with live reload. Press Ctrl+C to stop." parser = { end_of_options = "--", interleave = "permute", long_equals = true, short_attached = true, short_bundles = false } [[commands.subcommand.source]] id = "fig" kind = "completion" url = "https://github.com/withfig/autocomplete/blob/master/src/hugo.ts" license = "MIT" [[commands.subcommand.field]] id = "port" label = "Port" type = "integer" option = ["--port"] sources = ["fig"] [[commands.subcommand.field]] id = "bind" label = "Bind address" type = "string" option = ["--bind"] sources = ["fig"] [[commands.subcommand.field]] id = "build_drafts" label = "Include drafts" type = "boolean" option = ["--buildDrafts"] sources = ["fig"] [[commands.subcommand.field]] id = "build_future" label = "Include future-dated content" type = "boolean" option = ["--buildFuture"] sources = ["fig"] [[commands.subcommand.field]] id = "disable_live_reload" label = "Disable live reload" type = "boolean" option = ["--disableLiveReload"] sources = ["fig"] [[commands.subcommand.field]] id = "navigate_to_changed" label = "Navigate to changed content" type = "boolean" option = ["--navigateToChanged"] sources = ["fig"] [[commands.subcommand.task]] id = "with_drafts" label = "Serve with drafts" fields = ["port", "build_drafts"] required = [] set = { build_drafts = [true] } [[commands.subcommand.group]] id = "basic" label = "Basic" fields = ["port", "bind", "build_drafts", "build_future"] [[commands.subcommand.group]] id = "advanced" label = "Advanced" fields = ["disable_live_reload", "navigate_to_changed"] [[commands.subcommand]] path = ["new"] label = "New content" description = "Create a content file in the current site. Creating a whole site or theme is not covered." parser = { end_of_options = "--", interleave = "permute", long_equals = true, short_attached = true, short_bundles = false } [[commands.subcommand.source]] id = "fig" kind = "completion" url = "https://github.com/withfig/autocomplete/blob/master/src/hugo.ts" license = "MIT" [[commands.subcommand.field]] id = "file" label = "Content path" description = "Section and file name, for example posts/my-first-post.md." type = "string" position = 0 min = 1 sources = ["fig"] [[commands.subcommand.field]] id = "kind" label = "Archetype" type = "string" option = ["--kind"] suggestions = [{ value = "default", label = "default" }] sources = ["fig"] [[commands.subcommand.field]] id = "editor" label = "Open in editor" type = "string" option = ["--editor"] sources = ["fig"] [[commands.subcommand.task]] id = "new_post" label = "New post" fields = ["file", "kind"] required = ["file"] [[commands.subcommand.group]] id = "basic" label = "Basic" fields = ["file", "kind", "editor"]