From d3fc506c2bc2b38b306162c9beefcc45c3a7063b Mon Sep 17 00:00:00 2001 From: Panu Matilainen Date: Tue, 27 Nov 2007 13:00:47 +0200 Subject: [PATCH] Make default queryformat show epoch if present --- lib/query.c | 2 +- macros.in | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/query.c b/lib/query.c index 6f10579..9e22912 100644 --- a/lib/query.c +++ b/lib/query.c @@ -776,7 +776,7 @@ int rpmcliQuery(rpmts ts, QVA_t qva, const char ** argv) qva->qva_queryFormat = rpmExpand("%{?_query_all_fmt}\n", NULL); if (!(qva->qva_queryFormat != NULL && *qva->qva_queryFormat != '\0')) { qva->qva_queryFormat = _free(qva->qva_queryFormat); - qva->qva_queryFormat = xstrdup("%{name}-%{version}-%{release}.%{arch}\n"); + qva->qva_queryFormat = xstrdup("%{name}-%|epoch?{%{epoch}:}|%{version}-%{release}.%{arch}\n"); } } diff --git a/macros.in b/macros.in index 19de05c..ae70a4a 100644 --- a/macros.in +++ b/macros.in @@ -794,7 +794,7 @@ print (t)\ # Default headerSprintf() output format string for rpm -qa # # XXX Note: escaped %% for use in headerSprintf() -%_query_all_fmt %%{name}-%%{version}-%%{release}.%%{arch} +%_query_all_fmt %%{name}-%%|epoch?{%%{epoch}:}|%%{version}-%%{release}.%%{arch} # # Default path to the file used for transaction fcmtl lock. -- 2.7.4