From: "Jesús Gabriel y Galán" Date: 2007-10-05T15:24:45+09:00 Subject: Re: Human readable file sizes On 10/4/07, Daniel Waite wrote: > Jesús Gabriel y Galán wrote: > > I have a list of files and I need to produce a string containing the > > size of each file, but in human readable format. With that I mean > > something like what df -h does: make an approximation to the nearest > > unit (B, KB, MB, GB, etc). Is this already done somewhere? > > http://api.rubyonrails.org/classes/ActionView/Helpers/NumberHelper.html#M000525 Thanks to everybody who answered. I think I'll go with the action view helper, cause it's already done :-). Thanks again, Jesus.