capsman-download-packages: act in package-path only

This commit is contained in:
Christian Hesse 2018-12-27 21:40:12 +01:00
parent 0ecb0749fd
commit 1131d8ee41

View file

@ -10,10 +10,13 @@
:global CertificateAvailable;
:local "package-path" [ / caps-man manager get package-path ];
:if ([ :pick $"package-path" 0 ] = "/") do={
:set "package-path" [ :pick $"package-path" 1 [ :len $"package-path" ] ];
}
:local "installed-version" [ / system package update get installed-version ];
:local updated false;
:foreach package in=[ / file find where type=package ] do={
:foreach package in=[ / file find where type=package name~("^" . $"package-path") ] do={
:if ([ / file get $package package-version ] != $"installed-version") do={
:local "package-name" [ / file get $package package-name ];
:local "package-architecture" [ / file get $package package-architecture ];