From: Tatsushi Demachi Date: Sat, 6 Sep 2014 01:38:36 +0000 (+0900) Subject: More error messages at syncing static contents X-Git-Tag: v0.13~420 X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=d9964451;p=brevno-suite%2Fhugo More error messages at syncing static contents --- diff --git a/commands/hugo.go b/commands/hugo.go index a35a1f00..e95b0c0d 100644 --- a/commands/hugo.go +++ b/commands/hugo.go @@ -229,7 +229,7 @@ func copyStatic() error { // Copy Static to Destination jww.INFO.Println("syncing from", themeDir, "to", publishDir) - fsync.Sync(publishDir, themeDir) + utils.CheckErr(fsync.Sync(publishDir, themeDir), fmt.Sprintf("Error copying static files of theme to %s", publishDir)) } // Copy Static to Destination diff --git a/utils/utils.go b/utils/utils.go index df54737f..eaa6c09a 100644 --- a/utils/utils.go +++ b/utils/utils.go @@ -15,6 +15,7 @@ func CheckErr(err error, s ...string) { for _, message := range s { jww.ERROR.Println(message) } + jww.ERROR.Println(err) } } }