2015-03-23 19:36:10 +00:00
|
|
|
# NAME
|
|
|
|
|
|
|
|
git-annex unlock - unlock files for modification
|
|
|
|
|
|
|
|
# SYNOPSIS
|
|
|
|
|
|
|
|
git annex unlock `[path ...]`
|
|
|
|
|
|
|
|
# DESCRIPTION
|
|
|
|
|
|
|
|
Normally, the content of annexed files is protected from being changed.
|
|
|
|
Unlocking an annexed file allows it to be modified. This replaces the
|
2015-12-27 19:59:59 +00:00
|
|
|
symlink for each specified file with the file's content.
|
2015-12-10 20:12:05 +00:00
|
|
|
You can then modify it and `git annex add` (or `git commit`) to save your
|
|
|
|
changes.
|
|
|
|
|
2018-10-26 17:56:36 +00:00
|
|
|
In v5 repositories, unlocking a file is local
|
|
|
|
to the repository, and is temporary. In v7 repositories, unlocking a file
|
2015-12-10 20:12:05 +00:00
|
|
|
changes how it is stored in the git repository (from a symlink to a pointer
|
2018-10-26 17:56:36 +00:00
|
|
|
file), so you can commit it like any other change. Also in v7, you
|
2016-04-01 21:38:42 +00:00
|
|
|
can use `git add` to add a file to the annex in unlocked form. This allows
|
2015-12-10 20:12:05 +00:00
|
|
|
workflows where a file starts out unlocked, is modified as necessary, and
|
|
|
|
is locked once it reaches its final version.
|
2015-03-23 19:36:10 +00:00
|
|
|
|
2015-12-27 19:59:59 +00:00
|
|
|
Normally, unlocking a file requires a copy to be made of its content,
|
|
|
|
so that its original content is preserved, while the copy can be modified.
|
|
|
|
To use less space, annex.thin can be set to true; this makes a hard link
|
|
|
|
to the content be made instead of a copy. (Only when supported by the file
|
2018-10-26 17:56:36 +00:00
|
|
|
system, and only in v7 and higher.) While this can save considerable
|
2015-12-27 19:59:59 +00:00
|
|
|
disk space, any modification made to a file will cause the old version of the
|
|
|
|
file to be lost from the local repository. So, enable annex.thin with care.
|
|
|
|
|
2015-03-23 19:36:10 +00:00
|
|
|
# OPTIONS
|
|
|
|
|
|
|
|
* file matching options
|
|
|
|
|
|
|
|
The [[git-annex-matching-options]](1)
|
|
|
|
can be used to specify files to unlock.
|
|
|
|
|
2017-10-30 18:44:11 +00:00
|
|
|
* `--json`
|
|
|
|
|
|
|
|
Enable JSON output. This is intended to be parsed by programs that use
|
|
|
|
git-annex. Each line of output is a JSON object.
|
|
|
|
|
2018-02-19 18:28:17 +00:00
|
|
|
* `--json-error-messages`
|
|
|
|
|
2018-02-19 19:33:59 +00:00
|
|
|
Messages that would normally be output to standard error are included in
|
|
|
|
the json instead.
|
2018-02-19 18:28:17 +00:00
|
|
|
|
2015-03-23 19:36:10 +00:00
|
|
|
# SEE ALSO
|
|
|
|
|
|
|
|
[[git-annex]](1)
|
|
|
|
|
2015-05-29 16:12:55 +00:00
|
|
|
[[git-annex-edit]](1)
|
|
|
|
|
|
|
|
[[git-annex-add]](1)
|
|
|
|
|
|
|
|
[[git-annex-lock]](1)
|
|
|
|
|
2015-03-23 19:36:10 +00:00
|
|
|
# AUTHOR
|
|
|
|
|
|
|
|
Joey Hess <id@joeyh.name>
|
|
|
|
|
|
|
|
Warning: Automatically converted into a man page by mdwn2man. Edit with care.
|