yay
commit
ad83263c91
|
|
@ -0,0 +1,2 @@
|
|||
**/*.sw*
|
||||
/timer
|
||||
|
|
@ -0,0 +1,10 @@
|
|||
module gitea.inhome.blapointe.com/bel/timer
|
||||
|
||||
go 1.22.3
|
||||
|
||||
require (
|
||||
github.com/deckarep/gosx-notifier v0.0.0-20180201035817-e127226297fb // indirect
|
||||
github.com/martinlindhe/notify v0.0.0-20181008203735-20632c9a275a // indirect
|
||||
github.com/nu7hatch/gouuid v0.0.0-20131221200532-179d4d0c4d8d // indirect
|
||||
gopkg.in/toast.v1 v1.0.0-20180812000517-0a84660828b2 // indirect
|
||||
)
|
||||
|
|
@ -0,0 +1,8 @@
|
|||
github.com/deckarep/gosx-notifier v0.0.0-20180201035817-e127226297fb h1:6S+TKObz6+Io2c8IOkcbK4Sz7nj6RpEVU7TkvmsZZcw=
|
||||
github.com/deckarep/gosx-notifier v0.0.0-20180201035817-e127226297fb/go.mod h1:wf3nKtOnQqCp7kp9xB7hHnNlZ6m3NoiOxjrB9hFRq4Y=
|
||||
github.com/martinlindhe/notify v0.0.0-20181008203735-20632c9a275a h1:nQcAxLK581HrmqF0TVy2GC3iFjB8X+aWGtxQ/t2uyGE=
|
||||
github.com/martinlindhe/notify v0.0.0-20181008203735-20632c9a275a/go.mod h1:zL1p4SieQ27ZZ4V4KdVYdEcSkVl1OwNoi8xI1r5hJkc=
|
||||
github.com/nu7hatch/gouuid v0.0.0-20131221200532-179d4d0c4d8d h1:VhgPp6v9qf9Agr/56bj7Y/xa04UccTW04VP0Qed4vnQ=
|
||||
github.com/nu7hatch/gouuid v0.0.0-20131221200532-179d4d0c4d8d/go.mod h1:YUTz3bUH2ZwIWBy3CJBeOBEugqcmXREj14T+iG/4k4U=
|
||||
gopkg.in/toast.v1 v1.0.0-20180812000517-0a84660828b2 h1:MZF6J7CV6s/h0HBkfqebrYfKCVEo5iN+wzE4QhV3Evo=
|
||||
gopkg.in/toast.v1 v1.0.0-20180812000517-0a84660828b2/go.mod h1:s1Sn2yZos05Qfs7NKt867Xe18emOmtsO3eAKbDaon0o=
|
||||
|
|
@ -0,0 +1,18 @@
|
|||
package main
|
||||
|
||||
import (
|
||||
"os"
|
||||
"time"
|
||||
|
||||
"github.com/martinlindhe/notify"
|
||||
)
|
||||
|
||||
func main() {
|
||||
d, err := time.ParseDuration(os.Args[1])
|
||||
if err != nil {
|
||||
panic(err)
|
||||
}
|
||||
time.Sleep(d)
|
||||
msg := "alerting after " + d.String()
|
||||
notify.Alert(os.Args[0], msg, msg, "/dev/null")
|
||||
}
|
||||
Loading…
Reference in New Issue