Package: apt-listchanges
Severity: wishlist
Tags: patch

I'd like to use less's "lesspipe" mechanism to improve the formatting of
apt-listchanges changelogs.  However, the temporary files
apt-listchanges feeds to less have names like /tmp/tmpXXXXXX , which
doesn't identify them as belonging to apt-listchanges.  Please consider
using an appropriate prefix on these files, to make them easily
identifiable.  The following patch will do that:

diff --git a/apt-listchanges/apt_listchanges.py 
b/apt-listchanges/apt_listchanges.py
index b03124d..180a3dc 100644
--- a/apt-listchanges/apt_listchanges.py
+++ b/apt-listchanges/apt_listchanges.py
@@ -231,7 +231,7 @@ class runcommand:
             if os.fork() != 0:
                 return
 
-        tmp = tempfile.NamedTemporaryFile(suffix=self.suffix)
+        tmp = tempfile.NamedTemporaryFile(prefix="apt-listchanges-tmp", 
suffix=self.suffix)
         tmp.write(self._render(text))
         tmp.flush()
         shellcommand = self.get_command() + ' ' + tmp.name



-- 
To UNSUBSCRIBE, email to [email protected]
with a subject of "unsubscribe". Trouble? Contact [email protected]

Reply via email to