So to answer my own question, and maybe help someone else. I did a slightly more involved process and got what looks like most things working. This is going to be a bit more of a developer solution I'm afraid though:
what finally worked for me was to follow basically the article, but then recursively chown files and folders still owned by the previous user. I used a script which recursively checks a directory and contents if the user is the old one and if so change (chown) to the new one, but there is an additional step I had first to disable csrutil (system integrity check) to achieve this since some things a locked/restricted, and you have to do that in recovery mode. I'll post the bash script and the directories I ran this on.
1) reboot into a different admin user from the one you are changing, rename the home directory and then the user account as specified in the apple article.
2) reboot into recovery mode, open terminal type: csrutil disable (will ask you for a user and a password, use the admin one where you are going to perform this)
3) run the bash script below on the following directories (script will take a while depending on how many files etc. are in there)
- /Applications
- /Library
- /private/var
- /usr/local
create this bash file (I use nano as it's built in), so on the command line (terminal)
something like: touch doit.bash
then: sudo nano doit.bash
then copy and paste the code below into nano with the changed values, you will need to update the script for each directory you want to run it on.
save the script and exit nano.
To be able to execute the script you will need to then: chmod +x doit.bash
then run the script with: ./doit.bash
#!/bin/bash
olduser=oldusername # replace oldusername with your old username
newuser=newusername # replace newusername with your new username
dir=thedir # replace thedir with the directory you want to run through e.g. /Applications
find $dir | while read filename
do
owner=$(stat "$filename" | cut -d ' ' -f 5)
if [ $owner == $olduser ]
then
chown $newuser $filename
fi
done
4) Reboot into recovery, and open terminal and re-enable csrutil with: csrutil enable
5) reboot into your changed user, hopefully all preferences etc are preserved.
I really don't get why apple doesn't automate this process.
anyway good luck, hopefully helps someone else!