diff --git a/.db/complete b/.db/complete new file mode 100755 index 0000000..e69de29 diff --git a/.gitignore b/.gitignore index 86efe73..b00c912 100644 --- a/.gitignore +++ b/.gitignore @@ -1,2 +1,3 @@ podcasts.toml db/* +podcatch-bin diff --git a/podcatch/podcatch.go b/podcatch/podcatch.go index daec87e..236fe26 100644 --- a/podcatch/podcatch.go +++ b/podcatch/podcatch.go @@ -102,7 +102,7 @@ func downloadCasts(podcast Podcast) { } func podcastDownloaded(item Item) bool { if len(donefile) < 1 { - content, err := ioutil.ReadFile("db/complete") + content, err := ioutil.ReadFile(".db/complete") if err != nil { log.Fatal(err) } @@ -150,7 +150,7 @@ func createNFO(item Item, file string) { } } func markAsReceived(item Item) { - file, err := os.OpenFile("db/complete", os.O_APPEND|os.O_CREATE|os.O_WRONLY, 0755) + file, err := os.OpenFile(".db/complete", os.O_APPEND|os.O_CREATE|os.O_WRONLY, 0755) if err != nil { log.Println(err) } @@ -161,7 +161,7 @@ func markAsReceived(item Item) { } } func markAsErrored(item Item) { - file, err := os.OpenFile("db/error", os.O_APPEND|os.O_CREATE|os.O_WRONLY, 0755) + file, err := os.OpenFile(".db/error", os.O_APPEND|os.O_CREATE|os.O_WRONLY, 0755) if err != nil { log.Println(err) }