From 24868c0abc1111aa88fd9dbe34aeb413b3cb5868 Mon Sep 17 00:00:00 2001 From: kekskurse Date: Mon, 4 Aug 2025 01:05:50 +0200 Subject: [PATCH] chore: Ignore hidden folders and files --- pkg/wikipress/git.go | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/pkg/wikipress/git.go b/pkg/wikipress/git.go index 31dc48b..5350892 100644 --- a/pkg/wikipress/git.go +++ b/pkg/wikipress/git.go @@ -19,6 +19,9 @@ func ListFilesFromHDD(opath string) ([]File, error) { if err != nil { return err // z.B. fehlende Leserechte } + if strings.HasPrefix(info.Name(), ".") { + return nil + } if !info.IsDir() { v := Version{} @@ -37,6 +40,10 @@ func ListFilesFromHDD(opath string) ([]File, error) { f.Name = strings.TrimPrefix(path, opath) f.Versions = append(f.Versions, v) + if strings.HasPrefix(f.Name, ".") { + return nil + } + FileList = append(FileList, f) }