From 4b65d05dcc20f792249d55151da34ebc3c2c15f3 Mon Sep 17 00:00:00 2001 From: jolheiser Date: Mon, 30 Jan 2023 22:07:36 -0600 Subject: [PATCH] fix: correct if-logic for update Signed-off-by: jolheiser --- main.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/main.go b/main.go index f5abb65..121bc40 100644 --- a/main.go +++ b/main.go @@ -56,15 +56,15 @@ func main() { } uri := fs.Arg(0) - if strings.Index(uri, "/") != -1 { + if strings.Index(uri, "/") == -1 { if !*updateFlag { - fmt.Println("provided arg must be a URI, unless using --update") + fmt.Printf("%q was not a URI and --update was not passed\n", uri) return } pkg, ok := m.Packages[uri] if !ok { - fmt.Println("arg was not a URI and didn't match an installed package") + fmt.Printf("%q was not a URI and didn't match an installed package\n", uri) return } uri = pkg.Repo