简体   繁体   中英

no diff output when using “git diff HEAD file.c”

I'm trying to diff the modified file with the latest checked in version and this is the output I see:

$ git diff HEAD file.c
diff --git a/path/to/file.c b/path/to/file.c
old mode 100644
new mode 100755
index 5f8af1c..a828cb0
Binary files  a/path/to/file.c and b/path/to/file.c differ

I want to see the actual difference, can you please help me look at that?

The files are treated as binary files, possibly due to the text encoding. Make sure the files are saved with single byte character encoding, if they are indeed text files.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM