Date: Thu, 11 Nov 2004 13:20:54 -0600 From: "Andrew L. Gould" <algould@datawok.com> To: freebsd-questions@freebsd.org, CHris Rich <freebsdnews@gmail.com> Subject: Re: Outputting command to a text file Message-ID: <200411111320.54864.algould@datawok.com> In-Reply-To: <8292450b04111111083132f845@mail.gmail.com> References: <8292450b04111111083132f845@mail.gmail.com>
next in thread | previous in thread | raw e-mail | index | archive | help
On Thursday 11 November 2004 01:08 pm, CHris Rich wrote: > I want to use the du command to check on the sizes of files in a > directory, but i want the output to be put into a text file so I can > look at it later. > > I did some search on google, and found nothing that applied. > Searched other places (lists and things) and couldn't find what i was > looking for, perhaps i was using the wrong search terms. > > Any help will be greatly appreciated > > Thanks You can redirect the output of commands into files using '>' and '>>'. du > du_results.txt The command above will send the output of du to the file du_results.txt The command creates du_results.txt, overwriting it if it already exists. To append results to existing files, use '>>'. du >> du_results This, and other cool information can be found in the man page for your chosen shell. Best of luck, Andrew
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200411111320.54864.algould>