summaryrefslogtreecommitdiff
path: root/doc
diff options
context:
space:
mode:
Diffstat (limited to 'doc')
-rw-r--r--doc/copies.mdwn10
-rw-r--r--doc/git-annex.mdwn41
-rw-r--r--doc/internals.mdwn7
-rw-r--r--doc/tips/using_the_web_as_a_special_remote.mdwn2
-rw-r--r--doc/todo/preferred_content_numcopies_check.mdwn6
-rw-r--r--doc/walkthrough/fsck:_verifying_your_data.mdwn2
-rw-r--r--doc/walkthrough/removing_files:_When_things_go_wrong.mdwn4
7 files changed, 45 insertions, 27 deletions
diff --git a/doc/copies.mdwn b/doc/copies.mdwn
index 93cbd8ea8..205d2d5b1 100644
--- a/doc/copies.mdwn
+++ b/doc/copies.mdwn
@@ -6,8 +6,8 @@ command. So, git-annex can be configured to try
to keep N copies of a file's content available across all repositories.
(Although [[untrusted_repositories|trust]] don't count toward this total.)
-By default, N is 1; it is configured by annex.numcopies. This default
-can be overridden on a per-file-type basis by the annex.numcopies
+By default, N is 1; it is configured by running `git annex numcopies N`.
+This default can be overridden on a per-file-type basis by the annex.numcopies
setting in `.gitattributes` files. The --numcopies switch allows
temporarily using a different value.
@@ -30,9 +30,3 @@ refuse to do so.
With N=2, in order to drop the file content from Laptop, it would need access
to both USB and Server.
-
-Note that different repositories can be configured with different values of
-N. So just because Laptop has N=2, this does not prevent the number of
-copies falling to 1, when USB and Server have N=1. To avoid this,
-configure it in `.gitattributes`, which is shared between repositories
-using git.
diff --git a/doc/git-annex.mdwn b/doc/git-annex.mdwn
index e8058720c..4e7bd2395 100644
--- a/doc/git-annex.mdwn
+++ b/doc/git-annex.mdwn
@@ -403,6 +403,20 @@ subdirectories).
keyid+= and keyid-= with such remotes should be used with care, and
make little sense except in cases like the revoked key example above.
+* `numcopies [N]`
+
+ Tells git-annex how many copies it should preserve of files, over all
+ repositories. The default is 1.
+
+ Run without a number to get the current value.
+
+ When git-annex is asked to drop a file, it first verifies that the
+ required number of copies can be satisfied amoung all the other
+ repositories that have a copy of the file.
+
+ This can be overridden on a per-file basis by the annex.numcopies setting
+ in .gitattributes files.
+
* `trust [repository ...]`
Records that a repository is trusted to not unexpectedly lose
@@ -828,7 +842,7 @@ subdirectories).
* `--auto`
Enable automatic mode. Commands that get, drop, or move file contents
- will only do so when needed to help satisfy the setting of annex.numcopies,
+ will only do so when needed to help satisfy the setting of numcopies,
and preferred content configuration.
* `--all`
@@ -883,7 +897,7 @@ subdirectories).
* `--numcopies=n`
- Overrides the `annex.numcopies` setting, forcing git-annex to ensure the
+ Overrides the numcopies setting, forcing git-annex to ensure the
specified number of copies exist.
Note that setting numcopies to 0 is very unsafe.
@@ -1117,12 +1131,6 @@ Here are all the supported configuration settings.
A unique UUID for this repository (automatically set).
-* `annex.numcopies`
-
- Number of copies of files to keep across all repositories. (default: 1)
-
- Note that setting numcopies to 0 is very unsafe.
-
* `annex.backends`
Space-separated list of names of the key-value backends to use.
@@ -1151,6 +1159,17 @@ Here are all the supported configuration settings.
annex.largefiles = largerthan=100kb and not (include=*.c or include=*.h)
+* `annex.numcopies`
+
+ This is a deprecated setting. You should instead use the
+ `git annex numcopies` command to configure how many copies of files
+ are kept acros all repositories.
+
+ This config setting is only looked at when `git annex numcopies` has
+ never been configured.
+
+ Note that setting numcopies to 0 is very unsafe.
+
* `annex.queuesize`
git-annex builds a queue of git commands, in order to combine similar
@@ -1456,10 +1475,12 @@ but the SHA256E backend for ogg files:
The numcopies setting can also be configured on a per-file-type basis via
the `annex.numcopies` attribute in `.gitattributes` files. This overrides
-any value set using `annex.numcopies` in `.git/config`.
-For example, this makes two copies be needed for wav files:
+other numcopies settings.
+For example, this makes two copies be needed for wav files and 3 copies
+for flac files:
*.wav annex.numcopies=2
+ *.flac annex.numcopies=3
Note that setting numcopies to 0 is very unsafe.
diff --git a/doc/internals.mdwn b/doc/internals.mdwn
index d95ab3f5e..1cf0cf505 100644
--- a/doc/internals.mdwn
+++ b/doc/internals.mdwn
@@ -56,8 +56,11 @@ space and then the description, followed by a timestamp. Example:
e605dca6-446a-11e0-8b2a-002170d25c55 laptop timestamp=1317929189.157237s
26339d22-446b-11e0-9101-002170d25c55 usb disk timestamp=1317929330.769997s
-If there are multiple lines for the same uuid, the one with the most recent
-timestamp wins. git-annex union merges this and other files.
+## `numcopies.log`
+
+Records the global numcopies setting.
+
+The file format is simply a timestamp followed by a number.
## `remote.log`
diff --git a/doc/tips/using_the_web_as_a_special_remote.mdwn b/doc/tips/using_the_web_as_a_special_remote.mdwn
index 706ae2951..62ef58b69 100644
--- a/doc/tips/using_the_web_as_a_special_remote.mdwn
+++ b/doc/tips/using_the_web_as_a_special_remote.mdwn
@@ -34,7 +34,7 @@ With the result that it will hang onto files:
Could only verify the existence of 0 out of 1 necessary copies
Also these untrusted repositories may contain the file:
00000000-0000-0000-0000-000000000001 -- web
- (Use --force to override this check, or adjust annex.numcopies.)
+ (Use --force to override this check, or adjust numcopies.)
failed
## attaching urls to existing files
diff --git a/doc/todo/preferred_content_numcopies_check.mdwn b/doc/todo/preferred_content_numcopies_check.mdwn
index 956888cca..066f02cfb 100644
--- a/doc/todo/preferred_content_numcopies_check.mdwn
+++ b/doc/todo/preferred_content_numcopies_check.mdwn
@@ -47,10 +47,10 @@ work tree, which gitattributes settings do not.
Conclusion:
* Add to the git-annex branch a numcopies file that holds the global
- numcopies default if present.
-* Modify the assistant to use it when configuring numcopies.
+ numcopies default if present. **done**
+* Modify the assistant to use it when configuring numcopies. **done**
* To deprecate .git/config's annex.numcopies, only make it take effect
- when there is no numcopies file in the git-annex branch.
+ when there is no numcopies file in the git-annex branch. **done**
* Add "numcopiesneeded=N" preferred content expression using the git-annex
branch numcopies setting, overridden by any .gitattributes numcopies setting
for a particular file. It should ignore the other ways to specify
diff --git a/doc/walkthrough/fsck:_verifying_your_data.mdwn b/doc/walkthrough/fsck:_verifying_your_data.mdwn
index d036332fb..62e15b6fa 100644
--- a/doc/walkthrough/fsck:_verifying_your_data.mdwn
+++ b/doc/walkthrough/fsck:_verifying_your_data.mdwn
@@ -2,7 +2,7 @@ You can use the fsck subcommand to check for problems in your data. What
can be checked depends on the key-value [[backend|backends]] you've used
for the data. For example, when you use the SHA1 backend, fsck will verify
that the checksums of your files are good. Fsck also checks that the
-annex.numcopies setting is satisfied for all files.
+[[numcopies|copies]] setting is satisfied for all files.
# git annex fsck
fsck some_file (checksum...) ok
diff --git a/doc/walkthrough/removing_files:_When_things_go_wrong.mdwn b/doc/walkthrough/removing_files:_When_things_go_wrong.mdwn
index 2d3c0cde0..ccd2d197f 100644
--- a/doc/walkthrough/removing_files:_When_things_go_wrong.mdwn
+++ b/doc/walkthrough/removing_files:_When_things_go_wrong.mdwn
@@ -10,12 +10,12 @@ you'll see something like this.
Try making some of these repositories available:
58d84e8a-d9ae-11df-a1aa-ab9aa8c00826 -- portable USB drive
ca20064c-dbb5-11df-b2fe-002170d25c55 -- backup SATA drive
- (Use --force to override this check, or adjust annex.numcopies.)
+ (Use --force to override this check, or adjust numcopies.)
failed
drop other.iso (unsafe)
Could only verify the existence of 0 out of 1 necessary copies
No other repository is known to contain the file.
- (Use --force to override this check, or adjust annex.numcopies.)
+ (Use --force to override this check, or adjust numcopies.)
failed
Here you might --force it to drop `important_file` if you [[trust]] your backup.