fix: ignore "env" files which don't end in .env
This commit is contained in:
parent
10b15d65b4
commit
49781c7e3f
|
@ -73,6 +73,11 @@ func getAllFilesInDirectory(directory string) ([]fs.FileInfo, error) {
|
||||||
for _, file := range files {
|
for _, file := range files {
|
||||||
// Follow any symlinks
|
// Follow any symlinks
|
||||||
filePath := path.Join(directory, file.Name())
|
filePath := path.Join(directory, file.Name())
|
||||||
|
|
||||||
|
if filepath.Ext(strings.TrimSpace(filePath)) != ".env" {
|
||||||
|
continue
|
||||||
|
}
|
||||||
|
|
||||||
realPath, err := filepath.EvalSymlinks(filePath)
|
realPath, err := filepath.EvalSymlinks(filePath)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
logrus.Warningf("broken symlink in your abra config folders: '%s'", filePath)
|
logrus.Warningf("broken symlink in your abra config folders: '%s'", filePath)
|
||||||
|
|
Loading…
Reference in New Issue