[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: chown question



Douglas A. Tutty wrote:
[...]
> I know that I could have used find to look for all files owned by the
> old UID, plunked it through xargs and chowned them that way, but is
> there a way, as root, to chown directly the hidden files without
> chowning the whole box?
> 
> Just for my future reference?

I found this suggestion from some message board*

$ chown user:group .[!.]*

That uses the shell pattern matching to exclude '..' by skipping any files whose
second character is a dot. Unfortunately it will also skip any hidden files with
names like '..filename'

*http://forums11.itrc.hp.com/service/forums/questionanswer.do?admit=109447626+1246551046034+28353475&threadId=966579

- Chris B


Reply to: