What is the problem with it?
If a directory listing finds Foobar
file when git expects FooBar
, git will assume it's really the same file, and continue to remember it as Foobar
.
Two Steps approach
-
Move your file aside in some tmp folder or with some suffix & commit it:
mv Foobar Foobar_tmp git add -A git commit -m "renaming phase1"
-
Rename your file, move it back & commit.
mv Foobar_tmp FooBar git add -A git commit --amend -m "renamed Foobar to FooBar"
That's it.
Now into your git repository you'll see at once that Foobar
was renamed into FooBar
,
but not just modified as previously.
It means, that since your teammates will pull your pushed changes,
their Foobar
file will really change the name to FooBar
.
No comments:
Post a Comment