1git-annex(1) General Commands Manual git-annex(1)
2
3
4
6 git-annex - manage files with git, without checking their contents in
7
9 git annex command [params ...]
10
12 git-annex allows managing files with git, without checking the file
13 contents into git. While that may seem paradoxical, it is useful when
14 dealing with files larger than git can currently easily handle, whether
15 due to limitations in memory, checksumming time, or disk space.
16
17 Even without file content tracking, being able to manage files with
18 git, move files around and delete files with versioned directory trees,
19 and use branches and distributed clones, are all very handy reasons to
20 use git. And annexed files can co-exist in the same git repository with
21 regularly versioned files, which is convenient for maintaining docu‐
22 ments, Makefiles, etc that are associated with annexed files but that
23 benefit from full revision control.
24
25 When a file is annexed, its content is moved into a key-value store,
26 and a symlink is made that points to the content. These symlinks are
27 checked into git and versioned like regular files. You can move them
28 around, delete them, and so on. Pushing to another git repository will
29 make git-annex there aware of the annexed file, and it can be used to
30 retrieve its content from the key-value store.
31
33 # git annex get video/hackity_hack_and_kaxxt.mov
34 get video/hackity_hack_and_kaxxt.mov (not available)
35 I was unable to access these remotes: server
36 Try making some of these repositories available:
37 5863d8c0-d9a9-11df-adb2-af51e6559a49 -- my home file server
38 58d84e8a-d9ae-11df-a1aa-ab9aa8c00826 -- portable USB drive
39 ca20064c-dbb5-11df-b2fe-002170d25c55 -- backup SATA drive
40 failed
41 # sudo mount /media/usb
42 # git remote add usbdrive /media/usb
43 # git annex get video/hackity_hack_and_kaxxt.mov
44 get video/hackity_hack_and_kaxxt.mov (from usbdrive...) ok
45
46 # git annex add iso
47 add iso/Debian_5.0.iso ok
48
49 # git annex drop iso/Debian_4.0.iso
50 drop iso/Debian_4.0.iso ok
51
52 # git annex move iso --to=usbdrive
53 move iso/Debian_5.0.iso (moving to usbdrive...) ok
54
56 Like many git commands, git-annex can be passed a path that is either a
57 file or a directory. In the latter case it acts on all relevant files
58 in the directory. When no path is specified, most git-annex commands
59 default to acting on all relevant files in the current directory (and
60 subdirectories).
61
62 help Display built-in help.
63
64 For help on a specific command, use git annex help command
65
66 add [path ...]
67 Adds files in the path to the annex. If no path is specified,
68 adds files from the current directory and below.
69
70 See git-annex-add(1) for details.
71
72 get [path ...]
73 Makes the content of annexed files available in this repository.
74
75 See git-annex-get(1) for details.
76
77 drop [path ...]
78 Drops the content of annexed files from this repository.
79
80 See git-annex-drop(1) for details.
81
82 move [path ...] [--from=remote|--to=remote]
83 Moves the content of files from or to another remote.
84
85 See git-annex-move(1) for details.
86
87 copy [path ...] [--from=remote|--to=remote]
88 Copies the content of files from or to another remote.
89
90 See git-annex-copy(1) for details.
91
92 status [path ...]
93 Similar to git status --short, displays the status of the files
94 in the working tree.
95
96 See git-annex-status(1) for details.
97
98 unlock [path ...]
99 Unlock annexed files for modification.
100
101 See git-annex-unlock(1) for details.
102
103 edit [path ...]
104 This is an alias for the unlock command. May be easier to remem‐
105 ber, if you think of this as allowing you to edit an annexed
106 file.
107
108 lock [path ...]
109 Use this to undo an unlock command if you don't want to modify
110 the files, or have made modifications you want to discard.
111
112 See git-annex-lock(1) for details.
113
114 sync [remote ...]
115 Synchronize local repository with remotes.
116
117 See git-annex-sync(1) for details.
118
119 mirror [path ...] [--to=remote|--from=remote]
120 Mirror content of files to/from another repository.
121
122 See git-annex-mirror(1) for details.
123
124 addurl [url ...]
125 Downloads each url to its own file, which is added to the annex.
126
127 See git-annex-addurl(1) for details.
128
129 rmurl file url
130 Record that the file is no longer available at the url.
131
132 See git-annex-rmurl(1) for details.
133
134 import [path ...]
135 Add files from a non-version-controlled directory or a special
136 remote into the annex.
137
138 See git-annex-import(1) for details.
139
140 importfeed [url ...]
141 Imports the contents of podcast feeds into the annex.
142
143 See git-annex-importfeed(1) for details.
144
145 export treeish --to remote
146 Export content to a remote.
147
148 See git-annex-export(1) for details.
149
150 undo [filename|directory] ...
151 Undo last change to a file or directory.
152
153 See git-annex-undo(1) for details.
154
155 multicast
156 Multicast file distribution.
157
158 See git-annex-multicast(1) for details.
159
160 watch Watch for changes and autocommit.
161
162 See git-annex-watch(1) for details.
163
164 assistant
165 Automatically sync folders between devices.
166
167 See git-annex-assistant(1) for details.
168
169 webapp Opens a web app, that allows easy setup of a git-annex reposi‐
170 tory, and control of the git-annex assistant. If the assistant
171 is not already running, it will be started.
172
173 See git-annex-webapp(1) for details.
174
175 remotedaemon
176 Persistant communication with remotes.
177
178 See git-annex-remotedaemon(1) for details.
179
181 init [description]
182
183 Until a repository (or one of its remotes) has been initialized,
184 git-annex will refuse to operate on it, to avoid accidentally
185 using it in a repository that was not intended to have an annex.
186
187 See git-annex-init(1) for details.
188
189 describe repository description
190 Changes the description of a repository.
191
192 See git-annex-describe(1) for details.
193
194 initremote name type=value [param=value ...]
195 Creates a new special remote, and adds it to .git/config.
196
197 See git-annex-initremote(1) for details.
198
199 enableremote name [param=value ...]
200 Enables use of an existing special remote in the current reposi‐
201 tory.
202
203 See git-annex-enableremote(1) for details.
204
205 renameremote
206 Renames a special remote.
207
208 See git-annex-renameremote(1) for details.
209
210 enable-tor
211 Sets up tor hidden service.
212
213 See git-annex-enable-tor(1) for details.
214
215 numcopies [N]
216 Configure desired number of copies.
217
218 See git-annex-numcopies(1) for details.
219
220 trust [repository ...]
221 Records that a repository is trusted to not unexpectedly lose
222 content. Use with care.
223
224 See git-annex-trust(1) for details.
225
226 untrust [repository ...]
227 Records that a repository is not trusted and could lose content
228 at any time.
229
230 See git-annex-untrust(1) for details.
231
232 semitrust [repository ...]
233 Returns a repository to the default semi trusted state.
234
235 See git-annex-semitrust(1) for details.
236
237 group repository groupname
238 Add a repository to a group.
239
240 See git-annex-group(1) for details.
241
242 ungroup repository groupname
243 Removes a repository from a group.
244
245 See git-annex-ungroup(1) for details.
246
247 wanted repository [expression]
248 Get or set preferred content expression.
249
250 See git-annex-wanted(1) for details.
251
252 groupwanted groupname [expression]
253 Get or set groupwanted expression.
254
255 See git-annex-groupwanted(1) for details.
256
257 required repository [expression]
258 Get or set required content expression.
259
260 See git-annex-required(1) for details.
261
262 schedule repository [expression]
263 Get or set scheduled jobs.
264
265 See git-annex-schedule(1) for details.
266
267 config Get and set other configuration stored in git-annex branch.
268
269 See git-annex-config(1) for details.
270
271 vicfg Opens EDITOR on a temp file containing most of the above config‐
272 uration settings, as well as a few others, and when it exits,
273 stores any changes made back to the git-annex branch.
274
275 See git-annex-vicfg(1) for details.
276
277 adjust Switches a repository to use an adjusted branch, which can auto‐
278 matically unlock all files, etc.
279
280 See git-annex-adjust(1) for details.
281
282 direct Switches a repository to use direct mode. (deprecated)
283
284 See git-annex-direct(1) for details.
285
286 indirect
287 Switches a repository to use indirect mode. (deprecated)
288
289 See git-annex-indirect(1) for details.
290
292 fsck [path ...]
293
294 Checks the annex consistency, and warns about or fixes any prob‐
295 lems found. This is a good complement to git fsck.
296
297 See git-annex-fsck(1) for details.
298
299 expire [repository:]time ...
300 Expires repositories that have not recently performed an activ‐
301 ity (such as a fsck).
302
303 See git-annex-expire(1) for details.
304
305 unused Checks the annex for data that does not correspond to any files
306 present in any tag or branch, and prints a numbered list of the
307 data.
308
309 See git-annex-unused(1) for details.
310
311 dropunused [number|range ...]
312 Drops the data corresponding to the numbers, as listed by the
313 last git annex unused
314
315 See git-annex-dropunused(1) for details.
316
317 addunused [number|range ...]
318 Adds back files for the content corresponding to the numbers or
319 ranges, as listed by the last git annex unused.
320
321 See git-annex-addunused(1) for details.
322
323 fix [path ...]
324 Fixes up symlinks that have become broken to again point to
325 annexed content.
326
327 See git-annex-fix(1) for details.
328
329 merge Automatically merge changes from remotes.
330
331 See git-annex-merge(1) for details.
332
333 upgrade
334 Upgrades the repository.
335
336 See git-annex-upgrade(1) for details.
337
338 dead [repository ...] [--key key]
339 Indicates that a repository or a single key has been irretriev‐
340 ably lost.
341
342 See git-annex-dead(1) for details.
343
344 forget Causes the git-annex branch to be rewritten, throwing away his‐
345 torical data about past locations of files.
346
347 See git-annex-forget(1) for details.
348
349 repair This can repair many of the problems with git repositories that
350 git fsck detects, but does not itself fix. It's useful if a
351 repository has become badly damaged. One way this can happen is
352 if a repository used by git-annex is on a removable drive that
353 gets unplugged at the wrong time.
354
355 See git-annex-repair(1) for details.
356
357 p2p Configure peer-2-Peer links between repositories.
358
359 See git-annex-p2p(1) for details.
360
362 find [path ...]
363
364 Outputs a list of annexed files in the specified path. With no
365 path, finds files in the current directory and its subdirecto‐
366 ries.
367
368 See git-annex-find(1) for details.
369
370 whereis [path ...]
371 Displays information about where the contents of files are
372 located.
373
374 See git-annex-whereis(1) for details.
375
376 list [path ...]
377 Displays a table of remotes that contain the contents of the
378 specified files. This is similar to whereis but a more compact
379 display.
380
381 See git-annex-list(1) for details.
382
383 log [path ...]
384 Displays the location log for the specified file or files, show‐
385 ing each repository they were added to ("+") and removed from
386 ("-").
387
388 See git-annex-log(1) for details.
389
390 info [directory|file|remote|uuid ...]
391 Displays statistics and other information for the specified
392 item, which can be a directory, or a file, or a remote, or the
393 uuid of a repository.
394
395 When no item is specified, displays statistics and information
396 for the repository as a whole.
397
398 See git-annex-info(1) for details.
399
400 version
401 Shows the version of git-annex, as well as repository version
402 information.
403
404 See git-annex-version(1) for details.
405
406 map Generate map of repositories.
407
408 See git-annex-map(1) for details.
409
410 inprogress
411 Access files while they're being downloaded.
412
413 See git-annex-inprogress(1) for details.
414
416 metadata [path ...]
417
418 The content of an annexed file can have any number of metadata
419 fields attached to it to describe it. Each metadata field can in
420 turn have any number of values.
421
422 This command can be used to set metadata, or show the currently
423 set metadata.
424
425 See git-annex-metadata(1) for details.
426
427 view [tag ...] [field=value ...] [field=glob ...] [!tag ...]
428 [field!=value ...]
429 Uses metadata to build a view branch of the files in the current
430 branch, and checks out the view branch. Only files in the cur‐
431 rent branch whose metadata matches all the specified field val‐
432 ues and tags will be shown in the view.
433
434 See git-annex-view(1) for details.
435
436 vpop [N]
437 Switches from the currently active view back to the previous
438 view. Or, from the first view back to original branch.
439
440 See git-annex-vpop(1) for details.
441
442 vfilter [tag ...] [field=value ...] [!tag ...] [field!=value ...]
443 Filters the current view to only the files that have the speci‐
444 fied field values and tags.
445
446 See git-annex-vfilter(1) for details.
447
448 vadd [field=glob ...] [field=value ...] [tag ...]
449 Changes the current view, adding an additional level of directo‐
450 ries to categorize the files.
451
452 See git-annex-vfilter(1) for details.
453
454 vcycle When a view involves nested subdirectories, this cycles the
455 order.
456
457 See git-annex-vcycle(1) for details.
458
460 migrate [path ...]
461
462 Changes the specified annexed files to use a different key-value
463 backend.
464
465 See git-annex-migrate(1) for details.
466
467 reinject src dest
468 Moves the src file into the annex as the content of the dest
469 file. This can be useful if you have obtained the content of a
470 file from elsewhere and want to put it in the local annex.
471
472 See git-annex-reinject(1) for details.
473
474 unannex [path ...]
475 Use this to undo an accidental git annex add command. It puts
476 the file back how it was before the add.
477
478 See git-annex-unannex(1) for details.
479
480 uninit De-initialize git-annex and clean out repository.
481
482 See git-annex-uninit(1) for details.
483
484 reinit uuid|description
485 Initialize repository, reusing old UUID.
486
487 See git-annex-reinit(1) for details.
488
490 pre-commit [path ...]
491
492 This is meant to be called from git's pre-commit hook. git annex
493 init automatically creates a pre-commit hook using this.
494
495 See git-annex-pre-commit(1) for details.
496
497 post-receive
498 This is meant to be called from git's post-receive hook. git
499 annex init automatically creates a post-receive hook using this.
500
501 See git-annex-post-receive(1) for details.
502
503 lookupkey [file ...]
504 Looks up key used for file.
505
506 See git-annex-lookupkey(1) for details.
507
508 calckey [file ...]
509 Calculates the key that would be used to refer to a file.
510
511 See git-annex-calckey(1) for details.
512
513 contentlocation [key ..]
514 Looks up location of annexed content for a key.
515
516 See git-annex-contentlocation(1) for details.
517
518 examinekey [key ...]
519 Print information that can be determined purely by looking at
520 the key.
521
522 See git-annex-examinekey(1) for details.
523
524 matchexpression
525 Checks if a preferred content expression matches provided data.
526
527 See git-annex-matchexpression(1) for details.
528
529 fromkey [key file]
530 Manually set up a file in the git repository to link to a speci‐
531 fied key.
532
533 See git-annex-fromkey(1) for details.
534
535 registerurl [key url]
536 Registers an url for a key.
537
538 See git-annex-registerurl(1) for details.
539
540 setkey key file
541 Moves a file into the annex as the content of a key.
542
543 See git-annex-setkey(1) for details.
544
545 dropkey [key ...]
546 Drops annexed content for specified keys.
547
548 See git-annex-dropkey(1) for details.
549
550 transferkey key [--from=remote|--to=remote]
551 Transfers a key from or to a remote.
552
553 See git-annex-transferkey(1) for details.
554
555 transferkeys
556 Used internally by the assistant.
557
558 See git-annex-transferkey(1) for details.
559
560 setpresentkey key uuid [1|0]
561 This plumbing-level command changes git-annex's records about
562 whether the specified key's content is present in a remote with
563 the specified uuid.
564
565 See git-annex-setpresentkey(1) for details.
566
567 readpresentkey key uuid
568 Read records of where key is present.
569
570 See git-annex-readpresentkey(1) for details.
571
572 checkpresentkey key remote
573 Check if key is present in remote.
574
575 See git-annex-checkpresentkey(1) for details.
576
577 rekey [file key ...]
578 Change keys used for files.
579
580 See git-annex-rekey(1) for details.
581
582 resolvemerge
583 Resolves a conflicted merge, by adding both conflicting versions
584 of the file to the tree, using variants of their filename. This
585 is done automatically when using git annex sync or git annex
586 merge.
587
588 See git-annex-resolvemerge(1) for details.
589
590 diffdriver
591 This can be used to make git diff use an external diff driver
592 with annexed files.
593
594 See git-annex-diffdriver(1) for details.
595
596 smudge This command lets git-annex be used as a git filter driver,
597 allowing annexed files in the git repository to be unlocked at
598 all times, instead of being symlinks.
599
600 See git-annex-smudge(1) for details.
601
602 findref [ref]
603 Lists files in a git ref. (deprecated)
604
605 See git-annex-findref(1) for details.
606
607 proxy -- git cmd [options]
608 Bypass direct mode guard. (deprecated)
609
610 See git-annex-proxy(1) for details.
611
613 test
614
615 This runs git-annex's built-in test suite.
616
617 See git-annex-test(1) for details.
618
619 testremote remote
620 This tests a remote by generating some random objects and send‐
621 ing them to the remote, then redownloading them, removing them
622 from the remote, etc.
623
624 It's safe to run in an existing repository (the repository con‐
625 tents are not altered), although it may perform expensive data
626 transfers.
627
628 See git-annex-testremote(1) for details.
629
630 fuzztest
631 Generates random changes to files in the current repository, for
632 use in testing the assistant.
633
634 See git-annex-fuzztest(1) for details.
635
636 benchmark
637 This runs git-annex's built-in benchmarks, if it was built with
638 benchmarking support.
639
640 See git-annex-benchmark(1) for details.
641
643 These common options are accepted by all git-annex commands, and may
644 not be explicitly listed on their individual man pages. (Many commands
645 also accept the git-annex-matching-options(1).)
646
647 --force
648 Force unsafe actions, such as dropping a file's content when no
649 other source of it can be verified to still exist, or adding
650 ignored files. Use with care.
651
652 --fast Enable less expensive, but also less thorough versions of some
653 commands. What is avoided depends on the command.
654
655 --quiet
656 Avoid the default verbose display of what is done; only show
657 errors.
658
659 --verbose
660 Enable verbose display.
661
662 --debug
663 Show debug messages.
664
665 --no-debug
666 Disable debug messages.
667
668 --numcopies=n
669 Overrides the numcopies setting, forcing git-annex to ensure the
670 specified number of copies exist.
671
672 Note that setting numcopies to 0 is very unsafe.
673
674 --time-limit=time
675 Limits how long a git-annex command runs. The time can be some‐
676 thing like "5h", or "30m" or even "45s" or "10d".
677
678 Note that git-annex may continue running a little past the spec‐
679 ified time limit, in order to finish processing a file.
680
681 Also, note that if the time limit prevents git-annex from doing
682 all it was asked to, it will exit with a special code, 101.
683
684 --trust=repository
685
686 --semitrust=repository
687
688 --untrust=repository
689 Overrides trust settings for a repository. May be specified more
690 than once.
691
692 The repository should be specified using the name of a config‐
693 ured remote, or the UUID or description of a repository.
694
695 --trust-glacier
696 Amazon Glacier inventories take hours to retrieve, and may not
697 represent the current state of a repository. So git-annex does
698 not trust that files that the inventory claims are in Glacier
699 are really there. This switch can be used to allow it to trust
700 the inventory.
701
702 Be careful using this, especially if you or someone else might
703 have recently removed a file from Glacier. If you try to drop
704 the only other copy of the file, and this switch is enabled, you
705 could lose data!
706
707 --backend=name
708 Specifies which key-value backend to use. This can be used when
709 adding a file to the annex, or migrating a file. Once files are
710 in the annex, their backend is known and this option is not nec‐
711 essary.
712
713 --user-agent=value
714 Overrides the User-Agent to use when downloading files from the
715 web.
716
717 --notify-finish
718 Caused a desktop notification to be displayed after each suc‐
719 cessful file download and upload.
720
721 (Only supported on some platforms, e.g. Linux with dbus. A no-op
722 when not supported.)
723
724 --notify-start
725 Caused a desktop notification to be displayed when a file upload
726 or download has started, or when a file is dropped.
727
728 -c name=value
729 Overrides git configuration settings. May be specified multiple
730 times.
731
733 Like other git commands, git-annex is configured via .git/config.
734
735 annex.uuid
736 A unique UUID for this repository (automatically set).
737
738 annex.backend
739 Name of the default key-value backend to use when adding new
740 files to the repository.
741
742 This is overridden by annex annex.backend configuration in the
743 .gitattributes files, and by the --backend option.
744
745 (This used to be named annex.backends, and that will still be
746 used if set.)
747
748 annex.securehashesonly
749 Set to true to indicate that the repository should only use
750 cryptographically secure hashes (SHA2, SHA3) and not insecure
751 hashes (MD5, SHA1) for content.
752
753 When this is set, the contents of files using cryptographically
754 insecure hashes will not be allowed to be added to the reposi‐
755 tory.
756
757 Also, git-annex fsck will complain about any files present in
758 the repository that use insecure hashes.
759
760 To configure the behavior in new clones of the repository, this
761 can be set using git-annex-config.
762
763 annex.maxextensionlength
764 Maximum length of what is considered a filename extension when
765 adding a file to a backend that preserves filename extensions.
766 The default length is 4, which allows extensions like "jpeg".
767 The dot before the extension is not counted part of its length.
768 At most two extensions at the end of a filename will be pre‐
769 served, e.g. .gz or .tar.gz .
770
771 annex.diskreserve
772 Amount of disk space to reserve. Disk space is checked when
773 transferring content to avoid running out, and additional free
774 space can be reserved via this option, to make space for more
775 important content (such as git commit logs). Can be specified
776 with any commonly used units, for example, "0.5 gb", "500M", or
777 "100 KiloBytes"
778
779 The default reserve is 1 megabyte.
780
781 annex.largefiles
782 Used to configure which files are large enough to be added to
783 the annex. It is an expression that matches the large files, eg
784 "*.mp3 or largerthan(500kb)"
785
786 Overrides any annex.largefiles attributes in .gitattributes
787 files.
788
789 This configures the behavior of both git-annex and git when
790 adding files to the repository. By default, git-annex add adds
791 all files to the annex, and git add adds files to git (unless
792 they were added to the annex previously). When annex.largefiles
793 is configured, both git annex add and git add will add matching
794 large files to the annex, and the other files to git.
795
796 Other git-annex commands also honor annex.largefiles, including
797 git annex import, git annex addurl, git annex importfeed and the
798 assistant.
799
800 See <https://git-annex.branchable.com/tips/largefiles> for syn‐
801 tax documentation and more.
802
803 annex.gitaddtoannex
804 Setting this to false will prevent git add from honoring the
805 annex.largefiles configuration.
806
807 annex.addsmallfiles
808 Controls whether small files (not matching annex.largefiles)
809 should be checked into git by git annex add. Defaults to true;
810 set to false to instead make small files be skipped.
811
812 annex.addunlocked
813 Set to true to make commands like git-annex add that add files
814 to the repository add them in unlocked form. The default is for
815 these commands to add files in locked form.
816
817 (Using git add always adds files in unlocked form and it is not
818 affected by this setting.)
819
820 When a repository has core.symlinks set to false, it implicitly
821 sets annex.addunlocked to true.
822
823 annex.numcopies
824 This is a deprecated setting. You should instead use the git
825 annex numcopies command to configure how many copies of files
826 are kept across all repositories, or the annex.numcopies .gitat‐
827 tributes setting.
828
829 This config setting is only looked at when git annex numcopies
830 has never been configured, and when there's no annex.numcopies
831 setting in the .gitattributes file.
832
833 Note that setting numcopies to 0 is very unsafe.
834
835 annex.genmetadata
836 Set this to true to make git-annex automatically generate some
837 metadata when adding files to the repository.
838
839 In particular, it stores year, month, and day metadata, from the
840 file's modification date.
841
842 When importfeed is used, it stores additional metadata from the
843 feed, such as the author, title, etc.
844
845 annex.used-refspec
846 This controls which refs git-annex unused considers to be used.
847 See REFSPEC FORMAT in git-annex-unused(1) for details.
848
849 annex.jobs
850 Configure the number of concurrent jobs to run. Default is 1.
851
852 Only git-annex commands that support the --jobs option will use
853 this.
854
855 Setting this to "cpus" will run one job per CPU core.
856
857 annex.queuesize
858 git-annex builds a queue of git commands, in order to combine
859 similar commands for speed. By default the size of the queue is
860 limited to 10240 commands; this can be used to change the size.
861 If you have plenty of memory and are working with very large
862 numbers of files, increasing the queue size can speed it up.
863
864 annex.bloomcapacity
865 The git annex unused and git annex sync --content commands use a
866 bloom filter to determine what files are present in eg, the work
867 tree. The default bloom filter is sized to handle up to 500000
868 files. If your repository is larger than that, you should
869 increase this value. Larger values will make git-annex unused
870 and git annex sync --content consume more memory; run git annex
871 info for memory usage numbers.
872
873 annex.bloomaccuracy
874 Adjusts the accuracy of the bloom filter used by git annex
875 unused and git annex sync --content. The default accuracy is
876 10000000 -- 1 unused file out of 10000000 will be missed by git
877 annex unused. Increasing the accuracy will make git annex unused
878 consume more memory; run git annex info for memory usage num‐
879 bers.
880
881 annex.sshcaching
882 By default, git-annex caches ssh connections using ssh's Con‐
883 trolMaster and ControlPersist settings (if built using a new
884 enough ssh). To disable this, set to false.
885
886 annex.alwayscommit
887 By default, git-annex automatically commits data to the git-
888 annex branch after each command is run. If you have a series of
889 commands that you want to make a single commit, you can run the
890 commands with -c annex.alwayscommit=false. You can later commit
891 the data by running git annex merge (or by automatic merges) or
892 git annex sync.
893
894 You should beware running git gc when using this configuration,
895 since it could garbage collect objects that are staged in git-
896 annex's index but not yet committed.
897
898 annex.commitmessage
899 When git-annex updates the git-annex branch, it usually makes up
900 its own commit message ("update"), since users rarely look at or
901 care about changes to that branch. If you do care, you can spec‐
902 ify this setting by running commands with -c annex.commitmes‐
903 sage=whatever
904
905 This works well in combination with annex.alwayscommit=false, to
906 gather up a set of changes and commit them with a message you
907 specify.
908
909 annex.merge-annex-branches
910 By default, git-annex branches that have been pulled from
911 remotes are automatically merged into the local git-annex
912 branch, so that git-annex has the most up-to-date possible
913 knowledge.
914
915 To avoid that merging, set this to "false". This can be useful
916 particularly when you don't have write permission to the reposi‐
917 tory.
918
919 annex.hardlink
920 Set this to true to make file contents be hard linked between
921 the repository and its remotes when possible, instead of a more
922 expensive copy.
923
924 Use with caution -- This can invalidate numcopies counting,
925 since with hard links, fewer copies of a file can exist. So, it
926 is a good idea to mark a repository using this setting as
927 untrusted.
928
929 When a repository is set up using git clone --shared, git-annex
930 init will automatically set annex.hardlink and mark the reposi‐
931 tory as untrusted.
932
933 annex.thin
934 Set this to true to make unlocked files be a hard link to their
935 content in the annex, rather than a second copy. This can save
936 considerable disk space, but when a modification is made to a
937 file, you will lose the local (and possibly only) copy of the
938 old version. So, enable with care.
939
940 After setting (or unsetting) this, you should run git annex fix
941 to fix up the annexed files in the work tree to be hard links
942 (or copies).
943
944 Note that this has no effect when the filesystem does not sup‐
945 port hard links. And when multiple files in the work tree have
946 the same content, only one of them gets hard linked to the
947 annex.
948
949 annex.resolvemerge
950 Set to false to prevent merge conflicts in the checked out
951 branch being automatically resolved by the git-annex assitant,
952 git-annex sync, git-annex merge, and the git-annex post-receive
953 hook.
954
955 To configure the behavior in all clones of the repository, this
956 can be set in git-annex-config(1).
957
958 annex.synccontent
959 Set to true to make git-annex sync default to syncing content.
960
961 To configure the behavior in all clones of the repository, this
962 can be set in git-annex-config(1).
963
964 annex.debug
965 Set to true to enable debug logging by default.
966
967 annex.version
968 The current version of the git-annex repository. This is main‐
969 tained by git-annex and should never be manually changed.
970
971 annex.autoupgraderepository
972 When an old git-annex repository version has become deprecated,
973 git-annex will normally automatically upgrade the repository to
974 the new version.
975
976 If this is set to false, git-annex won't automatically upgrade
977 the repository. Instead it will exit with an error message. You
978 can run git annex upgrade yourself when you are ready to upgrade
979 the repository.
980
981 annex.crippledfilesystem
982 Set to true if the repository is on a crippled filesystem, such
983 as FAT, which does not support symbolic links, or hard links, or
984 unix permissions. This is automatically probed by "git annex
985 init".
986
987 annex.pidlock
988 Normally, git-annex uses fine-grained lock files to allow multi‐
989 ple processes to run concurrently without getting in each oth‐
990 ers' way. That works great, unless you are using git-annex on a
991 filesystem that does not support POSIX fcntl locks. This is
992 sometimes the case when using NFS or Lustre filesystems.
993
994 To support such situations, you can set annex.pidlock to true,
995 and it will fall back to a single top-level pid file lock.
996
997 Although, often, you'd really be better off fixing your net‐
998 worked filesystem configuration to support POSIX locks.. And,
999 some networked filesystems are so inconsistent that one node
1000 can't reliably tell when the other node is holding a pid lock.
1001 Caveat emptor.
1002
1003 annex.pidlocktimeout
1004 When using pid lock files, it's possible for a stale lock file
1005 to get left behind by previous run of git-annex that crashed or
1006 was interrupted. This is mostly avoided, but can occur espe‐
1007 cially when using a network file system.
1008
1009 git-annex will wait up to this many seconds for the pid lock
1010 file to go away, and will then abort if it cannot continue.
1011 Default: 300
1012
1013 annex.cachecreds
1014 When "true" (the default), git-annex will cache credentials used
1015 to access special remotes in files in .git/annex/creds/ that
1016 only you can read. To disable that caching, set to "false", and
1017 credentials will only be read from the environment, or if they
1018 have been embedded in encrypted form in the git repository, will
1019 be extracted and decrypted each time git-annex needs to access
1020 the remote.
1021
1022 annex.secure-erase-command
1023 This can be set to a command that should be run whenever git-
1024 annex removes the content of a file from the repository.
1025
1026 In the command line, %file is replaced with the file that should
1027 be erased.
1028
1029 For example, to use the wipe command, set it to wipe -f %file.
1030
1031 annex.tune.objecthash1, annex.tune.objecthashlower, annex.tune.branch‐
1032 hash1
1033 These can be passed to git annex init to tune the repository.
1034 They cannot be safely changed in a running repository and should
1035 never be set in global git configuration. For details, see
1036 <https://git-annex.branchable.com/tuning/>.
1037
1039 Remotes are configured using these settings in .git/config.
1040
1041 remote.<name>.annex-cost
1042 When determining which repository to transfer annexed files from
1043 or to, ones with lower costs are preferred. The default cost is
1044 100 for local repositories, and 200 for remote repositories.
1045
1046 remote.<name>.annex-cost-command
1047 If set, the command is run, and the number it outputs is used as
1048 the cost. This allows varying the cost based on e.g., the cur‐
1049 rent network.
1050
1051 remote.<name>.annex-start-command
1052 A command to run when git-annex begins to use the remote. This
1053 can be used to, for example, mount the directory containing the
1054 remote.
1055
1056 The command may be run repeatedly when multiple git-annex pro‐
1057 cesses are running concurrently.
1058
1059 remote.<name>.annex-stop-command
1060 A command to run when git-annex is done using the remote.
1061
1062 The command will only be run once *all* running git-annex pro‐
1063 cesses are finished using the remote.
1064
1065 remote.<name>.annex-shell
1066 Specify an alternative git-annex-shell executable on the remote
1067 instead of looking for "git-annex-shell" on the PATH.
1068
1069 This is useful if the git-annex-shell program is outside the
1070 PATH or has a non-standard name.
1071
1072 remote.<name>.annex-ignore
1073 If set to true, prevents git-annex from storing file contents on
1074 this remote by default. (You can still request it be used by
1075 the --from and --to options.)
1076
1077 This is, for example, useful if the remote is located somewhere
1078 without git-annex-shell. (For example, if it's on GitHub). Or,
1079 it could be used if the network connection between two reposito‐
1080 ries is too slow to be used normally.
1081
1082 This does not prevent git-annex sync (or the git-annex assis‐
1083 tant) from syncing the git repository to the remote.
1084
1085 remote.<name>.annex-ignore-command
1086 If set, the command is run, and if it exits nonzero, that's the
1087 same as setting annex-ignore to true. This allows controlling
1088 behavior based on e.g., the current network.
1089
1090 remote.<name>.annex-sync
1091 If set to false, prevents git-annex sync (and the git-annex
1092 assistant) from syncing with this remote by default. However,
1093 git annex sync <name> can still be used to sync with the remote.
1094
1095 remote.<name>.annex-sync-command
1096 If set, the command is run, and if it exits nonzero, that's the
1097 same as setting annex-sync to false. This allows controlling
1098 behavior based on e.g., the current network.
1099
1100 remote.<name>.annex-pull
1101 If set to false, prevents git-annex sync (and the git-annex
1102 assistant etc) from ever pulling (or fetching) from the remote.
1103
1104 remote.<name>.annex-push
1105 If set to false, prevents git-annex sync (and the git-annex
1106 assistant etc) from ever pushing to the remote.
1107
1108 remote.<name>.annex-readonly
1109 If set to true, prevents git-annex from making changes to a
1110 remote. This both prevents git-annex sync from pushing changes,
1111 and prevents storing or removing files from read-only remote.
1112
1113 remote.<name>.annex-verify, annex.verify
1114 By default, git-annex will verify the checksums of objects down‐
1115 loaded from remotes. If you trust a remote and don't want the
1116 overhead of these checksums, you can set this to false.
1117
1118 Note that even when this is set to false, git-annex does verifi‐
1119 cation in some edge cases, where it's likely the case than an
1120 object was downloaded incorrectly, or when needed for security.
1121
1122 remote.<name>.annex-tracking-branch
1123 This is for use with special remotes that support exports and
1124 imports.
1125
1126 When set to eg, "master", this tells git-annex that you want the
1127 special remote to track that branch.
1128
1129 When set to eg, "master:subdir", the special remote tracks only
1130 the subdirectory of that branch.
1131
1132 git-annex sync --content will import changes from the remote and
1133 merge them into the annex-tracking-branch. They also export
1134 changes made to the branch to the remote.
1135
1136 remote.<name>.annex-export-tracking
1137 Deprecated name for remote.<name>.annex-tracking-branch. Will
1138 still be used if it's configured and remote.<name>.annex-track‐
1139 ing-branch is not.
1140
1141 remote.<name>.annexUrl
1142 Can be used to specify a different url than the regular
1143 remote.<name>.url for git-annex to use when talking with the
1144 remote. Similar to the pushUrl used by git-push.
1145
1146 remote.<name>.annex-uuid
1147 git-annex caches UUIDs of remote repositories here.
1148
1149 remote.<name>.annex-config-uuid
1150 Used for some special remotes, points to a different special
1151 remote configuration to use.
1152
1153 remote.<name>.annex-retry, annex.retry
1154 Configure retries of failed transfers on a per-remote and gen‐
1155 eral basis, respectively. The value is the number of retries
1156 that can be made of the same transfer. (default 0)
1157
1158 remote.<name>.annex-retry-delay, annex.retry-delay
1159 Number of seconds to delay before the first retry of a transfer.
1160 When making multiple retries of the same transfer, the delay
1161 doubles after each retry. (default 1)
1162
1163 remote.<name>.annex-checkuuid
1164 This only affects remotes that have their url pointing to a
1165 directory on the same system. git-annex normally checks the uuid
1166 of such remotes each time it's run, which lets it transparently
1167 deal with different drives being mounted to the location at dif‐
1168 ferent times.
1169
1170 Setting annex-checkuuid to false will prevent it from checking
1171 the uuid at startup (although the uuid is still verified before
1172 making any changes to the remote repository). This may be useful
1173 to set to prevent unncessary spin-up or automounting of a drive.
1174
1175 remote.<name>.annex-trustlevel
1176 Configures a local trust level for the remote. This overrides
1177 the value configured by the trust and untrust commands. The
1178 value can be any of "trusted", "semitrusted" or "untrusted".
1179
1180 remote.<name>.annex-availability
1181 Can be used to tell git-annex whether a remote is LocallyAvail‐
1182 able or GloballyAvailable. Normally, git-annex determines this
1183 automatically.
1184
1185 remote.<name>.annex-speculate-present
1186 Set to "true" to make git-annex speculate that this remote may
1187 contain the content of any file, even though its normal location
1188 tracking does not indicate that it does. This will cause git-
1189 annex to try to get all file contents from the remote. Can be
1190 useful in setting up a caching remote.
1191
1192 remote.<name>.annex-bare
1193 Can be used to tell git-annex if a remote is a bare repository
1194 or not. Normally, git-annex determines this automatically.
1195
1196 remote.<name>.annex-ssh-options
1197 Options to use when using ssh to talk to this remote.
1198
1199 remote.<name>.annex-rsync-options
1200 Options to use when using rsync to or from this remote. For
1201 example, to force IPv6, and limit the bandwidth to 100Kbyte/s,
1202 set it to -6 --bwlimit 100
1203
1204 Note that git-annex-shell has a whitelist of allowed rsync
1205 options, and others will not be be passed to the remote rsync.
1206 So using some options may break the communication between the
1207 local and remote rsyncs.
1208
1209 remote.<name>.annex-rsync-upload-options
1210 Options to use when using rsync to upload a file to a remote.
1211
1212 These options are passed after other applicable rsync options,
1213 so can be used to override them. For example, to limit upload
1214 bandwidth to 10Kbyte/s, set --bwlimit 10.
1215
1216 remote.<name>.annex-rsync-download-options
1217 Options to use when using rsync to download a file from a
1218 remote.
1219
1220 These options are passed after other applicable rsync options,
1221 so can be used to override them.
1222
1223 remote.<name>.annex-rsync-transport
1224 The remote shell to use to connect to the rsync remote. Possible
1225 values are ssh (the default) and rsh, together with their argu‐
1226 ments, for instance ssh -p 2222 -c blowfish; Note that the
1227 remote hostname should not appear there, see rsync(1) for
1228 details. When the transport used is ssh, connections are auto‐
1229 matically cached unless annex.sshcaching is unset.
1230
1231 remote.<name>.annex-bup-split-options
1232 Options to pass to bup split when storing content in this
1233 remote. For example, to limit the bandwidth to 100Kbyte/s, set
1234 it to --bwlimit 100k (There is no corresponding option for bup
1235 join.)
1236
1237 remote.<name>.annex-gnupg-options
1238 Options to pass to GnuPG when it's encrypting data. For
1239 instance, to use the AES cipher with a 256 bits key and disable
1240 compression, set it to --cipher-algo AES256 --compress-algo
1241 none. (These options take precedence over the default GnuPG con‐
1242 figuration, which is otherwise used.)
1243
1244 remote.<name>.annex-gnupg-decrypt-options
1245 Options to pass to GnuPG when it's decrypting data. (These
1246 options take precedence over the default GnuPG configuration,
1247 which is otherwise used.)
1248
1249 annex.ssh-options, annex.rsync-options,
1250 annex.rsync-upload-options, annex.rsync-download-options,
1251 annex.bup-split-options, annex.gnupg-options,
1252 annex.gnupg-decrypt-options
1253
1254 Default options to use if a remote does not have more specific
1255 options as described above.
1256
1257 remote.<name>.annex-rsyncurl
1258 Used by rsync special remotes, this configures the location of
1259 the rsync repository to use. Normally this is automatically set
1260 up by git annex initremote, but you can change it if needed.
1261
1262 remote.<name>.annex-buprepo
1263 Used by bup special remotes, this configures the location of the
1264 bup repository to use. Normally this is automatically set up by
1265 git annex initremote, but you can change it if needed.
1266
1267 remote.<name>.annex-ddarrepo
1268 Used by ddar special remotes, this configures the location of
1269 the ddar repository to use. Normally this is automatically set
1270 up by git annex initremote, but you can change it if needed.
1271
1272 remote.<name>.annex-directory
1273 Used by directory special remotes, this configures the location
1274 of the directory where annexed files are stored for this remote.
1275 Normally this is automatically set up by git annex initremote,
1276 but you can change it if needed.
1277
1278 remote.<name>.annex-adb
1279 Used to identify remotes on Android devices accessed via adb.
1280 Normally this is automatically set up by git annex initremote.
1281
1282 remote.<name>.annex-androiddirectory
1283 Used by adb special remotes, this is the directory on the
1284 Android device where files are stored for this remote. Normally
1285 this is automatically set up by git annex initremote, but you
1286 can change it if needed.
1287
1288 remote.<name>.annex-androidserial
1289 Used by adb special remotes, this is the serial number of the
1290 Android device used by the remote. Normally this is automati‐
1291 cally set up by git annex initremote, but you can change it if
1292 needed, eg when upgrading to a new Android device.
1293
1294 remote.<name>.annex-s3
1295 Used to identify Amazon S3 special remotes. Normally this is
1296 automatically set up by git annex initremote.
1297
1298 remote.<name>.annex-glacier
1299 Used to identify Amazon Glacier special remotes. Normally this
1300 is automatically set up by git annex initremote.
1301
1302 remote.<name>.annex-webdav
1303 Used to identify webdav special remotes. Normally this is auto‐
1304 matically set up by git annex initremote.
1305
1306 remote.<name>.annex-tahoe
1307 Used to identify tahoe special remotes. Points to the configu‐
1308 ration directory for tahoe.
1309
1310 remote.<name>.annex-gcrypt
1311 Used to identify gcrypt special remotes. Normally this is auto‐
1312 matically set up by git annex initremote.
1313
1314 It is set to "true" if this is a gcrypt remote. If the gcrypt
1315 remote is accessible over ssh and has git-annex-shell available
1316 to manage it, it's set to "shell".
1317
1318 remote.<name>.annex-git-lfs
1319 Used to identify git-lfs special remotes. Normally this is
1320 automatically set up by git annex initremote.
1321
1322 It is set to "true" if this is a git-lfs remote.
1323
1324 remote.<name>.annex-hooktype, remote.<name>.annex-externaltype
1325 Used by hook special remotes and external special remotes to
1326 record the type of the remote.
1327
1328 annex.web-options
1329 Options to pass to curl when git-annex uses it to download urls
1330 (rather than the default built-in url downloader).
1331
1332 For example, to force IPv4 only, set it to "-4". Or to make
1333 curl use your ~/.netrc file, set it to "--netrc".
1334
1335 Setting this option makes git-annex use curl, but only when
1336 annex.security.allowed-ip-addresses is configured in a specific
1337 way. See its documentation.
1338
1339 annex.youtube-dl-options
1340 Options to pass to youtube-dl when using it to find the url to
1341 download for a video.
1342
1343 Some options may break git-annex's integration with youtube-dl.
1344 For example, the --output option could cause it to store files
1345 somewhere git-annex won't find them. Avoid setting here or in
1346 the youtube-dl config file any options that cause youtube-dl to
1347 download more than one file, or to store the file anywhere other
1348 than the current working directory.
1349
1350 annex.aria-torrent-options
1351 Options to pass to aria2c when using it to download a torrent.
1352
1353 annex.http-headers
1354 HTTP headers to send when downloading from the web. Multiple
1355 lines of this option can be set, one per header.
1356
1357 annex.http-headers-command
1358 If set, the command is run and each line of its output is used
1359 as a HTTP header. This overrides annex.http-headers.
1360
1361 annex.security.allowed-url-schemes
1362 List of URL schemes that git-annex is allowed to download con‐
1363 tent from. The default is "http https ftp".
1364
1365 Think very carefully before changing this; there are security
1366 implications. For example, if it's changed to allow "file" URLs,
1367 then anyone who can get a commit into your git-annex repository
1368 could git-annex addurl a pointer to a private file located out‐
1369 side that repository, possibly causing it to be copied into your
1370 repository and transferred on to other remotes, exposing its
1371 content.
1372
1373 Some special remotes support their own domain-specific URL
1374 schemes; those are not affected by this configuration setting.
1375
1376 annex.security.allowed-ip-addresses
1377 By default, git-annex only makes connections to public IP
1378 addresses; it will refuse to use HTTP and other servers on
1379 localhost or on a private network.
1380
1381 This setting can override that behavior, allowing access to par‐
1382 ticular IP addresses. For example "127.0.0.1 ::1" allows access
1383 to localhost (both IPV4 and IPV6). To allow access to all IP
1384 addresses, use "all"
1385
1386 Think very carefully before changing this; there are security
1387 implications. Anyone who can get a commit into your git-annex
1388 repository could git annex addurl an url on a private server,
1389 possibly causing it to be downloaded into your repository and
1390 transferred to other remotes, exposing its content.
1391
1392 Note that, since the interfaces of curl and youtube-dl do not
1393 allow these IP address restrictions to be enforced, curl and
1394 youtube-dl will never be used unless annex.secu‐
1395 rity.allowed-ip-addresses=all.
1396
1397 annex.security.allowed-http-addresses
1398 Old name for annex.security.allowed-ip-addresses. If set, this
1399 is treated the same as having annex.secu‐
1400 rity.allowed-ip-addresses set.
1401
1402 annex.security.allow-unverified-downloads
1403 For security reasons, git-annex refuses to download content from
1404 most special remotes when it cannot check a hash to verify that
1405 the correct content was downloaded. This particularly impacts
1406 downloading the content of URL or WORM keys, which lack hashes.
1407
1408 The best way to avoid problems due to this is to migrate files
1409 away from such keys, before their content reaches a special
1410 remote. See git-annex-migrate(1).
1411
1412 When the content is only available from a special remote, you
1413 can use this configuration to force git-annex to download it.
1414 But you do so at your own risk, and it's very important you read
1415 and understand the information below first!
1416
1417 Downloading unverified content from encrypted special remotes is
1418 prevented, because the special remote could send some other
1419 encrypted content than what you expect, causing git-annex to
1420 decrypt data that you never checked into git-annex, and risking
1421 exposing the decrypted data to any non-encrypted remotes you
1422 send content to.
1423
1424 Downloading unverified content from (non-encrypted) external
1425 special remotes is prevented, because they could follow http
1426 redirects to web servers on localhost or on a private network,
1427 or in some cases to a file:/// url.
1428
1429 If you decide to bypass this security check, the best thing to
1430 do is to only set it temporarily while running the command that
1431 gets the file. The value to set the config to is "ACKTHPPT".
1432 For example:
1433
1434 git -c annex.security.allow-unverified-downloads=ACKTHPPT annex
1435 get myfile
1436
1437 It would be a good idea to check that it downloaded the file you
1438 expected, too.
1439
1440 remote.<name>.annex-security-allow-unverified-downloads
1441 Per-remote configuration of annex.security.allow-unveri‐
1442 fied-downloads.
1443
1445 annex.delayadd
1446
1447 Makes the watch and assistant commands delay for the specified
1448 number of seconds before adding a newly created file to the
1449 annex. Normally this is not needed, because they already wait
1450 for all writers of the file to close it.
1451
1452 annex.expireunused
1453 Controls what the assistant does about unused file contents that
1454 are stored in the repository.
1455
1456 The default is false, which causes all old and unused file con‐
1457 tents to be retained, unless the assistant is able to move them
1458 to some other repository (such as a backup repository).
1459
1460 Can be set to a time specification, like "7d" or "1m", and then
1461 file contents that have been known to be unused for a week or a
1462 month will be deleted.
1463
1464 annex.fscknudge
1465 When set to false, prevents the webapp from reminding you when
1466 using repositories that lack consistency checks.
1467
1468 annex.autoupgrade
1469 When set to ask (the default), the webapp will check for new
1470 versions and prompt if they should be upgraded to. When set to
1471 true, automatically upgrades without prompting (on some sup‐
1472 ported platforms). When set to false, disables any upgrade
1473 checking.
1474
1475 Note that upgrade checking is only done when git-annex is
1476 installed from one of the prebuilt images from its website. This
1477 does not bypass e.g., a Linux distribution's own upgrade han‐
1478 dling code.
1479
1480 This setting also controls whether to restart the git-annex
1481 assistant when the git-annex binary is detected to have changed.
1482 That is useful no matter how you installed git-annex.
1483
1484 annex.autocommit
1485 Set to false to prevent the git-annex assistant and git-annex
1486 sync from automatically committing changes to files in the
1487 repository.
1488
1489 To configure the behavior in all clones of the repository, this
1490 can be set in git-annex-config(1).
1491
1492 annex.startupscan
1493 Set to false to prevent the git-annex assistant from scanning
1494 the repository for new and changed files on startup. This will
1495 prevent it from noticing changes that were made while it was not
1496 running, but can be a useful performance tweak for a large
1497 repository.
1498
1499 annex.listen
1500 Configures which address the webapp listens on. The default is
1501 localhost. Can be either an IP address, or a hostname that
1502 resolves to the desired address.
1503
1505 The key-value backend used when adding a new file to the annex can be
1506 configured on a per-file-type basis via .gitattributes files. In the
1507 file, the annex.backend attribute can be set to the name of the backend
1508 to use. For example, this here's how to use the WORM backend by
1509 default, but the SHA256E backend for ogg files:
1510
1511 * annex.backend=WORM
1512 *.ogg annex.backend=SHA256E
1513
1514 There is a annex.largefiles attribute, which is used to configure which
1515 files are large enough to be added to the annex. See the documentation
1516 above of the annex.largefiles git config and <https://git-annex.branch‐
1517 able.com/tips/largefiles> for details.
1518
1519 The numcopies setting can also be configured on a per-file-type basis
1520 via the annex.numcopies attribute in .gitattributes files. This over‐
1521 rides other numcopies settings. For example, this makes two copies be
1522 needed for wav files and 3 copies for flac files:
1523
1524 *.wav annex.numcopies=2
1525 *.flac annex.numcopies=3
1526
1527 Note that setting numcopies to 0 is very unsafe.
1528
1529 These settings are honored by git-annex whenever it's operating on a
1530 matching file. However, when using --all, --unused, or --key to specify
1531 keys to operate on, git-annex is operating on keys and not files, so
1532 will not honor the settings from .gitattributes. For this reason, the
1533 git annex numcopies command is useful to configure a global default for
1534 numcopies.
1535
1536 Also note that when using views, only the toplevel .gitattributes file
1537 is preserved in the view, so other settings in other files won't have
1538 any effect.
1539
1541 git-annex, when called as a git subcommand, may return exit codes 0 or
1542 1 for success or failures, or, more rarely, 127 or 128 for certain very
1543 specific failures. git-annex itself should return 0 on success and 1
1544 on failure, unless the --time-limit=time option is hit, in which case
1545 it returns with exit code 101.
1546
1548 These environment variables are used by git-annex when set:
1549
1550 GIT_WORK_TREE, GIT_DIR
1551 Handled the same as they are by git, see git(1)
1552
1553 GIT_SSH, GIT_SSH_COMMAND
1554 Handled similarly to the same as described in git(1). The one
1555 difference is that git-annex will sometimes pass an additional
1556 "-n" parameter to these, as the first parameter, to prevent ssh
1557 from reading from stdin. Since that can break existing uses of
1558 these environment variables that don't expect the extra parame‐
1559 ter, you will need to set GIT_ANNEX_USE_GIT_SSH=1 to make git-
1560 annex support these.
1561
1562 Note that setting either of these environment variables prevents
1563 git-annex from automatically enabling ssh connection caching
1564 (see annex.sshcaching), so it will slow down some operations
1565 with remotes over ssh. It's up to you to enable ssh connection
1566 caching if you need it; see ssh's documentation.
1567
1568 Also, annex.ssh-options and remote.<name>.annex-ssh-options
1569 won't have any effect when these envionment variables are set.
1570
1571 Usually it's better to configure any desired options through
1572 your ~/.ssh/config file, or by setting annex.ssh-options.
1573
1574 GIT_ANNEX_VECTOR_CLOCK
1575 Normally git-annex timestamps lines in the log files committed
1576 to the git-annex branch. Setting this environment variable to a
1577 number will make git-annex use that rather than the current num‐
1578 ber of seconds since the UNIX epoch. Note that decimal seconds
1579 are supported.
1580
1581 This is only provided for advanced users who either have a bet‐
1582 ter way to tell which commit is current than the local clock, or
1583 who need to avoid embedding timestamps for policy reasons. Mis‐
1584 use of this environment variable can confuse git-annex's
1585 book-keeping, sometimes in ways that git annex fsck is unable to
1586 repair.
1587
1588 Some special remotes use additional environment variables for
1589 authentication etc. For example, AWS_ACCESS_KEY_ID and
1590 GIT_ANNEX_P2P_AUTHTOKEN. See special remote documentation.
1591
1593 These files are used by git-annex:
1594
1595 .git/annex/objects/ in your git repository contains the annexed file
1596 contents that are currently available. Annexed files in your git repos‐
1597 itory symlink to that content.
1598
1599 .git/annex/ in your git repository contains other run-time information
1600 used by git-annex.
1601
1602 ~/.config/git-annex/autostart is a list of git repositories to start
1603 the git-annex assistant in.
1604
1605 .git/hooks/pre-commit-annex in your git repository will be run whenever
1606 a commit is made to the HEAD branch, either by git commit, git-annex
1607 sync, or the git-annex assistant.
1608
1609 .git/hooks/post-update-annex in your git repository will be run when‐
1610 ever the git-annex branch is updated. You can make this hook run git
1611 update-server-info when publishing a git-annex repository by http.
1612
1614 More git-annex documentation is available on its web site,
1615 <https://git-annex.branchable.com/>
1616
1617 If git-annex is installed from a package, a copy of its documentation
1618 should be included, in, for example, /usr/share/doc/git-annex/.
1619
1621 Joey Hess <id@joeyh.name>
1622
1623 <https://git-annex.branchable.com/>
1624
1625 git-annex(1)