diff options
| author | Paul Buetow <paul@buetow.org> | 2024-11-08 22:52:31 +0200 |
|---|---|---|
| committer | Paul Buetow <paul@buetow.org> | 2024-11-08 22:52:31 +0200 |
| commit | 9b14c12e0ccd5c96dd9f17d1b20fe134308d2184 (patch) | |
| tree | ff60a38c88686962a188ccabdbd4eda37e7e28f5 /cmd | |
| parent | 7a63e78baf3fe9f769ad4a0569baf8ca71363cfe (diff) | |
refactor
Diffstat (limited to 'cmd')
| -rw-r--r-- | cmd/gos/main.go | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/cmd/gos/main.go b/cmd/gos/main.go index 774dd13..ee7aae7 100644 --- a/cmd/gos/main.go +++ b/cmd/gos/main.go @@ -19,11 +19,10 @@ func main() { dry := flag.Bool("dry", false, "Dry run") version := flag.Bool("version", false, "Display version") gosDir := flag.String("gosDir", filepath.Join(os.Getenv("HOME"), ".gosdir"), "Gos' queue and DB directory") + cacheDir := flag.String("cacheDir", filepath.Join(*gosDir, "cache"), "Go's cache dir") browser := flag.String("browser", "firefox", "OAuth2 browser") secretsConfigPath := filepath.Join(os.Getenv("HOME"), ".config/gos/gosec.json") secretsConfigPath = *flag.String("secretsConfig", secretsConfigPath, "Gos' secret config") - cacheDir := filepath.Join(os.Getenv("HOME"), ".config/gos/cache") - cacheDir = *flag.String("cacheDir", cacheDir, "Go's cache dir") platforms := flag.String("platforms", "Mastodon:500,LinkedIn:1000", "Platforms enabled plus their post size limits") target := flag.Int("target", 2, "How many posts per week are the target?") minQueued := flag.Int("minQueued", 4, "Minimum of queued items until printing a warn message!") @@ -47,7 +46,7 @@ func main() { PauseDays: *pauseDays, Lookback: time.Duration(*lookback) * time.Hour * 24, SecretsConfigPath: secretsConfigPath, - CacheDir: cacheDir, + CacheDir: *cacheDir, Secrets: secrets, OAuth2Browser: *browser, } |
