From: dorayme on
Is it possible to *batch* change permissions on a whole lot of
*locked files and folders* which can be done OK one by one by
Getting Info and unlocking after entering password and then
manually changing?

--
dorayme
From: Bob Harris on
In article <dorayme-4C01DB.06354614032010(a)news.albasani.net>,
dorayme <dorayme(a)optusnet.com.au> wrote:

> Is it possible to *batch* change permissions on a whole lot of
> *locked files and folders* which can be done OK one by one by
> Getting Info and unlocking after entering password and then
> manually changing?

From a Terminal session

find "/path/to/1st/dir" -flags uchg -print0 |\
xargs -0 chflags nouchg

You can use

ls -RleOa@ "/path/to/1st/dir"

to see the permissions on all the files. -R all subdirectories,
-l long ls format, -e show the ACLs, -O (capital O) show the
flags, of which the Lock (aka uchg) is one, -a show Unix hidden
files (starts with a dot), -@ show extend attributes.

If you just want to see the files which are Locked

find "/path/to/1st/dir" -flags uchg

If you want to see just the Locked files, and their permissions

find "/path/to/1st/dir" -flags uchg -print0 |\
xargs -0 ls -dleO@

Where the -d prevents listing the contents of directories, and you
do not need the -a as 'find' does not ignore Unix hidden files,
and in this mode, ls is being explicitly asked to give info about
a Unix hidden file.

If you want a more GUI'fied approach, then put this inside of an
Automator workflow using "Run Shell Script".

Bob Harris
From: dorayme on
In article <michelle-1E2C6B.12535613032010(a)nothing.attdns.com>,
Michelle Steiner <michelle(a)michelle.org> wrote:

> In article <dorayme-4C01DB.06354614032010(a)news.albasani.net>,
> dorayme <dorayme(a)optusnet.com.au> wrote:
>
> > Is it possible to *batch* change permissions on a whole lot of
> > *locked files and folders* which can be done OK one by one by
> > Getting Info and unlocking after entering password and then
> > manually changing?
>
> Yes. Select all of them (however, you can not mix files and folders), then
> press command-option-I to open the Inspector. Double click on the lock
> icon in the lower right corner, and enter your password in the resulting
> dialog.
>
> You can then manually change permissions, lock, etc., on all of the
> selected files or folders together. For permissions, though, you will need
> to double-click the popup menu, rather than single click as with the Get
> Info window.

Thanks for this, appreciate it. Will save me heaps of work in
future.

--
dorayme
From: dorayme on
In article
<nospam.News.Bob-6181ED.15015813032010(a)news.eternal-september.org
>,
Bob Harris <nospam.News.Bob(a)remove.Smith-Harris.us> wrote:

> In article <dorayme-4C01DB.06354614032010(a)news.albasani.net>,
> dorayme <dorayme(a)optusnet.com.au> wrote:
>
> > Is it possible to *batch* change permissions on a whole lot of
> > *locked files and folders* which can be done OK one by one by
> > Getting Info and unlocking after entering password and then
> > manually changing?
>
> From a Terminal session
>
....

> If you want to see just the Locked files, and their permissions
>
> find "/path/to/1st/dir" -flags uchg -print0 |\
> xargs -0 ls -dleO@
>
> Where the -d prevents listing the contents of directories, and you
> do not need the -a as 'find' does not ignore Unix hidden files,
> and in this mode, ls is being explicitly asked to give info about
> a Unix hidden file.
>
> If you want a more GUI'fied approach, then put this inside of an
> Automator workflow using "Run Shell Script".
>
>

Thanks, I will store your instructions. I *think* the simple
thing Michelle said should do me for now.

--
dorayme
From: dorayme on
In article <michelle-89CD95.17344813032010(a)nothing.attdns.com>,
Michelle Steiner <michelle(a)michelle.org> wrote:

> In article <dorayme-CCFCD9.11070814032010(a)news.albasani.net>,
> dorayme <dorayme(a)optusnet.com.au> wrote:
>
> > Thanks for this, appreciate it. Will save me heaps of work in
> > future.
>
> De nada. The Finder's Inspector window is one of the little-known useful
> features of the Finder.
>
> Let us know how it went.

I did test your suggestion on this main work machine of mine on
Tiger and it certainly worked.

Perhaps more than you wanted to know but the question was
prompted by further attempts by me (at 4 am this morning) to
tweak my migration stuff to my MB on Snow. I should know better
than to futz about like I did, dangerously option copying whole
libraries and stuff! It was partially successful - and would have
been a whole lot easier if I had known (or remembered... a faint
feeling of deja vu here) about Inspector!

On more sleep and reflection, I decided to stop trying to
outsmart OS X and wiped the whole MB HD clean and reinstalled
Snow and I will use Migrant Assistant again now that I know
better a few pitfalls I encountered last time.

--
dorayme