sublime_merge icon indicating copy to clipboard operation
sublime_merge copied to clipboard

.gitattributes is not parsed correctly for LFS files

Open t4n0 opened this issue 1 year ago • 1 comments

Version info

  • OS: Ubuntu 24.04
  • Build: 2096

Description

.gitattributes is not parsed correctly for LFS files

Steps to reproduce

Given

  1. init a fresh git repo
  2. commit the following content (*) to .gitattributes:

* filter=lfs diff=lfs merge=lfs -text **/*.txt filter= diff= merge= text

  1. commit the following content to foo.txt:

asdf

When touch foo.txt

Then

  • foo.txt file will be labeld as LFS (even though it is not saved there)
  • foo.txt will be depicted as modified due to "line-endings changed since checkout"

Note that running "git status" will resolve these "false positives".

Expected behavior

Not labeled as LFS and line endings interpreted correctly.

Screenshots

image

Disclaimer

(*) Yes, I know its a weird thing to do. Rest assured: Its not my invention.

t4n0 avatar Oct 15 '24 12:10 t4n0

Hi @t4n0,

Thanks for reaching out and reporting this issue. I'll be investigating this further and will reach out when I've got more information.

Cheers, - Dylan from Sublime HQ

dpjohnst avatar Oct 16 '24 03:10 dpjohnst