So I'm on my branch internal_env_board2 and I'm trying to switch to branch battery_board. However, when I attempt to do so I get an error:
$ git checkout battery_board
error: Your local changes to the following files would be overwritten by checkout:
internal_env_board/internal_env_board2/internal_env_board_with_LCD_BOM.xlsx
Please commit your changes or stash them before you switch branches.
Aborting
I'm pretty annoyed because I know I haven't modified this .xlsx file. The only thing I did was open up the excel file, view its contents, and close it again. For some reason git thinks that there are changes in this file. I tried using git diff to find the differences between the working tree copy and the most recent committed copy and got the following:
$ git diff HEAD internal_env_board_with_LCD_BOM.xlsx
diff --git a/internal_env_board/internal_env_board2/internal_env_board_with_LCD_BOM.xlsx b/internal_env_board/internal_env_board2/internal_env_board_with_LCD_BOM.xlsx
index 0fb3369..10c945e 100644
Binary files a/internal_env_board/internal_env_board2/internal_env_board_with_LCD_BOM.xlsx and b/internal_env_board/internal_env_board2/internal_env_board_with_LCD_BOM.xlsx differ
I'm having a lot of trouble making sense of the output of of this diff command. It just tells me that they differ, but not how.
So I guess my two questions are:
1. Why does git think that I have modified a file just because I opened it?
2. How do I read the output of the git diff HEAD
command?