Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

git track binary files but ignore content?

Tags:

git

Is there a way in git to track binary files without git caring about the contents? The tracking would mainly be for historical reasons.

If not; is there a way to have git track all files but ignore contents of files over N size?


1 Answers

Is there a way in git to track binary files without git caring about the contents?

Not with native git.

You can check-out git-annex, which is pretty close of what you want.

git-annex allows managing files with git, without checking the file contents into git.

While that may seem paradoxical, it is useful when dealing with files larger than git can currently easily handle, whether due to limitations in memory, time, or disk space.

like image 153
VonC Avatar answered Jan 01 '26 02:01

VonC



Donate For Us

If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!