exclude dot-prefixed files from footage scan
All checks were successful
/ build-linux-amd64 (push) Successful in 3m18s

This commit is contained in:
ari melody 2026-01-31 18:10:39 +00:00
parent c52290392d
commit 9f32aedc3b
Signed by: ari
GPG key ID: CF99829C92678188
2 changed files with 2 additions and 0 deletions

View file

@ -317,6 +317,7 @@ func main() {
log.Print("Video uploaded successfully!")
// update metadata to reflect VOD is uploaded
// TODO: rather than a boolean flag, link to actual video
metadata.Uploaded = true
err = scanner.WriteMetadata(directory, metadata)
if err != nil {

View file

@ -51,6 +51,7 @@ func ScanSegments(directory string, extension string) ([]string, error) {
for _, item := range entries {
if item.IsDir() { continue }
if strings.HasPrefix(item.Name(), ".") { continue }
if !strings.HasSuffix(item.Name(), "." + extension) { continue }
if strings.HasSuffix(item.Name(), "-fullvod." + extension) { continue }
files = append(files, item.Name())