diff options
author | Ludovic Courtès <ludo@gnu.org> | 2014-02-21 17:54:32 +0100 |
---|---|---|
committer | Ludovic Courtès <ludo@gnu.org> | 2014-02-21 23:49:52 +0100 |
commit | 3140f2df423d1235c3766e3478a429ac89d882ed (patch) | |
tree | a250657c8c3682f5be9f40493d328f9c9ab83f20 /doc | |
parent | c1d52c71aa4fc8085a9737ad1b235ca53a854649 (diff) |
guix hash: Add '--recursive'.
* guix/scripts/hash.scm (show-help): Add --recursive.
(%options): Likewise.
(guix-hash)[file-hash]: New procedure. Honor --recursive.
Use it.
* guix/nar.scm (write-file): Add missing field to the &nar-error
condition raised upon unsupported file type; change its message to be
more descriptive.
* tests/guix-hash.sh: Add tests with -r.
* doc/guix.texi (Invoking guix hash): Document --recursive.
Diffstat (limited to 'doc')
-rw-r--r-- | doc/guix.texi | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/doc/guix.texi b/doc/guix.texi index 34f6810f34..ce011959ad 100644 --- a/doc/guix.texi +++ b/doc/guix.texi @@ -1958,6 +1958,19 @@ If the @option{--format} option is not specified, @command{guix hash} will output the hash in @code{nix-base32}. This representation is used in the definitions of packages. +@item --recursive +@itemx -r +Compute the hash on @var{file} recursively. + +In this case, the hash is computed on an archive containing @var{file}, +including its children if it is a directory. Some of @var{file}'s +meta-data is part of the archive; for instance, when @var{file} is a +regular file, the hash is different depending on whether @var{file} is +executable or not. Meta-data such as time stamps has no impact on the +hash (@pxref{Invoking guix archive}). +@c FIXME: Replace xref above with xref to an ``Archive'' section when +@c it exists. + @end table @node Invoking guix refresh |