Support --textconv option for "git show" command in Git Graph
I created a 3rd party tool to convert Excel file to text format to track changes. So, *.xlsx file is registered with textconv attribute in ~/.gitconfig and ~/.gitattributes as below.
[diff "excel"]
textconv = /usr/local/bin/excel2csv
*.xlsx diff=excel -text
*.xls diff=excel -text
Then, locally in terminal, I can use "git diff 1.xlsx 2.xlsx" to compare two Excel files quickly because they will converted to TEXT format first.
However, in Git Graph view, I checked out the command history when I clicked an Excel file.
It's like: git show 8f65c473ea5d8d98a86d43ffcd91aa91e4b4c532:Resources/XX.xlsx
Of course, the output is messy because it's taken as a binary format, no conversion first.
This problem makes VSCode diff suspending for a long time ... never exit
Then, I manually executed it terminal, the result came out quickly, but not readable.
Then, I added --textconv option, the result came out soon with clear text format, that's what I wanted.
git show --textconv 8f65c473ea5d8d98a86d43ffcd91aa91e4b4c532:XX.xlsx
I wonder if this can be a feature request:
Detect the target file format, if it has textconv attribute, then add --textconv option to git show while starting git diff in Git Graph View.
This issue puzzled me for months, I appreciate a lot for the consideration! If possible, I can help do some validation.
Best Regards,
ML
Support --textconv option for "git show" command in Git Graph
I created a 3rd party tool to convert Excel file to text format to track changes. So, *.xlsx file is registered with textconv attribute in ~/.gitconfig and ~/.gitattributes as below.
[diff "excel"]
textconv = /usr/local/bin/excel2csv
*.xlsx diff=excel -text
*.xls diff=excel -text
Then, locally in terminal, I can use "git diff 1.xlsx 2.xlsx" to compare two Excel files quickly because they will converted to TEXT format first.
However, in Git Graph view, I checked out the command history when I clicked an Excel file.
It's like: git show 8f65c473ea5d8d98a86d43ffcd91aa91e4b4c532:Resources/XX.xlsx
Of course, the output is messy because it's taken as a binary format, no conversion first.
This problem makes VSCode diff suspending for a long time ... never exit
Then, I manually executed it terminal, the result came out quickly, but not readable.
Then, I added --textconv option, the result came out soon with clear text format, that's what I wanted.
git show --textconv 8f65c473ea5d8d98a86d43ffcd91aa91e4b4c532:XX.xlsx
I wonder if this can be a feature request:
Detect the target file format, if it has textconv attribute, then add --textconv option to git show while starting git diff in Git Graph View.
This issue puzzled me for months, I appreciate a lot for the consideration! If possible, I can help do some validation.
Best Regards,
ML