Skip "dot" files in layout

As a vim user, .filename.swp files pop up.  This change prevents hugo
from reading those files.
This commit is contained in:
Noah Campbell committed 2013-08-23 13:58:52 -07:00
1 parent eb4288e3cd
commit ae7112977d
1 file changed
+3
+3
View File
@@ -163,6 +163,9 @@ func (s *Site) loadTemplates() {
}
if !fi.IsDir() {
if ignoreDotFile(path) {
return nil
}
filetext, err := ioutil.ReadFile(path)
if err != nil {
return err