]> Sergey Matveev's repositories - meta4ra.git/blobdiff - cmd/meta4ra/check.go
Prepare for release
[meta4ra.git] / cmd / meta4ra / check.go
index c030f8b8417ec376d2008ab8aed377efa43ac15e..c53ccb9f0e7c7768ada5c1ff2d8f92eeb49a39da 100644 (file)
@@ -50,6 +50,15 @@ and -extract-sig, then you can just specify an empty ("") FILE.
        }
        flag.Parse()
 
+       if *showVersion {
+               fmt.Println(meta4ra.Version())
+               return
+       }
+       if *showWarranty {
+               fmt.Println(meta4ra.Warranty)
+               return
+       }
+
        data, err := os.ReadFile(*metaPath)
        if err != nil {
                log.Fatalln(err)
@@ -216,8 +225,10 @@ and -extract-sig, then you can just specify an empty ("") FILE.
                }
        }
        if len(toCheck) != 0 {
-               fmt.Println("not all FILEs met")
-               bad = true
+               if _, ok := toCheck["."]; !(len(toCheck) == 1 && ok) {
+                       fmt.Println("not all FILEs met")
+                       bad = true
+               }
        }
        if bad {
                os.Exit(1)