copy/mv directory to another directory in git

Viewed 28394

I have a

dir1/ contains a lot files and subdirecties, I want to change the directory name to dir2/ . I tried

git mv dir1/ dir2/

I got this message:

fatal: renaming 'dir1' failed: Permission denied

update:

I ran from git for windows command line http://code.google.com/p/msysgit/
What is the correct command?

5 Answers

It could also be that the directory (or a file within) is being used by another program, which prevents you from doing anything with that folder. Only on Windows, obviously.

Use the Process Explorer if you're unsure which program has captured that directory/file.

Related