Re: Tag or delete by date or age

2002-03-28 Thread Cedric Duval

   That's odd, I get the same thing as Shawn:

Yep, weird. Like David, I have no problem with his sig.

   Can you tell us your...

   ... $pgp_getkeys_command?

pgp_getkeys_command=

Whenever gpg encounters a new key, it fetches it automatically.

   ... make and model of crypto software?

~ % gpg --version
gpg (GnuPG) 1.0.6
Copyright (C) 2001 Free Software Foundation, Inc.
This program comes with ABSOLUTELY NO WARRANTY.
This is free software, and you are welcome to redistribute it
under certain conditions. See the file COPYING for details.

Home: ~/.gnupg
Algorithmes supportés:
Cipher: 3DES, CAST5, BLOWFISH, RIJNDAEL, RIJNDAEL192, RIJNDAEL256,
TWOFISH
Pubkey: RSA, RSA-E, RSA-S, ELG-E, DSA, ELG
Hash: MD5, SHA1, RIPEMD160

   ... keyserver hostname?

~ % grep keyserver .gnupg/options
# for sercain operations. Is you set this option to a keyserver
# Use host -l pgp.net | grep www to figure out a keyserver.
keyserver wwwkeys.uk.pgp.net

-- 
Cedric



msg26352/pgp0.pgp
Description: PGP signature


Re: Tag or delete by date or age

2002-03-28 Thread John Buttery

* John Buttery [EMAIL PROTECTED] [2002-03-28 04:07:05 -0600]:
  Can you tell us your...

  ... $pgp_getkeys_command?
  ... make and model of crypto software?
  ... keyserver hostname?

  And of course it didn't occur to me to provide mine :p

  I'm using GPG 1.0.6 with a keyserver wwwkeys.us.pgp.net.  Here's my
$pgp_getkeys_command:

pgp_getkeys_command=/usr/bin/gpg --recv-keys %r  /dev/null 21

  Of course, there are implied other flags to gpg from its options file,
so I'll go ahead and attach that.

-- 
uh huh.


no-greeting
default-key 0x587F0CD702368857
force-v3-sigs
escape-from-lines
lock-once
keyserver wwwkeys.us.pgp.net
honor-http-proxy



msg26354/pgp0.pgp
Description: PGP signature


Re: Tag or delete by date or age - pattern ~d

2002-03-28 Thread Mike Schiraldi

 apropos:
 anyone have a utility to calculate the
 number of days between two given dates?
 i mean - easily?  no perl script
 with dozens of modules, please!

I'd do this, assuming you have the GNU version of date:

#! /bin/sh
expr \( `date -d $2 +%s` - `date -d $1 +%s` \) / 86400

This assumes that you consider the difference between, say, 'jan 1' and 'jan
4' to be 3 days, but the difference between '12 pm jan 1 2002' and '12 am
jan 4 2002' to be 2 days.

Here's the perl script i use to make my X-Last-Reboot header. It does the
opposite -- it determines the date that was n seconds ago:

#! /usr/bin/perl -W
use strict;

open X, '/proc/uptime' or die;
defined (my $time = X) or die;
$time =~ s/ .*// or die;

my $days  = int  ($time / 86400);
my $hours = int (($time % 86400) / 3600);
my $mins  = int (($time % 3600) / 60);
my $secs  = int  ($time % 60);

my (undef, undef, undef, $day, $mon, $year) = localtime (time - $time);

$year += 1900;
$mon = qw(January February March April May June July 
  August September October November December)[$mon];

print $mon $day, $year ($days days ago)\n;



msg26359/pgp0.pgp
Description: PGP signature


Re: Keyserver Bug (was: Re: Tag or delete by date or age)

2002-03-28 Thread Shawn McMahon

begin  quoting what mike ledoux said on Thu, Mar 28, 2002 at 10:27:37AM -0500:
 
 and hand out an invalid key.  This is a known problem in the keyserver
 code.  You can get a *valid* copy of my key from:
 
 http://www.volta.dyndns.org/~mwl/pgpkey.asc

Yep, worked peachy.  Thanks.

 As stated in the headers of every message I send.

Headers are for information for machines.  Information humans are
expected to read belongs in the body.

Many mailers don't show headers beyond the crucial ones.  Mutt lets
you configure that, I configure it that way.

 Of course, the signing key provided by the keyservers is still OK, as
 this problem only affects the encryption subkey(s), so you still should've
 been able to verify the signature.

Couldn't get the sig automatically.  But now that I have added it manually,
all is well.




msg26369/pgp0.pgp
Description: PGP signature


Tag or delete by date or age

2002-03-27 Thread Charles Gagnon

Is there a way to tag or delete by date. I use to do this a while back using
mush. Since I have a lot of folders where I get reports (i.e. backup reports
for example), deleting by date was an easy way to keep only the current and
previous month for example. All I would need is a way to say tag/delete
everything older than specific date or even tag/delete everything older
than number of days, whatever is easier.

If it's not in there, it would be a great feature.

-- 
Charles Gagnon   | My views are my views and they
http://unixrealm.com | do not represent those of anybody
[EMAIL PROTECTED]   | but me.

   One tequila, two tequila, three tequila, floor.
-- Dennis Miller



Re: Tag or delete by date or age

2002-03-27 Thread Simon White

27-Mar-02 at 15:07, Charles Gagnon ([EMAIL PROTECTED]) wrote :
 Is there a way to tag or delete by date. I use to do this a while back using
 mush. Since I have a lot of folders where I get reports (i.e. backup reports
 for example), deleting by date was an easy way to keep only the current and
 previous month for example. All I would need is a way to say tag/delete
 everything older than specific date or even tag/delete everything older
 than number of days, whatever is easier.

tag-pattern (usually bound to T)
~d range-range
tag-delete (usually ; then d)

See the manual for patterns, etc.


 If it's not in there, it would be a great feature.

This is easy for Mutt, one of his stock tricks you don't even have to
teach him.

You could write a macro to automatically delete messages older than a
certain date from a certain person, all in one keypress...

One tequila, two tequila, three tequila, floor.
 -- Dennis Miller

-- 
[Simon White. vim/mutt. [EMAIL PROTECTED] GIMPS:57.39% see www.mersenne.org]
History is the version of past events that people have decided to agree
upon.  -- Napoleon Bonaparte
[Arbitrary quotes signature rotation, a simple bash script by Simon White]



Re: Tag or delete by date or age

2002-03-27 Thread David T-G

Charles --

...and then Charles Gagnon said...
% 
% Is there a way to tag or delete by date. I use to do this a while back using

Yes.


% mush. Since I have a lot of folders where I get reports (i.e. backup reports
% for example), deleting by date was an easy way to keep only the current and

Makes sense.


% previous month for example. All I would need is a way to say tag/delete
% everything older than specific date or even tag/delete everything older
% than number of days, whatever is easier.

Well, the really easiest way would be to have procmail sort your backup
reports into folders by month and then you just delete the folder when
you're done :-)


% 
% If it's not in there, it would be a great feature.

See section 4.2, and perhaps 4.3, of the manual and get to work.


% 
% -- 
% Charles Gagnon   | My views are my views and they
% http://unixrealm.com | do not represent those of anybody
% [EMAIL PROTECTED]   | but me.
% 
%One tequila, two tequila, three tequila, floor.
% -- Dennis Miller


HTH  HAND

:-D
-- 
David T-G  * It's easier to fight for one's principles
(play) [EMAIL PROTECTED] * than to live up to them. -- fortune cookie
(work) [EMAIL PROTECTED]
http://www.justpickone.org/davidtg/Shpx gur Pbzzhavpngvbaf Qrprapl Npg!




msg26302/pgp0.pgp
Description: PGP signature


Re: Tag or delete by date or age

2002-03-27 Thread David T-G

Simon, et al --

...and then Simon White said...
% 
% You could write a macro to automatically delete messages older than a
% certain date from a certain person, all in one keypress...

Of course, if you did so, it would be wise to use Nicolas's tag-conditional
patch to ensure that it works as desired even when there are no matches...


% 
% One tequila, two tequila, three tequila, floor.
%  -- Dennis Miller
% 
% -- 
% [Simon White. vim/mutt. [EMAIL PROTECTED] GIMPS:57.39% see www.mersenne.org]
% History is the version of past events that people have decided to agree
% upon.  -- Napoleon Bonaparte
% [Arbitrary quotes signature rotation, a simple bash script by Simon White]


:-D
-- 
David T-G  * It's easier to fight for one's principles
(play) [EMAIL PROTECTED] * than to live up to them. -- fortune cookie
(work) [EMAIL PROTECTED]
http://www.justpickone.org/davidtg/Shpx gur Pbzzhavpngvbaf Qrprapl Npg!




msg26304/pgp0.pgp
Description: PGP signature


Re: Tag or delete by date or age

2002-03-27 Thread Shawn McMahon

begin  quoting what mike ledoux said on Wed, Mar 27, 2002 at 03:29:20PM -0500:

gpg: requesting key 57C3430B from wwwkeys.us.pgp.net ...
gpg: key 57C3430B: invalid subkey binding
gpg: key 57C3430B: no valid user IDs
gpg: this may be caused by a missing self-signature



Sign your key and re-submit it.




msg26305/pgp0.pgp
Description: PGP signature


Re: Tag or delete by date or age

2002-03-27 Thread David T-G

Shawn, et al --

...and then Shawn McMahon said...
% 
% begin  quoting what mike ledoux said on Wed, Mar 27, 2002 at 03:29:20PM -0500:
% 
% gpg: requesting key 57C3430B from wwwkeys.us.pgp.net ...
% gpg: key 57C3430B: invalid subkey binding
% gpg: key 57C3430B: no valid user IDs
% gpg: this may be caused by a missing self-signature

Hmmm...  That's not what I got:

  [-- PGP output follows -- Wed Mar 27 15:39:21 2002 --]gpg: Signature made Wed
  +Mar 27 15:29:20 2002 EST using DSA key ID 57C3430B
  gpg: Good signature from mike ledoux [EMAIL PROTECTED]
  gpg: key 7B9F4700: already in trusted key table
  gpg: WARNING: This key is not certified with a trusted signature!
  gpg:  There is no indication that the signature belongs to the owner.
  gpg: Fingerprint: AA02 86F6 FE1B 552C BB86  1D85 E6B8 1D1C 57C3 430B


% 
% 
% Sign your key and re-submit it.

Better check what you have, too.


:-D
-- 
David T-G  * It's easier to fight for one's principles
(play) [EMAIL PROTECTED] * than to live up to them. -- fortune cookie
(work) [EMAIL PROTECTED]
http://www.justpickone.org/davidtg/Shpx gur Pbzzhavpngvbaf Qrprapl Npg!




msg26306/pgp0.pgp
Description: PGP signature


Re: Tag or delete by date or age

2002-03-27 Thread Shawn McMahon

begin  quoting what David T-G said on Wed, Mar 27, 2002 at 03:40:46PM -0500:
 
 % Sign your key and re-submit it.
 
 Better check what you have, too.

If my key wasn't signed, GPG wouldn't accept it.




msg26307/pgp0.pgp
Description: PGP signature


Re: Tag or delete by date or age

2002-03-27 Thread David T-G

Shawn --

...and then Shawn McMahon said...
% 
% begin  quoting what David T-G said on Wed, Mar 27, 2002 at 03:40:46PM -0500:
%  
%  % Sign your key and re-submit it.
%  
%  Better check what you have, too.
% 
% If my key wasn't signed, GPG wouldn't accept it.

No, no -- I meant that you had better check your copy of his key; as
shown, it works fine for me.


:-D
-- 
David T-G  * It's easier to fight for one's principles
(play) [EMAIL PROTECTED] * than to live up to them. -- fortune cookie
(work) [EMAIL PROTECTED]
http://www.justpickone.org/davidtg/Shpx gur Pbzzhavpngvbaf Qrprapl Npg!




msg26308/pgp0.pgp
Description: PGP signature


Re: Tag or delete by date or age

2002-03-27 Thread Shawn McMahon

begin  quoting what David T-G said on Wed, Mar 27, 2002 at 03:55:19PM -0500:
 
 No, no -- I meant that you had better check your copy of his key; as
 shown, it works fine for me.

I don't have a copy of his key; GPG attempted to import it from the
keyserver, but the one on the keyserver didn't have a self-signature,
so it refused to import it.

Hence, he should sign his key and resubmit it to the keyserver.




msg26309/pgp0.pgp
Description: PGP signature


Re: Tag or delete by date or age

2002-03-27 Thread Steve Talley

You can use folder hooks to delete, say, anything older than a month
that isn't marked important:

folder-hook IN\.mutt 'push D~r1m!~Fenter'

This will be done automatically when you load the specified folder.

Steve

Charles Gagnon wrote:

 Is there a way to tag or delete by date. I use to do this a while back using
 mush. Since I have a lot of folders where I get reports (i.e. backup reports
 for example), deleting by date was an easy way to keep only the current and
 previous month for example. All I would need is a way to say tag/delete
 everything older than specific date or even tag/delete everything older
 than number of days, whatever is easier.

 If it's not in there, it would be a great feature.



Re: Tag or delete by date or age - pattern ~d

2002-03-27 Thread Sven Guckes

* Charles Gagnon [EMAIL PROTECTED] [2002-03-27 20:07]:
 Is there a way to tag or delete by date.

yes - you can tag messages by pattern ~d
which acceses their date.

 I use to do this a while back using mush. Since I have a
 lot of folders where I get reports (i.e. backup reports
 for example), deleting by date was an easy way to keep
 only the current and previous month for example.
 All I would need is a way to say
 tag/delete everything older than specific date

  ~d dd/mm/-

 or even
 tag/delete everything older than number of days,
 whatever is easier.

this is not included - sorry.

for more info see my setup page, section Moving old messages;
http://www.math.fu-berlin.de/~guckes/mutt/setup.html#moving_mails

Sven

-- 
Sven Guckes  http://www.math.fu-berlin.de/~guckes/mutt/setup.html
Mutt setup from scratch, Sven's sample setup; attribution, limit, list
vs subscribe, histories, mailcap, POP, hooks, use of external pagers,
troubleshooting, adding header lines, from Mozilla to Mutt.



Re: Tag or delete by date or age - pattern ~d

2002-03-27 Thread Aaron Schrab

At 23:51 +0100 27 Mar 2002, Sven Guckes [EMAIL PROTECTED] wrote:
 * Charles Gagnon [EMAIL PROTECTED] [2002-03-27 20:07]:
  or even
  tag/delete everything older than number of days,
  whatever is easier.
 
 this is not included - sorry.

Wrong.  T~d5d will tag all messages older than 5 days.  w(eek),
m(onth), and y(ear) can also be used in place of the second d.

See the section on Searching by Date (4.2.3 in my copy), especially
the Relative subsection for more info.

-- 
Aaron Schrab [EMAIL PROTECTED]  http://www.schrab.com/aaron/
 ...Unix, MS-DOS, and Windows NT (also known as the Good, the Bad, and
 the Ugly).  -- Matt Welsh



Re: Tag or delete by date or age - pattern ~d

2002-03-27 Thread Sven Guckes

* Aaron Schrab [EMAIL PROTECTED] [2002-03-27 23:14]:
 At 23:51 +0100 27 Mar 2002, Sven Guckes [EMAIL PROTECTED] wrote:
  * Charles Gagnon [EMAIL PROTECTED] [2002-03-27 20:07]:
   or even
   tag/delete everything older than number of days,
   whatever is easier.
  this is not included - sorry.
 Wrong.  T~d5d will tag all messages older than 5 days.

yes - but this is only relative to the *current* date.
I understood that in the context of the given  question
this date shall be relative to a given day - no?
(but, hey, that would be cool, too! :-)

apropos:
anyone have a utility to calculate the
number of days between two given dates?
i mean - easily?  no perl script
with dozens of modules, please!

Sven



Re: Tag or delete by date or age - pattern ~d

2002-03-27 Thread Aaron Schrab

At 00:18 +0100 28 Mar 2002, Sven Guckes [EMAIL PROTECTED] wrote:
 * Aaron Schrab [EMAIL PROTECTED] [2002-03-27 23:14]:
  At 23:51 +0100 27 Mar 2002, Sven Guckes [EMAIL PROTECTED] wrote:
   * Charles Gagnon [EMAIL PROTECTED] [2002-03-27 20:07]:
or even
tag/delete everything older than number of days,
whatever is easier.
   this is not included - sorry.
  Wrong.  T~d5d will tag all messages older than 5 days.
 
 yes - but this is only relative to the *current* date.
 I understood that in the context of the given  question

Older than x days, to me means relative to the current day, no ambiguity
at all in my mind.

 this date shall be relative to a given day - no?

Mutt supports that as well.  See the bit about Error margins, right
before the bit about relative dates.

-- 
Aaron Schrab [EMAIL PROTECTED]  http://www.schrab.com/aaron/
 /earth is 98% full ... please delete anyone you can.



Re: Tag or delete by date or age - pattern ~d

2002-03-27 Thread David Champion

* On 2002.03.27, in [EMAIL PROTECTED],
*   Sven Guckes [EMAIL PROTECTED] wrote:
 
 apropos:
 anyone have a utility to calculate the
 number of days between two given dates?
 i mean - easily?  no perl script
 with dozens of modules, please!

shell$ ./timediff Wed Mar 27 17:33:00 2002 Wed Mar 22 11:02:19 2002
Difference is 5.27 days.

shell$ env TIMEFMT=%d %b %Y ./timediff 19 Feb 2001 21 Apr 2002
Difference is 426.00 days.

shell$ env TIMEFMT=%D ./timediff 1/1/70 12/31/79
Difference is 3651.00 days.

-- 
 -D.[EMAIL PROTECTED]NSITUniversity of Chicago


#include stdio.h
#include stdlib.h
#include time.h
#include string.h
#include sysexits.h

#define DEFAULT_FORMAT  %c

char *A0;

main(int argc, char *argv[])
{
time_t   t1, t2;
struct tmtm1, tm2;
char*p, *fmt = DEFAULT_FORMAT;

if (A0 = strchr(argv[0], '/'))
++A0;
else
A0 = argv[0];

if (argc != 3 || (argc  1  !strcmp(argv[1], -h))) {
fprintf(stderr, usage: %s \time1\ \time2\\n, A0);
exit(EX_USAGE);
}

if (p = getenv(TIMEFMT))
fmt = p;

if (strptime(argv[1], fmt, tm1) == NULL ||
strptime(argv[2], fmt, tm2) == NULL) {
fprintf(stderr, %s: bad date for format \%s\\n, A0, fmt);
exit(EX_DATAERR);
}
t1 = mktime(tm1);
t2 = mktime(tm2);

printf(Difference is %-.2f days.\n, (double)abs(t2-t1)/(60*60*24));
exit(EX_OK);
}