Although this procedure is more complete than the previous one it has caveats of its own. In addition the issue mentioned above with respect to programs that store settings based on your short username there are also programs—in fact more programs—that store settings or preferences based on the path to your home folder. If you change the name of your home folder that path changes (from /Users/oldname to /Users/newname) and thus those settings are no longer valid. However as before the solution is usually as simple as viewing the settings interface for the offending program or service and changing whatever setting is causing the problem.
Finally changing the name of your home folder also has ramifications for Time Machine which tracks files based on their paths. If you change the name of your home folder the path to every file in your home folder changes so Time Machine will back up every file again.
If you still want to go all the way here are the steps to follow; note that these instructions assume your home folder is located in /Users:
- If Automatic Login is enabled (in Accounts preferences) for the account you’re modifying disable it. Similarly if File Vault is enabled (in Security preferences) disable it. You can re-enable these features if desired after completing the procedure.
- Log in as a different user than the one you want to modify; make sure the account you want to modify is not logged in.
- Open the Accounts pane of System Preferences.
- If the lock icon in the lower-left of the Accounts window is “locked ” click on it and provide an administrative username and password; this allows you to make changes.
- In the list of accounts on the left right-click (or Control-click) on the name of the account you want to modify; choose Advanced Options from the resulting menu.
- In the Advanced Options screen delete your current short username in the Short Name field and then type in your desired new short username.
- In the Home Directory field change /Users/oldusername to/Users/newusername where oldusername is your original short username and newusername is your new short username. Make note of the original and new paths.
- Click on OK and close System Preferences.
- Open Terminal (in /Applications/Utilities).
- Type the following command all on one line and then press Return; when prompted provide the password of the admin account you’re currently using and then press Return again:
sudo mv /Users/oldusername /Users/newusername
(These are the original and new Home Directory paths from Step 7;oldusername is your original short username and newusername is your new short username.) This step renames your home folder in the Finder.
- Restart your Mac.