diff options
author | 2013-09-05 18:32:18 +0200 | |
---|---|---|
committer | 2013-09-05 18:32:18 +0200 | |
commit | e99bc52284ede1cc43189b5ac8ac905cf8f5e64f (patch) | |
tree | 303df8773622b9ebd8a9b65f5b828527bddd33ce /gs_db_tool | |
parent | variables without quotation in ebuild-generator (diff) | |
download | g-sorcery-e99bc52284ede1cc43189b5ac8ac905cf8f5e64f.tar.gz g-sorcery-e99bc52284ede1cc43189b5ac8ac905cf8f5e64f.tar.bz2 g-sorcery-e99bc52284ede1cc43189b5ac8ac905cf8f5e64f.zip |
gs_db_tool/gs_db_tool: pass package to lambda
Diffstat (limited to 'gs_db_tool')
-rw-r--r-- | gs_db_tool/gs_db_tool.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/gs_db_tool/gs_db_tool.py b/gs_db_tool/gs_db_tool.py index 5594a12..1b58cee 100644 --- a/gs_db_tool/gs_db_tool.py +++ b/gs_db_tool/gs_db_tool.py @@ -83,10 +83,10 @@ def add_var(pkg_db, args): pkg_db.add_package(package, ebuild_data) elif args.lambda_function: - lmbd = "lambda ebuild_data: " + args.lambda_function + lmbd = "lambda package, ebuild_data: " + args.lambda_function f = eval(lmbd) for package, ebuild_data in pkg_db: - value = f(ebuild_data) + value = f(package, ebuild_data) ebuild_data[args.name] = value pkg_db.add_package(package, ebuild_data) |