On Sat, 2002-06-22 at 20:34, J. Lundeen wrote: > Hello, > > I'm writing a control panel for my web hosting company. I need to be > able to calculate how much disk space a user is taking up in their home > directory and its sub-directories, so that I can compare against the > "allowed" disk space of the selected hosting plan. > > I'm aware of the shell command: du -hs foldername > > But is there an easy way to get the info into Perl so that I can use it > in a calculation?
use the backticks or qx//: my ($diskspace) = split ' ', qx/du -hs $foldername/; -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]