New GIT user here, managing a Moodle course web site system on a Windows server. Trying to do my first Pull update of the core code (using TortoiseGit) and it's not working. Git is unable to unlink old versions of any the 200+ files to be updated because of an "invalid argument". I have no idea what that means.
Here's what it looks like after I dismiss 210 error dialogs: tortoisegit
I've rebooted the server and scoured the web for ideas, but I'm at a loss for what to try next.
Any ideas would be greatly appreciated!
I lost hours with that error too.
In my case, I got this error because some files was locked by another program. I had to close everything then I was able to pull again.
Hope this help someone :)
The error message shows the file name(s) that git was unable to unlink. In windows, you can go to Start Menu > Resource Monitor > CPU tab > Associated Handles
and search for the file name (not the full path), then you will get a result of the process locking that file. In my case, it was explorer.exe
. So I killed that process and git worked again as expected.
I guess you can do that same using other operating systems by finding the process(es) locking the file(s).
Try to close any other tools while using Tortoisegit
I also had unlink issues when trying to pull from gitlab.
Based on ivan866's and Nicolas Leucci's answer, to resolve I simply opened my SourceTree in administrative mode which fixed my problem. I suppose SourceTree didn't have enough rights to handle the permissions correctly. Anyway it's worth a try!
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With