Re: [mail_lists] Re: cleaning out files

2003-04-05 Thread Jim
On Friday 04 April 2003 02:39, Stijn Hoop wrote: The best way is simply doing: bash]$ > filename This clears the file out without destroying any open file descriptors on the file. - Jim | On Fri, Apr 04, 2003 at 12:27:46PM +0200, CARTER Anthony wrote: | > How do I clean the contents of text f

Re: cleaning out files

2003-04-04 Thread parv
in message <[EMAIL PROTECTED]>, wrote Jan Grant thusly... > > On Fri, 4 Apr 2003, CARTER Anthony wrote: > > > How do I clean the contents of text files without actually > > removing the files? > > man 1 truncate > > This is a command-line utility that directly wraps the appropriate > system call

Re: cleaning out files

2003-04-04 Thread Jan Grant
On Fri, 4 Apr 2003, CARTER Anthony wrote: > How do I clean the contents of text files without actually removing the files? man 1 truncate This is a command-line utility that directly wraps the appropriate system call. -- jan grant, ILRT, University of Bristol. http://www.ilrt.bris.ac.uk/ Tel

Re: [mail_lists] Re: cleaning out files

2003-04-04 Thread CARTER Anthony
Yep, I want to clean out my log files in /var/log, but some of the log files don't get re-created automatically (I get errors at bootup about some logs not existing) if I just rm them. Thanks, Anthony On Friday 04 April 2003 13:00, Jim wrote: > On Friday 04 April 2003 02:39, Stijn Hoop wrote:

Re: [mail_lists] Re: cleaning out files

2003-04-04 Thread Stijn Hoop
On Fri, Apr 04, 2003 at 03:00:52AM -0800, Jim wrote: > The best way is simply doing: > > bash]$ > filename > > This clears the file out without destroying any open file descriptors on the > file. Does echo -n 'destroy' an open file descriptor on the file? Does the above work with other shells?

Re: cleaning out files

2003-04-04 Thread Stijn Hoop
On Fri, Apr 04, 2003 at 12:27:46PM +0200, CARTER Anthony wrote: > How do I clean the contents of text files without actually removing the files? $ echo -n > $FILE Works for me, there are various other ways. You will end up with a 0-byte file, is that what you mean by 'cleaning'? --Stijn -- I r

cleaning out files

2003-04-04 Thread CARTER Anthony
How do I clean the contents of text files without actually removing the files? Thanks, Anthony ___ [EMAIL PROTECTED] mailing list http://lists.freebsd.org/mailman/listinfo/freebsd-questions To unsubscribe, send any mail to "[EMAIL PROTECTED]"