diff options
Diffstat (limited to 'cmd/booktopipeline/main.go')
-rw-r--r-- | cmd/booktopipeline/main.go | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/cmd/booktopipeline/main.go b/cmd/booktopipeline/main.go index b4f4d99..bf088a0 100644 --- a/cmd/booktopipeline/main.go +++ b/cmd/booktopipeline/main.go @@ -7,6 +7,7 @@ package main import ( + "context" "flag" "fmt" "log" @@ -65,6 +66,8 @@ func main() { bookname = filepath.Base(bookdir) } + var ctx context.Context + if *verbose { verboselog = log.New(os.Stdout, "", log.LstdFlags) } else { @@ -97,7 +100,7 @@ func main() { } verboselog.Println("Checking that all images are valid in", bookdir) - err = pipeline.CheckImages(bookdir) + err = pipeline.CheckImages(ctx, bookdir) if err != nil { log.Fatalln(err) } @@ -112,7 +115,7 @@ func main() { } verboselog.Println("Uploading all images are valid in", bookdir) - err = pipeline.UploadImages(bookdir, bookname, conn) + err = pipeline.UploadImages(ctx, bookdir, bookname, conn) if err != nil { log.Fatalln(err) } |