Gossamer Forum
Home : Products : Links 2.0 : Customization :

Deleting outdated, unused files automatically

Quote Reply
Deleting outdated, unused files automatically
Is it possible to delete unused or outdated files automatically?
E.g.:
1) for backup files, only keep only last X files, to prevent server space filling.
2) for What's new span files, to keep only those which is currently used, e.g. files created in last 7 days, the others should be deleted
(01-25-2000.html, 01-26-2000.=> html should keep, 12-23-1999 => should deleted)

Thanks,
Webmaster33
Quote Reply
Re: Deleting outdated, unused files automatically In reply to
Webmaster33,

Do you host your site on a NT or Unix server? It is quite simple to do in Unix with a find command and cron.

Frank

------------------
Webmasters Resources
http://www.webmasters-resources.com/
Quote Reply
Re: Deleting outdated, unused files automatically In reply to
nope, I don't host a server...
I have an ISP, and I don't have telnet access on it.

So it should solved by perl script within Links.

Webmaster33
Quote Reply
Re: Deleting outdated, unused files automatically In reply to
Widgetz wrote some codes for the nph-build.cgi file that compresses data files into a tar.gz file and only keeps up to the last five copies of these compressed files.

He posted the codes in the Discussion Forum.

Regards,

------------------
Eliot Lee....
Former Handle: Eliot
* Check Resource Center
* Search Forums
Quote Reply
Re: Deleting outdated, unused files automatically In reply to
This is exactly, what I'm looking for.
This can be used for the backup files.

For the date based span pages of What's new page, this can not used but if Widgetz would share this script with us, I could modify it to be used also for the What's new page.

Widgetz: is your script available for the public?

Thanks,
Webmaster33
Quote Reply
Re: Deleting outdated, unused files automatically In reply to
Uh...did you not even read my REPLY!? The codes are posted in the LINKS Discussion Forum. And he posted them about two months ago.

BTW: I believe that the codes Widgetz wrote can be adapted to delete files in other specified directories. And you can try using the delete function in Perl to do this as well.

Regards,

------------------
Eliot Lee....
Former Handle: Eliot
* Check Resource Center
* Search Forums


[This message has been edited by AnthroRules (edited February 27, 2000).]
Quote Reply
Re: Deleting outdated, unused files automatically In reply to
Really. I went over the sentence where you mentioned the Discussion forum. Sorry. Smile
I will try your suggestion.

Thanks, your help!
Webmaster33
Quote Reply
Re: Deleting outdated, unused files automatically In reply to
posted 02-27-00 01:24 PM PST

Quote:
Widgetz wrote some codes for the nph-build.cgi file that compresses data files into a tar.gz file and only keeps up to the last five copies of these compressed files.

He posted the codes in the Discussion Forum.

Regards,

------------------
Eliot Lee....
Former Handle: Eliot
* Check Resource Center
* Search Forums
Quote Reply
Re: Deleting outdated, unused files automatically In reply to
ok-ok Smile