git-annex/ required content

Required content settings can be configured to do more complicated things than just setting the required number of copies of your data. For example, you could require that data be archived in at least two archival repositories, and also require that one copy be stored offsite.

The format of required content expressions is the same as preferred content expressions.

Required content settings can be edited using `git annex vicfg` or set using `git annex required`. Each repository can have its own settings, and other repositories will try to honor those settings when interacting with it.

While preferred content expresses a preference, it can be overridden by simply using `git annex drop`. On the other hand, required content settings are enforced; `git annex drop` will refuse to drop a file if doing so would violate its required content settings. (Although even this can be overridden using `--force`).

Also, `git-annex fsck` will warn about required contents that are not present.

comment 2
`git annex required` was recently added to the CLI.
Comment by joey — Tue Jul 22 18:11:47 2025
Command line?

Th expression format in the file is the same as preferred, but the latter can be set through command line (git-annex wanted REPO EXP), but I can't find any way to set required through command line. Is there any way, in the works, or not planned?

Thanks!

Comment by https://www.google.com/accounts/o8/id?id=AItOawnG-DZQa3d3Jn7K2q36TlbmZ8v2YuV-23M — Tue Jul 22 18:11:47 2025
Comments on this page are closed.