On Sun, 8 Mar 2009, Major P?ter wrote:

The main problem with du is, that it doesn't care with users, so I need a "find" before (using the -user will solve the problem). But I can't use du `find ...` because it will contain the subfolders too, so it will duplicate, and the measure won't be correct. (Or if I'm use the --max-depth option it will still not care with the user filtering).
So by now I have this:
du `find . -type f -user foobar`
using sed, and a for cycle I can make a sum from this values.
But now, I don't have the sizes of the directories, so that's why I tried to use: ls `find . -type d -user foo -name "*"` # -name "*" will be removed in the final version
but didn't worked, so I wrote here a mail.
If you know a better way, please just send me a command or parameter name, because this is my homework. :)

I don't expect this list will do your homework for you, however... you can get all the required information about users and filesizes from find's -printf action.


Cheers,
Phil


_______________________________________________
Bug-coreutils mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/bug-coreutils

Reply via email to