Documentation
¶
Overview ¶
Package commands define command-line interface for Hoor, current implementation is based on the Cobra package.
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var HoorCmd = &cobra.Command{ Use: "hoor", Short: "Add Shamsi date to Hugo based websites with ease", Run: func(cmd *cobra.Command, args []string) { startTime = time.Now() if debugMode { jww.SetStdoutThreshold(jww.LevelTrace) } if err := defineWorkingDir(); err != nil { return } if err := hugolib.LoadGlobalConfig(sourcePath, cfgFile); err != nil { jww.ERROR.Println("Cannot find configurations file") jww.DEBUG.Println(err) return } site, err := loadHugoSite() if err != nil { return } if input != "" { applyToFile(input) return } applyToSite(site) }, }
HoorCmd represents the base command when called without any subcommands.
Functions ¶
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.