From 4de4096004cc1c403a13358356d32598063bdc77 Mon Sep 17 00:00:00 2001 From: sh0rez Date: Tue, 29 Oct 2019 22:35:59 +0100 Subject: [PATCH] fix: fail on invalid URI --- cmd/jb/install.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/cmd/jb/install.go b/cmd/jb/install.go index 7fcb7e2..7d64b6f 100644 --- a/cmd/jb/install.go +++ b/cmd/jb/install.go @@ -48,6 +48,9 @@ func installCommand(dir, jsonnetHome string, uris []string) int { for _, u := range uris { d := parseDependency(dir, u) + if d == nil { + kingpin.Fatalf("Unable to parse package URI `%s`", u) + } if !depEqual(jsonnetFile.Dependencies[d.Name], *d) { // the dep passed on the cli is different from the jsonnetFile