hardlink
hardlink copied to clipboard
Folders not getting deleted after unlinking - Finder
I am able to implement hardlinks on macOS using this command-line utility, but I am seeing an issue after unlinking an folder. Issue: Unable to delete the unlinked folder from finder (command used to unlink "hln -u destination") same folder can be deleted from terminal using "rm"
Any idea where the permission is getting changed ? and what might be the cause for this issue.
What version of command line tools are you using?
pkgutil --pkg-info=com.apple.pkg.CLTools_Executables
Not sure this is the right way to do it but I get: version: 8.2.0.0.1.1480973914
Version of command line tool is : 8.1.0.0.1.1476494586
I have even verified this using the latest version of Xcode command line tool
Are you compiling the source or installing via homebrew?
I just tried what you mentioned above. Can't reproduce this. What are the permissions on the folders?
Please try to replicating the issue in this way: Create a folder under /Users/user/Desktop/Unlinked-folder Source: /Users/user/Desktop/Unlinked-folder Destination: /Users/user/linked
Command to hard link folder: hln /Users/user/Desktop/Unlinked-folder /Users/user/linked/Unlinked-folder
Now if I try to delete the (source) /Users/user/Desktop/Unlinked-folder or (destination) /Users/user/linked/Unlinked-folder
I get promoted with admin credentials to authenticate, but even after giving the password the folders will remain without deleting:
Even after removing hard link i am unable to delete the source folder : /Users/user/Desktop/Unlinked-folder
Only way to delete is through terminal... running "rm -r"
Is this the normal behavior or am i missing any thing here..?
I had this issue too, when trying to delete the usual way in finder. a sudo rm -rf
works though
This may be a protection against orphaning files... Which version of macOS are each of you using?
I believe it was El Capitan. This was a year ago though, so I might be wrong.
My thinking is that if it was happening for you and @kulal but not for @jamespayne , and @jamespayne happened to be using an older macOS, that the issue might be something Apple implemented as a feature. @kulal, @jamespayne : ideas?