🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: news.software.readers
Article #127824

Re: slrn: my_posts

#127824
From: Mike Vanecek
Date: Sat, 05 Jul 2003 19:38
34 lines
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.
Technical Details
Message-ID: <8kljt-i4j.ln1@news.invalid.99computer>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.readers.20140922.mbox.gz!news5.aus1.giganews.com!firehose2!nntp4!intern1.nntp.aus1.giganews.com!border1.nntp.aus1.giganews.com!nntp.giganews.com!newsfeed.news2me.com!newsfeed2.easynews.com!newsfeed1.easynews.com!easynews.com!easynews!newscene!novia!novia!sequencer.newscene.com!not-for-mail
References: <tahgt-c95.ln1@news.invalid.99computer> <vgb6ub8je3mr25@news.supernews.com> <slrnbgbmkc.42f.tim@vegeta.ath.cx>

Show Full Headers
Complete Article Headers
Message-ID: <8kljt-i4j.ln1@news.invalid.99computer>
Subject: Re: slrn: my_posts
Date: Sat, 05 Jul 2003 19:38:15 +0000
From: Mike Vanecek <MikeV99@privacy.net>
References: <tahgt-c95.ln1@news.invalid.99computer> <vgb6ub8je3mr25@news.supernews.com> <slrnbgbmkc.42f.tim@vegeta.ath.cx>
Path: mbox-mo1.pugleaf.net!archive.usenet.blueworldhosting.com!illumos!news.pugleaf.net!.TX!archive.pugleaf.net!archive.newsdeef.eu!mbox2nntp-news.software.readers.20140922.mbox.gz!news5.aus1.giganews.com!firehose2!nntp4!intern1.nntp.aus1.giganews.com!border1.nntp.aus1.giganews.com!nntp.giganews.com!newsfeed.news2me.com!newsfeed2.easynews.com!newsfeed1.easynews.com!easynews.com!easynews!newscene!novia!novia!sequencer.newscene.com!not-for-mail
Newsgroups: news.software.readers
Lines: 34
X-Archive: encrypt
User-Agent: slrn/0.9.7.4 (Linux)