The following command otherwise yields many blank lines:
authorAndreas Oberritter <obi@opendreambox.org>
Thu, 28 Aug 2014 22:04:20 +0000 (15:04 -0700)
committerMichael Vogt <mvo@debian.org>
Thu, 28 Aug 2014 22:04:20 +0000 (15:04 -0700)
apt list -o APT::Cmd::use-format=true -o APT::Cmd::format=\${Package}

And even worse when adding "-o APT::Cmd::All-Versions=true".

Signed-off-by: Andreas Oberritter <obi@opendreambox.org>
apt-private/private-list.cc

index b690021..f984565 100644 (file)
@@ -93,7 +93,6 @@ static void ListAllVersions(pkgCacheFile &CacheFile, pkgRecords &records,/*{{{*/
         Ver.end() == false; ++Ver)
    {
       ListSingleVersion(CacheFile, records, Ver, outs, include_summary);
-      outs << "\n";
    }
 }
                                                                        /*}}}*/
@@ -149,7 +148,7 @@ bool DoList(CommandLine &Cmd)
    // FIXME: SORT! and make sorting flexible (alphabetic, by pkg status)
    // output the sorted map
    for (K = output_map.begin(); K != output_map.end(); ++K)
-      std::cout << (*K).second << std::endl;
+      std::cout << (*K).second;
 
 
    // be nice and tell the user if there is more to see