Skip to content

Commit

Permalink
Add option for post-print delay
Browse files Browse the repository at this point in the history
  • Loading branch information
hjr265 committed Jan 26, 2023
1 parent d918935 commit 1037ca8
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 0 deletions.
2 changes: 2 additions & 0 deletions config.go
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ package main

import (
"os"
"time"

"github.com/BurntSushi/toml"
)
Expand All @@ -16,6 +17,7 @@ type Config struct {
MarginLeft float64
TabSize int
KeepPDF bool
DelayAfter time.Duration
}
Printer struct {
Name string
Expand Down
3 changes: 3 additions & 0 deletions main.go
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ import (
"context"
"flag"
"log"
"time"
)

var (
Expand Down Expand Up @@ -36,6 +37,8 @@ func main() {
err = markPrintDone(ctx, cfg, pr)
catch(err)
log.Printf(".. Done")

time.Sleep(cfg.Printd.DelayAfter)
}
}

Expand Down

0 comments on commit 1037ca8

Please sign in to comment.