Set home directory permissions via Terminal
I recently moved my home directory to a dedicated hard drive. I used “Advanced Options” in the "Accounts" System Preference of OS X 10.5.2, to point to a directory /Volumes/Home/users/myusername. Default permissions for all of my top level folders was fine (music, documents, etc.) since I let the OS create my home directory folder for me. However, after I copied all of my data to the new home directory, things got messy. I was logged in to OS X as root when I did the copy, so all of my files and folders were owned by root. I ran chown -R myusername myusername, and it seemed to work, but I want to make sure that there isn't a better way, especially since Leopard now uses ACL's. Also, some files in my home directory have a "Locked" flag when I go to a file or folder's "Get Info" window. Is there a way to get rid of this via the command line as well?
I guess my question really boils down to - What command do I need to run via the command line in order to get all files and folders in my home directory back to the correct set of permissions, including ACL's. I’d like things to be set the way they would have been set if I installed a fresh copy of the OS and recreated all of my data from scratch. Also, how do I remove the "Locked" flag from files and folders via the command line?
Thanks
Bobby
I guess my question really boils down to - What command do I need to run via the command line in order to get all files and folders in my home directory back to the correct set of permissions, including ACL's. I’d like things to be set the way they would have been set if I installed a fresh copy of the OS and recreated all of my data from scratch. Also, how do I remove the "Locked" flag from files and folders via the command line?
Thanks
Bobby
Mac Pro Quad 2.66, Mac OS X (10.5.2)