Hi
Can someone tell me if it’s possible to use AppleScript to change the Group Privileges of a file from Read Only to Read/Write - if so how do you do it?
Thanks!!
Sorry, I meant the files privileges, not ownership…
This might work:
tell application "Finder" to set group privileges of file "path:to:file" to read write
– Rob
Or, of course:
do shell script "chmod g+w " & quoted form of posix path of theFile
Thanks for that - I’m using a watched folder rather than file path so (e.g., on adding folder items to etc etc) Can you suggest how I would do this? I’ve experimented but it doesn’t seem to work
Thanks
Howard
Thanks for that - I’m using a watched folder rather than file path so (e.g., on adding folder items to etc etc) Can you suggest how I would do this? I’ve experimented but it doesn’t seem to work
This should work.
on adding folder items to this_folder after receiving these_items
repeat with this_item in these_items
tell application "Finder" to set group privileges of this_item to read write
end repeat
end adding folder items to
This should work.]
Worked perfectly thanks!!