Bugfix when no input file specified

This commit is contained in:
yo 2023-09-11 16:14:33 +02:00
parent 9b849fad3a
commit a1892cbe37

View File

@ -33,7 +33,7 @@ import (
)
const (
version = "0.6"
version = "0.6.1"
)
var (
@ -84,6 +84,10 @@ func main() {
}
args := os.Args
if len(os.Args) < 2 {
pflag.Usage()
os.Exit(1)
}
filename := args[len(args)-1]
var f *os.File