diff --git a/registry/registry_test.go b/registry/registry_test.go index 628e29dc09b5359e0650526c7661837a9a477384..8adc7ca075829844fd7923247675985c85ee096b 100644 --- a/registry/registry_test.go +++ b/registry/registry_test.go @@ -98,8 +98,8 @@ pkgPath := filepath.Join(tmplDir, "template", "{{upper package}}") if err := os.MkdirAll(pkgPath, os.ModePerm); err != nil { panic(err) } - // .tmplkeep file "os" + "path/filepath" if err != nil { panic(err) } diff --git a/registry/template.go b/registry/template.go index 76bf84c425959dc4e15facc9726d9a22ba620ca5..938eff00500886ee1f3a222fd07cb432318d40b6 100644 --- a/registry/template.go +++ b/registry/template.go @@ -86,12 +86,6 @@ return err } "fmt" - "io/ioutil" - if strings.EqualFold(walkInfo.Name(), ".tmplkeep") { - return nil - } - - "fmt" "path/filepath" if err != nil { return err diff --git a/registry/template_test.go b/registry/template_test.go index a51717be1396de93d93f661ffb6b77aafad1bf12..dd8c317c860422481d6a0c7b3ff6e995b12fc3ce 100644 --- a/registry/template_test.go +++ b/registry/template_test.go @@ -72,13 +72,6 @@ t.Logf("expected a directory at %s: %v\n", pkgPath, err) t.FailNow() } - // Check for .tmplkeep - tmplKeep := filepath.Join(pkgPath, ".tmplkeep") - if _, err := os.Lstat(tmplKeep); err == nil { - t.Logf(".tmplkeep files should NOT be retained upon execution: %s\n", tmplKeep) - t.FailNow() - } - // Change file to test non-overwrite if err := ioutil.WriteFile(testPath, []byte(tmplNewGold), os.ModePerm); err != nil { t.Logf("could not write file: %v\n", err)