From dbd8a9098ab2c16b88626029ff4e6d26037858cb Mon Sep 17 00:00:00 2001 From: John Gebbie Date: Wed, 28 Dec 2022 10:55:19 +0000 Subject: [PATCH] abort if any command-line arguments --- dotool.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/dotool.go b/dotool.go index 67f4c30..7fc0d1a 100644 --- a/dotool.go +++ b/dotool.go @@ -244,6 +244,9 @@ func main() { if err != nil { fatal(err.Error()) } + if len(optset.Args()) > 0 { + fatal("there should be no arguments, commands are read from stdin") + } } keyboard, err := uinput.CreateKeyboard("/dev/uinput", []byte("dotool keyboard"))