From mboxrd@z Thu Jan 1 00:00:00 1970 Date: Tue, 29 Dec 2009 07:59:52 -1000 From: Tim Newsham To: Fans of the OS Plan 9 from Bell Labs <9fans@9fans.net> In-Reply-To: <20091228230510.GA25423@machine> Message-ID: References: <20091228230510.GA25423@machine> MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII; format=flowed Subject: Re: [9fans] du and find Topicbox-Message-UUID: b389c506-ead5-11e9-9d60-3106f5b1d025 > It is suggested to use > du -a | awk '{print $2}' > instead of find. But what if filename contains spaces? For example if > file is named "foo bar" then awk will output "foo" only. What about du -a | sed 's/^[0-9]*//g' no loss on spaces in filenames. no loss on tabs in filenames. Tim Newsham | www.thenewsh.com/~newsham | thenewsh.blogspot.com