X-Git-Url: https://pd.if.org/git/?a=blobdiff_plain;f=zpm-pkginfo;h=ff55481c27e4022e66cd80caaabe6d1e9189c7b9;hb=be765ec4d3dc14dd27826326e29da8a62d5603f7;hp=3be0e03afc31389643de272ccd6f7235034bf392;hpb=95c91056eb1fea49f96dcc2b1c5b91930e0b960a;p=zpackage diff --git a/zpm-pkginfo b/zpm-pkginfo index 3be0e03..ff55481 100755 --- a/zpm-pkginfo +++ b/zpm-pkginfo @@ -34,7 +34,7 @@ if [ -z "$pkgfile" ]; then fi zpm-test -v $pkgfile -pkg=$(zpm-findpkg $pkgfile) +pkg=$(zpm-findpkg -f $pkgfile) #.mode line { @@ -62,24 +62,26 @@ EOS #mode user group hash mtime csvtags path -sqlite3 $pkgfile <<-EOS -.header on +zpm shell $pkgfile <<-EOS +.header off select - printf('%s %s %s %s %s %s', + printf('%s %s %s %s %s %s %s', F.mode, F.username, F.groupname, case when F.filetype = 'c' then F.devmajor || ',' || F.devminor + when F.filetype = 'd' then + 'directory' else F.hash end ,strftime('%Y-%m-%dT%H:%M:%S', F.mtime, 'unixepoch') - , T.tags + , coalesce(T.tags, '-') ,F.path) from packagefiles as F left join ( select TG.package, TG.version, TG.release, TG.path - ,coalesce(group_concat(tag), '-') as tags - from packagefiletags TG + ,group_concat(tag) as tags + from pathtags TG group by package, version, release, path ) T on T.package = F.package and T.version = F.version and T.release = F.release