summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rwxr-xr-xaports.lua10
1 files changed, 10 insertions, 0 deletions
diff --git a/aports.lua b/aports.lua
index 87b4cf7..3f7e9ae 100755
--- a/aports.lua
+++ b/aports.lua
@@ -207,6 +207,16 @@ function Aports:foreach_pkg(pkg, f)
end
end
+function Aports:foreach_aport(f)
+ self:foreach(function(pkgname)
+ self:foreach_pkg(pkgname, function(i, pkg)
+ if pkgname == pkg.pkgname then
+ f(pkg)
+ end
+ end)
+ end)
+end
+
function new(repodirs)
local h = Aports
h.repodirs = repodirs