From 9d68556f0ea9fa451510060f6dc24495f1b1ec21 Mon Sep 17 00:00:00 2001 From: Julien Dessaux Date: Thu, 29 Feb 2024 23:55:01 +0100 Subject: fix(stdlib): fixed apt package promises The installed packages list failed to recognise packages when the architecture name is part of the package's name --- stdlib/os/debian/apt.go | 3 +++ 1 file changed, 3 insertions(+) (limited to 'stdlib/os') diff --git a/stdlib/os/debian/apt.go b/stdlib/os/debian/apt.go index 2eb58fa..848294b 100644 --- a/stdlib/os/debian/apt.go +++ b/stdlib/os/debian/apt.go @@ -64,6 +64,9 @@ func packages_list() { slog.Error("dpkg-query", "error", "parsing error: no version after name") os.Exit(1) } + if strings.Contains(name, ":") { // some packages are named with the arch like something:amd64 + name = strings.Split(name, ":")[0] // in this case we want only the name + } packages[name] = s.Text() } } -- cgit v1.2.3