JUSTIGNOREME
V2EX  ›  问与答

Git LFS 为什么会自动追踪所有的空文件,是 bug 还是 feature ?

  •  
  •   JUSTIGNOREME · Nov 25, 2021 · 824 views
    This topic created in 1655 days ago, the information mentioned may be changed or developed.

    今天使用 git-lfs 的时候,发现如果创建一个空文件,不管这个文件在哪,只要 git add 之后,git lfs status 就会显示它被 lfs 追踪(图 1)。向文件里写点内容再重新操作就显示未被 lfs 追踪(图 2

    图 1 001.png

    图 2 002.png

    PS: .gitattributes内容

    builds/bundled/** filter=lfs diff=lfs merge=lfs -text
    
    No Comments Yet
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Solana   ·   922 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 29ms · UTC 19:15 · PVG 03:15 · LAX 12:15 · JFK 15:15
    ♥ Do have faith in what you're doing.