Note that there are some explanatory texts on larger screens.

plurals
  1. PO
    text
    copied!<p>This problem only occurs when rename detection fails.</p> <p><a href="http://thread.gmane.org/gmane.comp.version-control.git/235889" rel="nofollow">http://thread.gmane.org/gmane.comp.version-control.git/235889</a></p> <p>It just so happens that git disabled rename detection of empty files in git 1.8. <a href="https://github.com/git/git/commit/4f7cb99ada26be5d86402a6e060f3ee16a672f16" rel="nofollow">https://github.com/git/git/commit/4f7cb99ada26be5d86402a6e060f3ee16a672f16</a> </p> <p>This script runs as expected on git 1.7 and git 1.8:</p> <pre><code>#!/bin/sh -x # create git repo git --version rm -rf caps git init caps cd caps git config --get core.ignorecase # commit empty file called "file" echo file &gt; file git add . git commit -am "initial commit" # create branch called "branch" git branch branch # rename "file" to "File" # using --force per http://stackoverflow.com/questions/6899582 git mv --force file File git commit -am "renamed to File" # switch to branch, make a non-conflicting commit git checkout branch echo newfile &gt; newfile git add . git commit -am "branch commit" # merge master into branch, commit merge GIT_EDITOR=true git merge --verbose --commit master ls File git status </code></pre> <p>But this script fails, due to a bug in git:</p> <pre><code>#!/bin/sh -x # create git repo git --version rm -rf caps git init caps cd caps git config --get core.ignorecase # commit empty file called "file" echo file &gt; file git add . git commit -am "initial commit" # create branch called "branch" git branch branch # rename "file" to "File" # using --force per http://stackoverflow.com/questions/6899582 git mv --force file File echo "completely different content" &gt; File git commit -am "renamed to File" # switch to branch, make a non-conflicting commit git checkout branch echo newfile &gt; newfile git add . git commit -am "branch commit" # merge master into branch, commit merge GIT_EDITOR=true git merge --verbose --commit master ls File git status </code></pre>
 

Querying!

 
Guidance

SQuiL has stopped working due to an internal error.

If you are curious you may find further information in the browser console, which is accessible through the devtools (F12).

Reload