mirror of
https://github.com/tiennm99/hugoDocs.git
synced 2026-10-13 14:16:06 +00:00
adding more verbose output to server functionality
This commit is contained in:
1 parent
b2385f062a
commit
c560a7537a
1 file changed
+5
@@ -112,6 +112,11 @@ func main() {
|
||||
}
|
||||
|
||||
func serve(port string, config *hugolib.Config) {
|
||||
|
||||
if config.Verbose {
|
||||
fmt.Println("Serving pages from " + config.GetAbsPath(config.PublishDir))
|
||||
}
|
||||
|
||||
fmt.Println("Web Server is available at http://localhost:" + port)
|
||||
fmt.Println("Press ctrl+c to stop")
|
||||
panic(http.ListenAndServe(":"+port, http.FileServer(http.Dir(config.PublishDir))))
|
||||
|
||||
Reference in new issue
Block a user