Re: time

2010-01-06 Thread Ravi Uday
Yes I did it.
On the linux server where i run mutt :

bash-3.00$ date
Wed Jan  6 08:44:40 IST 2010

Now from within mutt, if I check a recent mail's header, I see this :
..
Date: Wed, 6 Jan 2010 00:44:27 -0800
..

I just have
export TZ=IST
in my .bashrc.

Both the dates(from bash and from within mutt) are wrong
when I see from my windows m/c.
It rightly shows - Jan-6-2010 2:15 PM ! whichis the correct time now


- Ravi



On Wed, Jan 6, 2010 at 1:27 PM, Patrick Ben Koetter  
wrote:
> * Ravi Uday :
>> Kyle,
>>
>> This didn't work.
>>
>> The mail header shows :
>>
>> Date: Tue, 5 Jan 2010 21:59:44 -0800
>>
>> but my laptop's time is : Jan-6th-2010 11:38 AM.
>
> Did you source the ~/.bashrc after editing it?
>
> p...@rick
>
>
>
>>
>> - Ravi
>>
>> On Tue, Jan 5, 2010 at 11:50 PM, Kyle Wheeler  
>> wrote:
>> > -BEGIN PGP SIGNED MESSAGE-
>> > Hash: SHA256
>> >
>> > On Tuesday, January  5 at 11:42 PM, quoth Ravi Uday:
>> >>Hi,
>> >>
>> >>how to change the date and time format from
>> >>PST to IndianStandardTime (IST) in .muttrc
>> >
>> > Add this to your ~/.bashrc:
>> >
>> >     export TZ=IST
>> >
>> > ~Kyle
>> > - --
>> > However many holy words you read, However many you speak, what good
>> > will they do you If you do not act on upon them?
>> >                                                              -- Buddha
>> > -BEGIN PGP SIGNATURE-
>> > Comment: Thank you for using encryption!
>> >
>> > iQIcBAEBCAAGBQJLQ4MBAAoJECuveozR/AWeg+4P/iuYmERmpA5Bz5Be6abU1/6l
>> > 3I/CzVLamlSKfWvPeXvalTBYZKv9nHb4Hqw3U8tmoVC926aLjl5bfb38dbrHmQ/j
>> > DtJE9xkOS7wNU+T13l4p3IrZaCPua3Ld0YP6nzvWrRpnlJXgxbJsDn/3tTlR8VZ4
>> > /bGGwOq9Co31wskN0q5HYHs5wUrrmb8j4FMFur+7iOScRkvU0t+9ltDYxdSN84YT
>> > YAhmZ8NIpm0r9RWQniREwqP2/oZiVqhoqEVbBbte2BGEajy/0oOJLVZ471j8fSYy
>> > E42xYVSU7sEMKQfIUG4P84Wkw7COszL+LR0iLw0XphIzYeGx5X6Z6EnArqINIBa8
>> > T3EUiovCW5PRCraW+LOCOWKkD2GrDCwyfmXs3x25sw2YgnE/keskEt3kYNmwSjCu
>> > HdNG2iRsGh6kOYvgWmfgBXFl7hd37aSRq18B5pijMw69aIBjKdORy3jy1TpNamst
>> > AtZ+TuSgL8OecRXPYPCMZJPxmRo7mk5BQUFRMm+U8xaeF2uXYfbs2/y48LpSnaD5
>> > zILkjzIw8r04cRo1JEehMjETozo0BOj7JCESmw6KDpMXKrcLUJ1taZbkDkYc/R9b
>> > lkO0Ri/LNud132CuTL+VL3l9YNNHDocSAKWCdBlCznT5l0mH4iXGqCtakCx2BKM1
>> > c4KCEjULj82nyvEfHfFc
>> > =WlUG
>> > -END PGP SIGNATURE-
>> >
>
> --
> Postfix - Einrichtung, Betrieb und Wartung
> 
> saslfinger (debugging SMTP AUTH):
> 
>


Attach local files when displaying remotely

2010-01-06 Thread steve
Hi,

At work, I use mutt via a ssh tunnel (with putty). So mutt is running on
my home server (Debian). Sometimes I need to attach files located not on
my (remote) server but on my local windows box. So what I do is to send
myself the files using my work's email account, save it on the remote
server and then attach them in mutt; not the best solution but it works.

I'd like to know if it's possible to attach files directly from the
local machine.

Thank you for your help,
steve  


Problems with a2ps/enscript and printing in mutt

2010-01-06 Thread Joseph Ishac
I'm looking to adjust the way mutt prints.  I had just been piping
things to lpr, but I decided to try and get a little fancier.

So I tried the following two commands:

set print_command="enscript -Email --word-wrap -r -t %s -G -2"

and

set print_command="a2ps -=mail -2"

a2ps works nicely, and the header is nice... unfortunately there is no
word wrap, so things fold mid-word and makes reading the mail difficult.
Enscript does proper word wraps but doesn't generate a useful title.

Since print_decode is set, mutt is parsing the message before piping it.
I was wondering if there is a way to have mutt hand me the subject of
the message so that I could pass it to the -t option of enscript to
formulate a title.

Thanks,

-Joseph


Re: Attach local files when displaying remotely

2010-01-06 Thread Cameron Simpson
On 06Jan2010 10:36, steve  wrote:
| At work, I use mutt via a ssh tunnel (with putty). So mutt is running on
| my home server (Debian). Sometimes I need to attach files located not on
| my (remote) server but on my local windows box. So what I do is to send
| myself the files using my work's email account, save it on the remote
| server and then attach them in mutt; not the best solution but it works.

Might it not be more direct to scp the files?

| I'd like to know if it's possible to attach files directly from the
| local machine.

Not as far as I know. I'd be inclined to have a directory at work with
"files for home". Copy the needed files and push an rsync button to push
everything to home as needed. Cumbersome, I know.

Hmm, what if you tunnels your won't machine's files as a samba mount for
home? Maybe using automount to attach it at need. Forward your local 139
(I think) to 139 at the far (home) end. Then you can smbmount the work
windows files somewhere on your home machine for direct access by mutt.
If sort all that out you could maybe configure the automounter to mount
at need and unmount when idle, perhaps avoiding some pain.

Cheers,
-- 
Cameron Simpson  DoD#743
http://www.cskk.ezoshosting.com/cs/

Question Authority and the Authorities will question You.


Re: Attach local files when displaying remotely

2010-01-06 Thread Toby Cubitt
On 06Jan2010 10:36, steve  wrote:
> At work, I use mutt via a ssh tunnel (with putty). So mutt is running on
> my home server (Debian). Sometimes I need to attach files located not on
> my (remote) server but on my local windows box. So what I do is to send
> myself the files using my work's email account, save it on the remote
> server and then attach them in mutt; not the best solution but it works.
>
> I'd like to know if it's possible to attach files directly from the
> local machine.

Since you're already using ssh tunnels, you could try using the sshfs
filesystem to mount your windows directories remotely on your server.
sshfs is available for Debian, and I believe it should be able to mount
directories hosted on a windows system just as easily as anything else.

Of course, for this to work you'd have to run an ssh server on your
*windows* box (and it would have to be visible over the network from your
server). But running an ssh server on your windows box might be a bit
easier than setting up a sambda share.

HTH,

Toby
--
Dr T. S. Cubitt
Quantum Information Theory group
Department of Mathematics
University of Bristol
United Kingdom

email: ts...@cantab.net
web: www.dr-qubit.org


Re: Attach local files when displaying remotely

2010-01-06 Thread steve
Hi Cameron,

Thanks for your answer.


Le 06-01-2010, à 22:45:52 +1100, Cameron Simpson (c...@zip.com.au) a écrit :

> On 06Jan2010 10:36, steve  wrote:
> | At work, I use mutt via a ssh tunnel (with putty). So mutt is running on
> | my home server (Debian). Sometimes I need to attach files located not on
> | my (remote) server but on my local windows box. So what I do is to send
> | myself the files using my work's email account, save it on the remote
> | server and then attach them in mutt; not the best solution but it works.
> 
> Might it not be more direct to scp the files?

You mean scp to my recipient? Or to my home server? In the first case, I
don't see how it could simply be possible if the recipient doesn't have
a ssh server running on his/her machine. And in the second case, I
simply don't know how to do that from my windows box at work. Not
allowed to install anything, yet putty runs fine from a usb stick :)


> | I'd like to know if it's possible to attach files directly from the
> | local machine.
> 
> Not as far as I know. I'd be inclined to have a directory at work with
> "files for home". Copy the needed files and push an rsync button to push
> everything to home as needed. Cumbersome, I know.

Yep. And same problem than above I guess.

> Hmm, what if you tunnels your won't machine's files as a samba mount for
> home? Maybe using automount to attach it at need. Forward your local 139
> (I think) to 139 at the far (home) end. Then you can smbmount the work
> windows files somewhere on your home machine for direct access by mutt.
> If sort all that out you could maybe configure the automounter to mount
> at need and unmount when idle, perhaps avoiding some pain.

Well didn't think about that (I don't use Samba). Would it be difficult
to implement (and just possible from work)? 

I'll have to think about it.

Does anyone have another idea?


Thanks,
steve



Re: Attach local files when displaying remotely

2010-01-06 Thread steve
Hi Toby,

Thanks for your answer.


Le 06-01-2010, à 13:28:40 +0100, Toby Cubitt (ts...@cantab.net) a écrit :

> On 06Jan2010 10:36, steve  wrote:
> > At work, I use mutt via a ssh tunnel (with putty). So mutt is running on
> > my home server (Debian). Sometimes I need to attach files located not on
> > my (remote) server but on my local windows box. So what I do is to send
> > myself the files using my work's email account, save it on the remote
> > server and then attach them in mutt; not the best solution but it works.
> >
> > I'd like to know if it's possible to attach files directly from the
> > local machine.
> 
> Since you're already using ssh tunnels, you could try using the sshfs
> filesystem to mount your windows directories remotely on your server.
> sshfs is available for Debian, and I believe it should be able to mount
> directories hosted on a windows system just as easily as anything else.
> 
> Of course, for this to work you'd have to run an ssh server on your
> *windows* box 

I guess it will be difficult (read forbidden) to that at work.

> (and it would have to be visible over the network from your
> server). But running an ssh server on your windows box might be a bit
> easier than setting up a sambda share.

So a Samba share is the only solution left?

Thanks,
steve



Re: Attach local files when displaying remotely

2010-01-06 Thread Monte Stevens
On Wed, Jan 06, 2010 at 01:27:45PM +0100, steve wrote:
> Le 06-01-2010, à 22:45:52 +1100, Cameron Simpson (c...@zip.com.au) a écrit :
> > 
> > Might it not be more direct to scp the files?
> 
> You mean scp to my recipient? Or to my home server? In the first case, I
> don't see how it could simply be possible if the recipient doesn't have
> a ssh server running on his/her machine. And in the second case, I
> simply don't know how to do that from my windows box at work. Not
> allowed to install anything, yet putty runs fine from a usb stick :)

The putty suite includes pscp and psftp, which can be used to do what
you want to do.  pscp is a oneshot copying program, psftp will run an
interactive ftp style session.  You can also use a GUI sftp client such
as FileZilla -- it is available as a portable executable.

Each of these methods can use putty's authentication agent, pageant.

More info...
pscp: http://the.earth.li/~sgtatham/putty/0.60/htmldoc/Chapter5.html#pscp
psftp: http://the.earth.li/~sgtatham/putty/0.60/htmldoc/Chapter6.html#psftp
pageant: http://the.earth.li/~sgtatham/putty/0.60/htmldoc/Chapter9.html#pageant
FileZilla: http://wiki.filezilla-project.org/Howto


-- 
Monte


Re: Attach local files when displaying remotely

2010-01-06 Thread Toby Cubitt
On Wed, Jan 06, 2010 at 01:44:33PM +0100, steve wrote:
> Hi Toby,
>
> Thanks for your answer.
>
>
> Le 06-01-2010, à 13:28:40 +0100, Toby Cubitt (ts...@cantab.net) a écrit :
>
> > On 06Jan2010 10:36, steve  wrote:
> > > At work, I use mutt via a ssh tunnel (with putty). So mutt is running on
> > > my home server (Debian). Sometimes I need to attach files located not on
> > > my (remote) server but on my local windows box. So what I do is to send
> > > myself the files using my work's email account, save it on the remote
> > > server and then attach them in mutt; not the best solution but it works.
> > >
> > > I'd like to know if it's possible to attach files directly from the
> > > local machine.
> >
> > Since you're already using ssh tunnels, you could try using the sshfs
> > filesystem to mount your windows directories remotely on your server.
> > sshfs is available for Debian, and I believe it should be able to mount
> > directories hosted on a windows system just as easily as anything else.
> >
> > Of course, for this to work you'd have to run an ssh server on your
> > *windows* box
>
> I guess it will be difficult (read forbidden) to that at work.

Yes, I wrote that before you're follow-up post mentioning that the
windows box was at work and locked down.

> > (and it would have to be visible over the network from your
> > server). But running an ssh server on your windows box might be a bit
> > easier than setting up a sambda share.
>
> So a Samba share is the only solution left?

Using samba would be a sledgehammer of a solution. In any case, if
running an ssh server is forbidden/impossible, setting up a samba share
isn't going to be allowed either. (Though I suppose you could always ask
-- there's no accounting for the logic of corporate IT policy sometimes!)

The trouble is, mutt can only attach files on the local filesystem (as
far as I know). So to attach a remote file requires either transferring
the file to the computer running mutt, or some way of mounting the remote
filesystem over the network. As another poster has already pointed out,
the former can be achieved with the scp or sftp clients from the PuTTY
suite (since you can run putty, you should have no trouble running pscp
or psftp).

A remote mount is slightly more convenient, as it avoids having to first
manually copy the file across the network before attaching it. But this
is inevitably going to require some kind of server to be running on the
computer hosting the file, be it SSH, or windows itself serving a samba
share. (If you're behind a firewall and can only ssh *out*, then it also
requires some nifty ssh remote port-forwarding to tunnel a connection
*back* from your home server to your work computer.)

However, since it seems running any kind of server on your work computer
is impossible for you, you're probably better off living with
transferring the file by scp or sftp.

Toby
--
Dr T. S. Cubitt
Quantum Information Theory group
Department of Mathematics
University of Bristol
United Kingdom

email: ts...@cantab.net
web: www.dr-qubit.org



Re: time

2010-01-06 Thread Kyle Wheeler
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA256

On Wednesday, January  6 at 11:42 AM, quoth Ravi Uday:
>Kyle,
>
>This didn't work.
>
>The mail header shows :
>
>Date: Tue, 5 Jan 2010 21:59:44 -0800
>
>but my laptop's time is : Jan-6th-2010 11:38 AM.

As Derek Martin pointed out, I got the TZ value wrong. It should be:

 export TZ="Asia/Kolkata"

~Kyle
- -- 
He who joyfully marches in rank and file has already earned my 
contempt. He has been given a large brain by mistake, since for him 
the spinal cord would suffice.
 -- Albert Einstein
-BEGIN PGP SIGNATURE-
Comment: Thank you for using encryption!

iQIcBAEBCAAGBQJLRLUnAAoJECuveozR/AWeWsEP/iCWPJgPqihMBh8nV3Xut00a
WarmmVnbyYzuyeeXZMB9VoUUNRLjcDy/lO6uc6eyr0GilGNdSz0Qdzuoq62Lq8zb
+FrZjGN00o6OnogAfaO86vLEOe2jSaFJ40vTdxwgfQGAyDVhXh+v/CBBlRkSoO4e
CiZO022yrRG3gTc/B55qFySLhsfmM7SQB/ke1rq5fkVDkrw8QmHbNRSNH24CFUzD
sV+aePUgzdF1CbNbcwD3tuaUcBtraOY+K6Rufse23fhiBCnnY32JwffEPGbo7I6W
8JyfOmZg+VbOJDxCQUy9TSspSolWf0bnBJiZc4dr9Bf8oFIv6sw3Hnh2rEfMjYnS
vjnZNwE4Uz0sprDWoY6YFGpdzEamGulVVEsV3UA1Mwd81Tg/olNutYCubdibOyCt
Wn0qNRzLjyOFc46QSasPQSrQEWUdoc0u9LuhEhZP2GFbOjE3V0fdc0iuggWW6yCr
YiTbogLuZF1HUPy+u9Ltfd0Mg/MaM1WaHtXjZRRxKBsWSjF+wlNIJJ2s6bi3wfU2
pQtIcpmhDinxXHkViJ6B5J/XYkN/ywtC7HnWgYewMT2oA7rd0FO5MYblh3vEX1yP
/IDE8V/pV39b3ojnhpBSlLCq1U67w6Ce3eoQ/NbOCFyXKa+ocdOoSyHiqB7+aF/U
aF/yO+dWwIV9IvkSmHIW
=wcqb
-END PGP SIGNATURE-


Re: time

2010-01-06 Thread Gary Johnson
On 2010-01-06, Ravi Uday  wrote:

> On Wed, Jan 6, 2010 at 1:27 PM, Patrick Ben Koetter  
> wrote:
> > * Ravi Uday :
> >> Kyle,
> >>
> >> This didn't work.
> >>
> >> The mail header shows :
> >>
> >> Date: Tue, 5 Jan 2010 21:59:44 -0800
> >>
> >> but my laptop's time is : Jan-6th-2010 11:38 AM.
> >
> > Did you source the ~/.bashrc after editing it?

> Yes I did it.
> On the linux server where i run mutt :
> 
> bash-3.00$ date
> Wed Jan  6 08:44:40 IST 2010
> 
> Now from within mutt, if I check a recent mail's header, I see this :
> ..
> Date: Wed, 6 Jan 2010 00:44:27 -0800
> ..
> 
> I just have
> export TZ=IST
> in my .bashrc.
> 
> Both the dates(from bash and from within mutt) are wrong
> when I see from my windows m/c.
> It rightly shows - Jan-6-2010 2:15 PM ! whichis the correct time now

On a Red Hat system I just tried, TZ=IST doesn't work for me,
either, but TZ=Asia/Calcutta does.  The time zone names are in
/usr/share/zoneinfo.

HTH,
Gary




Re: Vim fold key bindings for mutt threads

2010-01-06 Thread david

On 04/01/10 11:22, Horacio Sanson wrote:
> Is it possible to create Vim fold like keybindings to expand/collapse 
threads in

> mutt?
>
> Example:
>zo  -   expand thread under the cursor
>zO  -   expand thread under the cursor and all subthreads recursively
>zc  -   close thread under the cursor
>zC  -   close thread under the cursor and all subthreads recursively
>za  -   toggle thread under the cursor
>zA  -   toggle thread under the cursor and all subthreads recursively
>
> Being used to vim keybindings using ESC-v is rather uncomfortable for me.
>

Here is a list of bindings and macros I use to simulate vim. Any 
suggestion to enhance it is welcome ;)


#
#  Moving
#

bind generic   first-entry
bind pager  top

bind genericlast-entry
bind pager   bottom

bind indexprevious-entry
bind index  next-entry

bind pagerprevious-line
bind pager  next-line

bind index jnext-undeleted
bind pager jnext-undeleted

bind index kprevious-undeleted
bind pager kprevious-undeleted

bind index Jnext-new-then-unread
bind pager Jnext-new-then-unread

bind index Kprevious-new-then-unread
bind pager Kprevious-new-then-unread

bind index   '('  previous-subthread
bind pager   '('  previous-subthread

bind index   ')'  next-subthread
bind pager   ')'  next-subthread

bind index   '{'  previous-thread
bind pager   '{'  previous-thread

bind index   '}'  next-thread
bind pager   '}'  next-thread

bind index   '['  half-up
bind pager   '['  half-up

bind index   ']'  half-down
bind pager   ']'  half-down

bind pager  previous-entry
bind pager next-entry

#
#  Sidebar (mutt patched)
#

# ctrl - n, p, o, u, d

bind pager '' sidebar-next
bind index '' sidebar-next

bind pager '' sidebar-prev
bind index '' sidebar-prev

bind pager '' sidebar-open
bind index '' sidebar-open

bind pager '' sidebar-scroll-up
bind index '' sidebar-scroll-up

bind pager '' sidebar-scroll-down
bind index '' sidebar-scroll-down

#
#  Move, Copy, Delete mails
#

bind pager 's' save-message
bind index 's' save-message

bind pager 'S' copy-message
bind index 'S' copy-message

bind index 'd' delete-message
bind pager 'd' delete-message

bind index 'u' undelete-message
bind pager 'u' undelete-message

bind index 'D' delete-thread
bind pager 'D' delete-thread

bind index 'U' undelete-thread
bind pager 'U' undelete-thread

#
#  Display
#

# Headers
# 

bind pager   'h'  display-toggle-weed

#
#  Selections
#

bind index vtag-thread
bind index Vtag-pattern
bind index untag-pattern

#
#  Lists
#

macro index za 'v'
macro pager za 'v'

macro index zr 'V'
macro pager zr 'V'

macro index zm 'V'
macro pager zm 'V'

#
#  Attachments
#

macro attach V '|view -'


Re: Vim fold key bindings for mutt threads

2010-01-06 Thread david

On 04/01/10 11:22, Horacio Sanson wrote:
> Is it possible to create Vim fold like keybindings to expand/collapse
threads in
> mutt?
>
> Example:
>zo  -   expand thread under the cursor
>zO  -   expand thread under the cursor and all subthreads recursively
>zc  -   close thread under the cursor
>zC  -   close thread under the cursor and all subthreads recursively
>za  -   toggle thread under the cursor
>zA  -   toggle thread under the cursor and all subthreads recursively
>
> Being used to vim keybindings using ESC-v is rather uncomfortable for me.
>

well, encoding issue with the ctrl-*, here is a more portable form :

bind pager \cn sidebar-next
bind index \cn sidebar-next

bind pager \cp sidebar-prev
bind index \cp sidebar-prev

bind pager \co sidebar-open
bind index \co sidebar-open

bind pager \cu sidebar-scroll-up
bind index \cu sidebar-scroll-up

bind pager \cd sidebar-scroll-down
bind index \cd sidebar-scroll-down


Re: time

2010-01-06 Thread Ravi Uday
It is still the same.

on linux :

bash-3.00$ date
Wed Jan  6 17:24:25 Asia/Kolkata 2010
bash-3.00$

On a new email, inside mutt the header shows it as :

Date: Wed, 6 Jan 2010 09:24:20 -0800

I just have:
export TZ="Asia/Kolkata"

in my .bashrc.

The actual time should be : 10:54:25 PM - Jan-6th-2010.

- Ravi

On Wed, Jan 6, 2010 at 9:37 PM, Kyle Wheeler  wrote:
> -BEGIN PGP SIGNED MESSAGE-
> Hash: SHA256
>
> On Wednesday, January  6 at 11:42 AM, quoth Ravi Uday:
>>Kyle,
>>
>>This didn't work.
>>
>>The mail header shows :
>>
>>Date: Tue, 5 Jan 2010 21:59:44 -0800
>>
>>but my laptop's time is : Jan-6th-2010 11:38 AM.
>
> As Derek Martin pointed out, I got the TZ value wrong. It should be:
>
>     export TZ="Asia/Kolkata"
>
> ~Kyle
> - --
> He who joyfully marches in rank and file has already earned my
> contempt. He has been given a large brain by mistake, since for him
> the spinal cord would suffice.
>                                                     -- Albert Einstein
> -BEGIN PGP SIGNATURE-
> Comment: Thank you for using encryption!
>
> iQIcBAEBCAAGBQJLRLUnAAoJECuveozR/AWeWsEP/iCWPJgPqihMBh8nV3Xut00a
> WarmmVnbyYzuyeeXZMB9VoUUNRLjcDy/lO6uc6eyr0GilGNdSz0Qdzuoq62Lq8zb
> +FrZjGN00o6OnogAfaO86vLEOe2jSaFJ40vTdxwgfQGAyDVhXh+v/CBBlRkSoO4e
> CiZO022yrRG3gTc/B55qFySLhsfmM7SQB/ke1rq5fkVDkrw8QmHbNRSNH24CFUzD
> sV+aePUgzdF1CbNbcwD3tuaUcBtraOY+K6Rufse23fhiBCnnY32JwffEPGbo7I6W
> 8JyfOmZg+VbOJDxCQUy9TSspSolWf0bnBJiZc4dr9Bf8oFIv6sw3Hnh2rEfMjYnS
> vjnZNwE4Uz0sprDWoY6YFGpdzEamGulVVEsV3UA1Mwd81Tg/olNutYCubdibOyCt
> Wn0qNRzLjyOFc46QSasPQSrQEWUdoc0u9LuhEhZP2GFbOjE3V0fdc0iuggWW6yCr
> YiTbogLuZF1HUPy+u9Ltfd0Mg/MaM1WaHtXjZRRxKBsWSjF+wlNIJJ2s6bi3wfU2
> pQtIcpmhDinxXHkViJ6B5J/XYkN/ywtC7HnWgYewMT2oA7rd0FO5MYblh3vEX1yP
> /IDE8V/pV39b3ojnhpBSlLCq1U67w6Ce3eoQ/NbOCFyXKa+ocdOoSyHiqB7+aF/U
> aF/yO+dWwIV9IvkSmHIW
> =wcqb
> -END PGP SIGNATURE-
>


Re: time

2010-01-06 Thread Kyle Wheeler
-BEGIN PGP SIGNED MESSAGE-
Hash: SHA256

On Wednesday, January  6 at 10:57 PM, quoth Ravi Uday:
>It is still the same.
>
>on linux :
>
>bash-3.00$ date
>Wed Jan  6 17:24:25 Asia/Kolkata 2010
>bash-3.00$
>
>On a new email, inside mutt the header shows it as :
>
>Date: Wed, 6 Jan 2010 09:24:20 -0800

Hrm. I would have thought it would do:

 Date: Wed, 6 Jan 2010 09:24:20 +0530

Because what mutt SHOULD be doing is printing the Date header in the 
local time (according to your timezone) and then specify the timezone 
via the standard offset (which, for IST, is +0530).

What mutt does to generate the Date header is to call the system 
function localtime() for the time and date---that SHOULD produce the 
same output as the `date` command at the commandline.

I do note that mutt's source says it's "optimized" for negative 
timezone offsets, but I don't know enough to be able to tell if its 
calculating positive timezone offsets correctly---it may not be.

~Kyle
- -- 
The important work of moving the world forward does not wait to be 
done by perfect men.
-- George Eliot
-BEGIN PGP SIGNATURE-
Comment: Thank you for using encryption!

iQIcBAEBCAAGBQJLRNjvAAoJECuveozR/AWe86YQAK13Y9HHD8TAta3T5o8I7Uvr
PkuApIsMHGFBS9fzZXFwMuhGn1GFhHLN07bWHOERyzYIlyslIEAgnLeYOekce15f
dWrAG8kZXw3ix+tZWDm5z5fNYKSBcNdHKJxOI5kaL+rqOv6dgxc6w6wMfF0xFOvP
cm/f+kZ6q1ZY+fjmiOyr4nbWqOfjtzTCjW5ixIQLAJphdzd9fPZgK5fJUWV5ph9A
fizldLWTM5ORnNd4tlNLxH1PFew6CxJM2WTGBjzErCqeYqKCcYVzXt7hPdk4xz61
DZNC0rNXQaU18BGJhizIbu9QWHAQrCTVl9zRdlVbmZ64FDAkY5ycu5mjqMPSWUko
s3Yehst84MdiH9X8iD1Pw4+31+R6wGzBSGOqI8hiJ0rUmiMkagKk5r6/4w5BDWMv
P0C/WcosLrL1cxx/ILRtPvkKAuOQHVtRWm2J6TaMygtaKKU5GRWQlX2BklVfHyne
YaVuuqr1x7M0BP/h9wWedPNZsm7qg3Tcf171y9v9cIUGo4AWNY2Mu2/PeKlAnC4O
SgUBZJ3ooEv8GWho/C+IEJ+01g6iOWkyL575oBnUAjYpysySkLWIIemInurUDQzm
LDwzGo4Tmh6+c0T5nmFPhhnePfqzknAC5OSvAt8gwO5MMTgCb4ooKG5emoISV9l3
w7a1NEzRBfBExvj/jCzF
=Vto5
-END PGP SIGNATURE-


Re: time

2010-01-06 Thread Derek Martin
On Wed, Jan 06, 2010 at 10:07:03AM -0600, Kyle Wheeler wrote:
> As Derek Martin pointed out, I got the TZ value wrong. It should be:
> 
>  export TZ="Asia/Kolkata"

Incidentally, one of the problems with Unix timezones is exemplified
by IST.  IST can stand for Israel Standard Time, Indian Standard Time,
Iran Standard Time, and my personal favorite, Irish Summer Time.  I've
read somewhere that on at least one old Unix system (I can't remember
what or when), it was interpreted as that last one.  I can hardly
blame it though... who wouldn't want to spend their time in Ireland in
the summer, given the chance? ;-)

Can you tell I've had this problem before?  My employer has offices in
Bangalore...

-- 
Derek D. Martinhttp://www.pizzashack.org/   GPG Key ID: 0xDFBEAD02
-=-=-=-=-
This message is posted from an invalid address.  Replying to it will result in
undeliverable mail due to spam prevention.  Sorry for the inconvenience.



pgp9xfzFuDAJD.pgp
Description: PGP signature


Re: Problems with a2ps/enscript and printing in mutt

2010-01-06 Thread Ed Blackman

On Tue, Jan 05, 2010 at 11:30:17PM -0500, Joseph Ishac wrote:

Since print_decode is set, mutt is parsing the message before piping it.
I was wondering if there is a way to have mutt hand me the subject of
the message so that I could pass it to the -t option of enscript to
formulate a title.


I've attached my muttPrint script, which uses formail to grab the 
subject to pass to enscript.


Ed
#!/bin/sh
#
# muttPrint
#
# macro index,pager p \
# 'source ~/.mutt/rc/print.rcmuttPrint 
[enscript args]\
# source ~/.mutt/rc/unprint.rc'

# arguments always passed to enscript
args="-f Times-Roman12 --word-wrap --fancy-header=emacs-custom"

# save the message to a tempfile
: ${TEMP:=$HOME/tmp}
tmpf=$TEMP/muttprint$$
cat >"$tmpf"

# get Subject, stripping all occurrances of 'Re: ' and any initial spaces
subj="$(formail -cx Subject <$tmpf | sed -e 's/Re: \?//g' -e 's/^\s\+//')"

# get Date, and parse into a more regular, but still human-readable format
date="$(date -d "$(formail -cx Date <$tmpf)" +%Y-%m-%d-%H:%M:%S)"

# send message to print with appropriate title and all passed args
enscript --title "$subj $date" $args "$@" <"$tmpf"

# save the enscript return code, remove the temp file, and exit
rc=$?

rm "$tmpf"
exit $rc


signature.txt
Description: Digital signature


Re: Vim fold key bindings for mutt threads

2010-01-06 Thread Gen-Paul

david wrote:

[..]

Cool..!

Thanks for posting.

Gen-Paul.


Re: Attach local files when displaying remotely

2010-01-06 Thread Cameron Simpson
On 06Jan2010 13:44, steve  wrote:
| Le 06-01-2010, à 13:28:40 +0100, Toby Cubitt (ts...@cantab.net) a écrit :
| > On 06Jan2010 10:36, steve  wrote:
| > > I'd like to know if it's possible to attach files directly from the
| > > local machine.
| > 
| > Since you're already using ssh tunnels, you could try using the sshfs
| > filesystem to mount your windows directories remotely on your server.
| > sshfs is available for Debian, and I believe it should be able to mount
| > directories hosted on a windows system just as easily as anything else.
| > 
| > Of course, for this to work you'd have to run an ssh server on your
| > *windows* box 
| 
| I guess it will be difficult (read forbidden) to that at work.

Hmm, wouldn't putty already be forbidden?

You could:
  put a small cygwin install on your USB key
  run an sshd, _listening only on localhost_ !! (not remotely
accessible)
  do a _reverse_ portforward in Putty, forwarding the local sshd
service to your home machine
  run sshfs at home, connecting to the forwarded sshd service

sshfs uses the SFTP protocol, so it should be happy.

| > (and it would have to be visible over the network from your
| > server). But running an ssh server on your windows box might be a bit
| > easier than setting up a sambda share.
| 
| So a Samba share is the only solution left?

Only if sshfs can't be made to work: sshfs is a better solution.

Cheers,
-- 
Cameron Simpson  DoD#743
http://www.cskk.ezoshosting.com/cs/

Silicon chips with a cardboard substrate?  That's not a good marriage!
- overhead by WIRED at the Intelligent Printing conference Oct2006


Re: Problems with a2ps/enscript and printing in mutt

2010-01-06 Thread Wilkinson, Alex

0n Tue, Jan 05, 2010 at 11:30:17PM -0500, Joseph Ishac wrote: 

>I'm looking to adjust the way mutt prints.  I had just been piping
>things to lpr, but I decided to try and get a little fancier.

You may want to look at:

   Muttprint pretty-prints mail messages for any mail client which can output
   plain text with the mail headers included.
   
   It uses the typesetting system LaTeX, which is normally installed on a
   Unix/Linux system.
   
   WWW: http://muttprint.sourceforge.net/

 -Alex

IMPORTANT: This email remains the property of the Australian Defence 
Organisation and is subject to the jurisdiction of section 70 of the CRIMES ACT 
1914.  If you have received this email in error, you are requested to contact 
the sender and delete the email.



Re: Mutt 256 color themes

2010-01-06 Thread Gen-Paul

Horacio Sanson wrote:

 Currently I am using the ivy league color theme from Aaron Toponce
 (see link below) with a couple of modifications to make it work in my
 transparent KDE Konsole.



 http://pthree.org/2008/10/22/ivy-league-theme-for-mutt/



 I was looking for similar 256 color themes for mutt but there does
 not appear to be any on the whole Internet.


There are some config file samples at http://wiki.mutt.org - look for a 
link called
Configlist - some include coloring, and screenshots are provided, but 
there are many
broken links. There used to be a lot more when I downloaded some to my 
laptop a couple

of years ago when I was setting up mutt.


 Are there any other themes around? Or is anyone willing to share
 their colors?

 Here I attach the color setting I use. To use it I source it in my
 .muttrc file like:

 source /path/to/ivy256


Attaching mine, I use different tones of a couple of colors and shades 
of grey rather
than the entire color spectrum, so if you were looking for something 
colorful, you

will be disappointed :-)

If you want to take a look at it, make sure you're running mutt on a 
dark background.


Gen-Paul.



# -*- muttrc -*-
#
# Color settings for mutt.
#

# Default color definitions
color normal  color250  default
color hdrdefault  color136  default
color quotedcolor244  default
color quoted1 color240  default
color quoted2 color236  default
color quoted3 color244  default
color quoted4 color240  default
color quoted5 color236  default
color signature   color254  default
color indicator   color231  color233
color error   color88   default
color statusblack color245
color treecolor240  default
color tilde   black default
color attachment  brightyellow  default
color markers   color240  default
color message color250  default
color search  color231  color233
color boldcolor231  default

# Color definitions when on a mono screen
mono bold bold
mono underlineunderline
mono indicatorreverse
mono errorbold

# Colors for message headers
color header  color231  default "^(From|Subject):"
color header  color231  default ^To:
color header  color231  default ^Cc:
mono  header  bold  "^(From|Subject):"

# This is a mess.  What happens when a message is flagged twice?

# reset index to medium grey
color index   color246  default " "
# regular new messages
color index   color145  default "~O | ~N"
# regular 'old' messages
#color index  color145  default "~N" 
# regular tagged messages
color index   color184  default "~T"
# regular flagged messages
color index   color185  default "~F"
# messages to myself
color index   color221  default "~p"
# messages from myself
color index   color221  default "~P"
# big messages - don't see much point for this one
#color index  color52   default "~z 32765-"
# deleted messages
color index   color160   default "~D"

# Highlights inside the body of a message.

# Attribution lines
color body color208 default "\\* [^<]+ <[^>]+> \\[[^]]+\\]:"
color body color208 default "(^|[^[:alnum:]])on [a-z0-9 ,]+( at [a-z0-9:,. 
+-]+)? wrote:"

# The TOFU
#color body color231 default "\[\-\-\-\=\|"
color body color231 default "TOFU"

# Highlights inside the body of a message.

# URLs
color body color231default "(http|https|ftp|news|telnet|finger)://[^ 
\"\t\r\n]*"
color body color231default "mailto:[-a-z_0-9...@[-a-z_0-9.]+";
mono  body bold"(http|https|ftp|news|telnet|finger)://[^ 
\"\t\r\n]*"
mono  body bold"mailto:[-a-z_0-9...@[-a-z_0-9.]+";

# email addresses
color body color231default "[-a-z_0-9.%...@[-a-z_0-9.]+\\.[-a-z][-a-z]+"
mono  body bold"[-a-z_0-9.%...@[-a-z_0-9.]+\\.[-a-z][-a-z]+"

# PGP messages
color  bodycolor84 default "^gpg: Good signature .*"
color  bodycolor250default "^gpg: "
color  bodycolor88 default "^gpg: BAD signature from.*"
mono   bodybold"^gpg: Good signature"
mono   bodybold"^gpg: BAD signature from.*"

# Various smilies and the like
color body color220default "<[Gg]>"# 
color body color220default "<[Bb][Gg]>"# 
color body color220default " [;:]-*[})>{(<|]"  # :-) etc...
# *bold*
color body color231default 
"(^|[[:space:][:punct:]])\\*[^*]+\\*([[:space:][:punct:]]|$)"
mono  body bold
"(^|[[:space:][:punct:]])\\*[^*]+\\*([[:space:][:punct:]]|$)"
# _underline_
color body color231default 
"(^|[[:space:][:punct:]])_[^_]+_([[:space:][:punct:]]|$)"
mono  body underline   
"(^|[[:space:][:punct:]])_[^_]+_([[:space:][:punct:]]|$)"
# /italic/  (Sometimes gets