From c439dc2661ebc48b5fee76f06afd07c187eba860 Mon Sep 17 00:00:00 2001 From: Justin Davis Date: Thu, 29 Dec 2011 16:45:04 -0500 Subject: Relocate pkgverfmt logic in pbfields. --- lib/templ/pbfields | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'lib/templ') diff --git a/lib/templ/pbfields b/lib/templ/pbfields index 18155a0..5e7844c 100755 --- a/lib/templ/pbfields +++ b/lib/templ/pbfields @@ -38,6 +38,10 @@ arrfield[$1] { } END { + if(pkgverfmt){ + output["pkgver"] = sprintf(pkgverfmt, output["pkgver"]) + } + if(!maintainer && !packager) { packager = "Anonymous" } if(maintainer) print "# Maintainer: " maintainer else if(packager) print "# Packager: " packager @@ -47,9 +51,6 @@ END { for(i=1; i<=max; i++){ name = fields[i] if(name in output){ - if(name == "pkgver" && pkgverfmt){ - output["pkgver"] = sprintf(pkgverfmt, output["pkgver"]) - } print name, output[name] } } -- cgit v1.2.3-24-g4f1b