From: Daniel Berger Date: 2005-02-05T02:30:42+09:00 Subject: Re: cross platform method to obtain disk usage Caio Tiago Oliveira wrote: > Robert Klemme, 4/2/2005 13:50: > > "Tim Ferrell" schrieb im Newsbeitrag > > news:4203A207.7040102@mcgeecorp.com... > >> I am working on something where one of the requirements is to manage > >> disk usage (kind of a rotating backup thing) and I was wondering if > >> anyone could point me in the right direction for determining disk usage > >> from Ruby. > >> > >> I have been tinkering with using syscall (I am on Linux) but ultimately > >> I'd like to find a way to do this on Windows as well... Any thoughts? I > >> am not against using C if necessary, but perhaps that can be avoided? > > :-) > > > > Hm, probably this is helpful: > > http://raa.ruby-lang.org/project/filesystem/ > > The page says: "Tested on Linux and Solaris.". > I don't think it works on windows. > > "'statvfs' and 'getmntent'"... I've tested it on FreeBSD and HP-UX as well. No, it doesn't work on Windows. I've been mulling over a win32-filesystem package for win32utils, but I don't know that it's realistic to keep a unified API between *nix and Win32. But, I'll mull it over. Regards, Dan