git diff --name-status does not always list changed files

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi,

I was getting a lot of "no newline at end of file" warnings with GCC, so I decided to fix these files in my clean working tree with

for i in `find . -iname "*.c" -o -iname "*.cc" -o -iname "*.cpp" -o -iname "*.h" -o -iname "*.hpp"`; do
    echo $i
    echo wq | ed $i > /dev/null 2>&1
done

Afterwards, I wanted so see a list of files that were actually affected, but to my wonderment "git diff --name-status" did not list any files, although both "git diff" and "gitk" showed the diffs correctly.

Is this a bug in "--name-status" that is does not detected changes if only a final newline has been added, or am I missing something?

Thanks.

--
Sebastian Schuberth

--
To unsubscribe from this list: send the line "unsubscribe git" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Kernel Development]     [Gcc Help]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [V4L]     [Bugtraq]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]     [Fedora Users]

  Powered by Linux