This is on MacOS Catalina, but the same behavior has been observed in prior versions of MacOS.
Similar questions have been asked for other default directories in the default home directory, but this is different. I am able to delete most of the other directories:
~/Movies all went away after I removed any ACL's from them. But
~/Pictures is different, and no matter what I do, MacOS refuses to delete it.
bash-5.0# /bin/ls -led Pictures drwxrwxr-x 2 MyLogin MyGroup 64 Nov 5 18:17 Pictures bash-5.0# /bin/ls -lea Pictures total 0 drwxrwxr-x 2 MyLogin MyGroup 64 Nov 5 18:17 . drwxr-xr-x+ 72 MyLogin MyGroup 2304 Nov 5 18:17 .. 0: group:everyone deny delete
Note that the last ACL is applied to the parent directory of
~/Pictures ie. my home directory, and that is not the cause of this behavior as I am able to delete other subdirectories without trouble.
This also does not appear to be a restriction imposed by System Integrity Protection:
bash-5.0# /bin/ls -leOd /usr/bin drwxr-xr-x 1014 root wheel restricted 32448 Oct 23 01:19 /usr/bin bash-5.0# /bin/ls -leOd Pictures/ drwxrwxr-x 2 MyLogin MyGroup - 64 Nov 5 18:23 Pictures/ bash-5.0# /bin/ls -leOa Pictures/ total 0 drwxrwxr-x 2 MyLogin MyGroup - 64 Nov 5 18:23 . drwxr-xr-x+ 72 MyLogin MyGroup - 2304 Nov 5 18:23 .. 0: group:everyone deny delete
restricted attribute on
/usr/bin which is protected by SIP.
~/Pictures has no such attribute.
I've tried as root, as my normal user account, and even as a different user after setting the permission 777. Nothing works.
My question is: what is protecting
~/Pictures from deletion, and how can I turn it off?