mirror of
https://github.com/gohugoio/hugo.git
synced 2024-12-26 03:31:54 +00:00
Add genDocsHelper mage target
Expose the functionality of the hidden `hugo gen docshelper` command as a mage target.
This commit is contained in:
parent
f720fe56db
commit
889dc47ceb
1 changed files with 6 additions and 1 deletions
|
@ -66,6 +66,7 @@ func flagEnv() map[string]string {
|
|||
}
|
||||
}
|
||||
|
||||
// Generate autogen packages
|
||||
func Generate() error {
|
||||
generatorPackages := []string{
|
||||
"tpl/tplimpl/embedded/generate",
|
||||
|
@ -101,6 +102,11 @@ func Generate() error {
|
|||
return nil
|
||||
}
|
||||
|
||||
// Generate docs helper
|
||||
func GenDocsHelper() error {
|
||||
return runCmd(flagEnv(), goexe, "run", "-tags", buildTags(), "main.go", "gen", "docshelper")
|
||||
}
|
||||
|
||||
// Build hugo without git info
|
||||
func HugoNoGitInfo() error {
|
||||
ldflags = noGitLdflags
|
||||
|
@ -334,5 +340,4 @@ func buildTags() string {
|
|||
return envtags
|
||||
}
|
||||
return "none"
|
||||
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue