A tool for printing from notmuch

2011-01-29 Thread Sebastian Spaeth
On Sat, 29 Jan 2011 15:09:14 -0500, Jesse Rosenthal wrote: > So BS is the best I could find for this job No doubt. I once tried to scrape http://theeconomist.com. It has so broken html that all parsers broke down. BeautifulSoup at least made it through and didn't completely fail. so I agree it

A tool for printing from notmuch

2011-01-29 Thread Sebastian Spaeth
On Fri, 28 Jan 2011 15:25:28 -0500, Jesse Rosenthal wrote: > Dear all, > > Printing from notmuch is a bit of a pain. Hi Jesse, that sounds like a fantastic solution and I will look into it, so far I have been printing the buffers which does not include attachments at all. I prefer to not

A tool for printing from notmuch

2011-01-29 Thread Jesse Rosenthal
Hi Sebastian, On Sat, 29 Jan 2011 20:58:53 +0100, Sebastian Spaeth wrote: > I prefer to not have dependencies outside the std lib in python, but for > xml/html parsing, there is really nothing appropriate, it seems. I agree. And I'll admit I mainly chose BeautifulSoup out of familiarity. But

Re: A tool for printing from notmuch

2011-01-29 Thread Sebastian Spaeth
On Fri, 28 Jan 2011 15:25:28 -0500, Jesse Rosenthal jrosent...@jhu.edu wrote: Dear all, Printing from notmuch is a bit of a pain. Hi Jesse, that sounds like a fantastic solution and I will look into it, so far I have been printing the buffers which does not include attachments at all. I

A tool for printing from notmuch

2011-01-28 Thread Andreas Amann
On Fri, 28 Jan 2011 16:11:00 -0500, Jesse Rosenthal wrote: > > Hmm... looks like a problem with ConfigParser. Maybe the default values > aren't working well? > > Try setting up a ~/.notmuchprintrc: > > notmuch_command: "/usr/local/bin/notmuch" > browser_command: "/usr/bin/firefox" >

A tool for printing from notmuch

2011-01-28 Thread Andreas Amann
Dear Jesse, > Printing from notmuch is a bit of a pain. Muttprint doesn't really help > much, because it can't handle multiparts well, doesn't know what to do > with html, and will print out pages of base64 if you have > attachments. And more often than not, what I need to print is an HTML >

A tool for printing from notmuch

2011-01-28 Thread Jesse Rosenthal
On Fri, 28 Jan 2011 16:11:00 -0500, Jesse Rosenthal wrote: > Hmm... looks like a problem with ConfigParser. Maybe the default values > aren't working well? Yep, that was the problem. It turns out it doesn't take True and False as defaults -- needs strings ("yes", "no", "true", "false) or 1 or

A tool for printing from notmuch

2011-01-28 Thread Jesse Rosenthal
Hi Andreas, On Fri, 28 Jan 2011 20:59:06 +, Andreas Amann wrote: > Unfortunately I could not get it to work with python2.7: > > Traceback (most recent call last): > File "/home/amann/local/bin/notmuchprint", line 284, in > main(config) > File "/home/amann/local/bin/notmuchprint",

A tool for printing from notmuch

2011-01-28 Thread Jesse Rosenthal
Dear all, Printing from notmuch is a bit of a pain. Muttprint doesn't really help much, because it can't handle multiparts well, doesn't know what to do with html, and will print out pages of base64 if you have attachments. And more often than not, what I need to print is an HTML email (a bus

Re: A tool for printing from notmuch

2011-01-28 Thread Andreas Amann
Dear Jesse, Printing from notmuch is a bit of a pain. Muttprint doesn't really help much, because it can't handle multiparts well, doesn't know what to do with html, and will print out pages of base64 if you have attachments. And more often than not, what I need to print is an HTML email (a

Re: A tool for printing from notmuch

2011-01-28 Thread Jesse Rosenthal
Hi Andreas, On Fri, 28 Jan 2011 20:59:06 +, Andreas Amann a.am...@ucc.ie wrote: Unfortunately I could not get it to work with python2.7: Traceback (most recent call last): File /home/amann/local/bin/notmuchprint, line 284, in module main(config) File

Re: A tool for printing from notmuch

2011-01-28 Thread Jesse Rosenthal
On Fri, 28 Jan 2011 16:11:00 -0500, Jesse Rosenthal jrosent...@jhu.edu wrote: Hmm... looks like a problem with ConfigParser. Maybe the default values aren't working well? Yep, that was the problem. It turns out it doesn't take True and False as defaults -- needs strings (yes, no, true, false)

Re: A tool for printing from notmuch

2011-01-28 Thread Andreas Amann
On Fri, 28 Jan 2011 16:11:00 -0500, Jesse Rosenthal jrosent...@jhu.edu wrote: Hmm... looks like a problem with ConfigParser. Maybe the default values aren't working well? Try setting up a ~/.notmuchprintrc: notmuch_command: /usr/local/bin/notmuch browser_command: /usr/bin/firefox