summaryrefslogtreecommitdiff
path: root/args/args.go
diff options
context:
space:
mode:
Diffstat (limited to 'args/args.go')
-rw-r--r--args/args.go3
1 files changed, 3 insertions, 0 deletions
diff --git a/args/args.go b/args/args.go
index a360d57..64dee35 100644
--- a/args/args.go
+++ b/args/args.go
@@ -18,6 +18,7 @@ type Arguments struct {
Port int
Server bool
Migrate bool
+ Scheduler bool
OauthConfig *oauth2.Config
OauthUserInfoURI string
@@ -28,6 +29,7 @@ func GetArgs() (*Arguments, error) {
databasePath := flag.String("database-path", "./hatecomputers.db", "Path to the SQLite database")
templatePath := flag.String("template-path", "./templates", "Path to the template directory")
staticPath := flag.String("static-path", "./static", "Path to the static directory")
+ scheduler := flag.Bool("scheduler", false, "Run scheduled jobs via cron")
server := flag.Bool("server", false, "Run the server")
migrate := flag.Bool("migrate", false, "Run the migrations")
@@ -83,6 +85,7 @@ func GetArgs() (*Arguments, error) {
Port: *port,
Server: *server,
Migrate: *migrate,
+ Scheduler: *scheduler,
OauthConfig: oauthConfig,
OauthUserInfoURI: oauthUserInfoURI,