16 comments

[ 2.9 ms ] story [ 33.4 ms ] thread
Happy to see use cases front and center in command line documentation. They seem to always start with ”obscure command flag that you’ll probably never use”.
Could this be abused to simulate something like SVN externals? I always found git submodules to be a very bad replacement for that.
GitHub really embraced the Microsoft-esque NIH with LFS, instead of adopting git-annex.
(comment deleted)
git-annex has some really awkward documentation.

You can apparently do, sort of, but not really, the same thing git-fetch-file[1] does, with git-annex:

    git fetch-file add https://github.com/icculus/physfs.git "**" lib/physfs-main
    git fetch-file pull
`add` creates this at `.git-remote-files`:

    [file "**"]
    commit = 9d18d36b5a5207b72f473f05e1b2834e347d8144
    target = lib/physfs-main
    repository = https://github.com/icculus/physfs
    branch = main
But git-annex's documentation goes on and on about a bunch of commands I don't really want to read about, whereas those two lines and that .git-remote-files manifest just told you what git-fetch-file does.

[1]: https://github.com/andrewmcwattersandco/git-fetch-file

I use git-annex to manage all my data on all my drives. It automatically keeps track of which files are on which drives, it ensures that there are enough copies and it checksums everything. It works perfectly with offline drives.

git-annex can be a bit hard to grasp, so I suggest to create a throw-away repository, following the walkthrough[1] and try things out. See also workflows[2].

[1] https://git-annex.branchable.com/walkthrough/

[2] https://git-annex.branchable.com/workflow/

Git-Annex is a cool piece of technology, but my impression is that it works best for single-user repositories. So for instance, as @nolist_policy described in a sibling comment, managing all your personal files, documents, music, etc. across many different devices.

I tried using it for syncing large files in a collaborative repository, and the use of "magic" branches didn't seem to scale well.

(comment deleted)
I'm using my self-hosted forgejo. I don't see any benefit of git-annex over LFS so far, I'm not even sure I could setup annex as easily.

Digging a little bit I found that git-annex is coded in haskell (not a fan) and seems to be 50% slower (expected from haskell but also only 1 source so far so not really reliable).

I don't see appeal of the complexity of the commands, they probably serve a purpose. Once you opened a .gitattributes from git-LFS you pretty much know all you need and you barely need any commands anymore.

Also I like how setting up a .gitattribute makes everything transparent the same way .gitignore works. I don't see any equivalent with git-annex.

Lastly any "tutorial" or guide about git-annex that won't show me an equivalent of 'git lfs ls-files' will definitely not appeal to me. I'm a big user of 'git status' and 'git lfs ls-files' to check/re-check everything.

My only problem with git-annex is Haskell. I don't hate the language itself, but the sheer number of dependencies it has to install is staggering. Many of those dependencies are not used by anything else, or may be incompatible versions when more than one application uses it. The pain is when you install them using the system package manager. Just two Haskell applications - annex and pandoc - are enough to fill your daily updates with may be a dozen little Haskell packages. God forbid you're on a distro that installs from source!

It's quite safe to just statically link most, if not all of them directly into the application, even when some of them are shared by other applications. I have seen this complaint repeated a few times. The reply from the Haskelliers seem to be that this is for the fine grained modularity of the library ecosystem. But why do they treat it like everything starts and ends with Haskell? Sometimes, there are other priorities like system administration. None of the other compiled languages have this problem - Rust, Go, Zig, ... Even plain old C and C++ aren't this frustrating with dependencies.

I need to clarify that I'm not hostile towards the Haskell language, its ecosystem and its users. It's something I plan to learn myself. But why does this problem exist? And is there a solution?

I've used this for years, but to me the big selling point was integration with cloud storage providers as a means of backup. That, however, was always flaky and dependent on unmaintained third-party plugins. I think there was also a bug at some point that caused some data inconsistencies, so eventually I stopped.

Does anyone know if the situation has improved on that front in the past 5 years?

Does this also work if I have data on SharePoint, DropBox, etc. and want to pull them (sync with local machine)?

My use case is mostly ETL related, where I want to pull all customers data (enterprise customer) so I can process them. But also keep the data updated, hence pull?

Ironically, I just spent a day last weekend writing my own version control system for large files

I dislike git-annex that much.

- it converts your files into blobs and bloats your file system

- As others have previously alluded, my primary use case is to ensure sync between distributed files, not version them (why would anyone possibly need that??)

- You can use AI to build a python based solution that will hash your files and put them into a lookup table, then create some helper methods to sync sources using rclone

Far simpler and more efficient methods exist.