Thread View: news.software.readers
6 messages
6 total messages
Started by Mike Vanecek
Fri, 04 Jul 2003 15:02
slrn: my_posts
Author: Mike Vanecek
Date: Fri, 04 Jul 2003 15:02
Date: Fri, 04 Jul 2003 15:02
9 lines
1009 bytes
1009 bytes
The user account file my_posts contains a copy of all posted messages. Does anyone have a macro (similar to cleanscore) that periodically removes old messages? Otherwise, the file will grow without limit? Thanks. Mike.
Re: slrn: my_posts
Author: Jimchip
Date: Fri, 04 Jul 2003 15:22
Date: Fri, 04 Jul 2003 15:22
13 lines
1450 bytes
1450 bytes
On 4 Jul 2003 10:02:58 -0500, Mike Vanecek wrote: > The user account file my_posts contains a copy of all posted messages. > Does anyone have a macro (similar to cleanscore) that periodically > removes old messages? Otherwise, the file will grow without limit? I do mine manually. I cp My_Posts MyPosts[date of backup], rm My_Posts, touch My_Posts. Not very elegant but it has been useful for me to archive my old posts. -- Anyone outside my light-cone is dead to me. That's just a rule I have. (lifted from /. Posted by jamie.)
Re: slrn: my_posts
Author: Tim Hammerquist
Date: Fri, 04 Jul 2003 19:51
Date: Fri, 04 Jul 2003 19:51
34 lines
2145 bytes
2145 bytes
Jimchip graced us by uttering:
> Mike Vanecek wrote:
> > The user account file my_posts contains a copy of all posted
> > messages. Does anyone have a macro (similar to cleanscore)
> > that periodically removes old messages? Otherwise, the file
> > will grow without limit?
>
> I do mine manually. I cp My_Posts MyPosts[date of backup], rm
> My_Posts, touch My_Posts.
>
> Not very elegant but it has been useful for me to archive my
> old posts.
The following short script does the same, which the added
advantage that all permissions for the original file are
preserved (though the new file will not necessarily retain those
of the original).
$ cat bin/arch_file.sh
#!/bin/sh
name="$1"
cp "$name" "$name-`date '+%G%m%d'`"
echo -n > "$name"
$ arch_file.sh My_Posts
$ ls -l
total 14
-rw------- 1 user users 0 2003-07-04 12:41 My_Posts
-rw------- 1 user users 2350 2003-07-04 12:38 My_Posts-20030704
HTH,
Tim Hammerquist
--
"You! Invaders! Get you the hot bullets of shotgun to die!"
-- caption from Battle Rangers video game
Re: slrn: my_posts
Author: Blinky the Shark
Date: Fri, 04 Jul 2003 20:26
Date: Fri, 04 Jul 2003 20:26
16 lines
1435 bytes
1435 bytes
Tim Hammerquist wrote: > $ cat bin/arch_file.sh > #!/bin/sh > name="$1" > cp "$name" "$name-`date '+%G%m%d'`" > echo -n > "$name" Cool beans. Installed. Didn't even add any registry keys. ;) -- Blinky Linux RU 297263 Spam: The Boulder Pledge http://snurl.com/boulder All In The Family http://snurl.com/familything
Re: slrn: my_posts
Author: Mike Vanecek
Date: Sat, 05 Jul 2003 19:38
Date: Sat, 05 Jul 2003 19:38
34 lines
2018 bytes
2018 bytes
On 4 Jul 2003 12:51:15 -0700, Tim Hammerquist wrote: > Jimchip graced us by uttering: >> Mike Vanecek wrote: >> > The user account file my_posts contains a copy of all posted >> > messages. Does anyone have a macro (similar to cleanscore) >> > that periodically removes old messages? Otherwise, the file >> > will grow without limit? >> >> I do mine manually. I cp My_Posts MyPosts[date of backup], rm >> My_Posts, touch My_Posts. >> >> Not very elegant but it has been useful for me to archive my >> old posts. > > The following short script does the same, which the added > advantage that all permissions for the original file are > preserved (though the new file will not necessarily retain those > of the original). > > $ cat bin/arch_file.sh > #!/bin/sh > name="$1" > cp "$name" "$name-`date '+%G%m%d'`" > echo -n > "$name" > $ arch_file.sh My_Posts > $ ls -l > total 14 > -rw------- 1 user users 0 2003-07-04 12:41 My_Posts > -rw------- 1 user users 2350 2003-07-04 12:38 My_Posts-20030704 That will work. I'll just do a bit of cron magic with it too. Thanks.
Re: slrn: my_posts
Author: Tim Hammerquist
Date: Sat, 05 Jul 2003 20:07
Date: Sat, 05 Jul 2003 20:07
17 lines
1398 bytes
1398 bytes
Mike Vanecek graced us by uttering: > Tim Hammerquist wrote: >> The following short script... [ snippage ] > > That will work. I'll just do a bit of cron magic with it too. Ah, the beauty of the Unix Philosophy! > Thanks. np. Tim Hammerquist -- now playing at vegeta.ath.cx: (The Cure) Six Different Ways [1:55]
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads