Git issues when cloning any repo. Resource unavailable and when trying to check out new branch every file contains warning of : unable to unlink.
Searched for solution and couldn't find anything with this exact issue.
My git version is:
git version 2.15.2 (Apple Git-101.1)
The errors and warnings received when cloning a repo below.
Cloning into 'repo'...
remote: Counting objects: 11812, done.
remote: Compressing objects: 100% (4191/4191), done.
remote: Total 11812 (delta 4965), reused 10164 (delta 4474)
Receiving objects: 100% (11812/11812), 3.21 MiB | 1.18 MiB/s, done.
Resolving deltas: 100% (4965/4965), done.
warning: unable to unlink '/Users/myusername/Workspace/repo/.git/config.lock': Resource temporarily unavailable
error: could not write config file /Users/myusername/Workspace/repo/.git/config: Resource temporarily unavailable
warning: unable to unlink '/Users/myusername/Workspace/repo/.git/objects/pack/pack-
44eb34891f78eafbe39cee406ff6c4d694465be4.keep': Resource temporarily
unavailable
Assuming this is something related to permissions however I have write permissions on .git also experiencing a similar issue on gradle as I build projects.
Following error:
Caused by: java.io.FileNotFoundException:
/Users/username/.gradle/caches/modules-2/metadata-2.58/module-metadata.bin (Resource temporarily unavailable)
Hoping someone may have experienced something similar and a possible solution.