aboutsummaryrefslogtreecommitdiffstats
path: root/Documentation/git-fast-import.adoc
diff options
context:
space:
mode:
Diffstat (limited to 'Documentation/git-fast-import.adoc')
-rw-r--r--Documentation/git-fast-import.adoc45
1 files changed, 37 insertions, 8 deletions
diff --git a/Documentation/git-fast-import.adoc b/Documentation/git-fast-import.adoc
index 250d866652..3144ffcdb6 100644
--- a/Documentation/git-fast-import.adoc
+++ b/Documentation/git-fast-import.adoc
@@ -111,7 +111,8 @@ Locations of Marks Files
Like --import-marks but instead of erroring out, silently
skips the file if it does not exist.
---[no-]relative-marks::
+--relative-marks::
+--no-relative-marks::
After specifying --relative-marks the paths specified
with --import-marks= and --export-marks= are relative
to an internal directory in the current repository.
@@ -182,7 +183,7 @@ amount of memory usage and processing time. Assuming the frontend
is able to keep up with fast-import and feed it a constant stream of data,
import times for projects holding 10+ years of history and containing
100,000+ individual commits are generally completed in just 1-2
-hours on quite modest (~$2,000 USD) hardware.
+hours on quite modest hardware (~$2,000 USD in 2007).
Most bottlenecks appear to be in foreign source data access (the
source just cannot extract revisions fast enough) or disk IO (fast-import
@@ -445,7 +446,7 @@ one).
original-oid?
('author' (SP <name>)? SP LT <email> GT SP <when> LF)?
'committer' (SP <name>)? SP LT <email> GT SP <when> LF
- ('gpgsig' SP <alg> LF data)?
+ ('gpgsig' SP <algo> SP <format> LF data)?
('encoding' SP <encoding> LF)?
data
('from' SP <commit-ish> LF)?
@@ -518,13 +519,39 @@ their syntax.
^^^^^^^^
The optional `gpgsig` command is used to include a PGP/GPG signature
-that signs the commit data.
+or other cryptographic signature that signs the commit data.
-Here <alg> specifies which hashing algorithm is used for this
-signature, either `sha1` or `sha256`.
+....
+ 'gpgsig' SP <git-hash-algo> SP <signature-format> LF data
+....
+
+The `gpgsig` command takes two arguments:
+
+* `<git-hash-algo>` specifies which Git object format this signature
+ applies to, either `sha1` or `sha256`. This allows to know which
+ representation of the commit was signed (the SHA-1 or the SHA-256
+ version) which helps with both signature verification and
+ interoperability between repos with different hash functions.
+
+* `<signature-format>` specifies the type of signature, such as
+ `openpgp`, `x509`, `ssh`, or `unknown`. This is a convenience for
+ tools that process the stream, so they don't have to parse the ASCII
+ armor to identify the signature type.
-NOTE: This is highly experimental and the format of the data stream may
-change in the future without compatibility guarantees.
+A commit may have at most one signature for the SHA-1 object format
+(stored in the "gpgsig" header) and one for the SHA-256 object format
+(stored in the "gpgsig-sha256" header).
+
+See below for a detailed description of the `data` command which
+contains the raw signature data.
+
+Signatures are not yet checked in the current implementation
+though. (Already setting the `extensions.compatObjectFormat`
+configuration option might help with verifying both SHA-1 and SHA-256
+object format signatures when it will be implemented.)
+
+NOTE: This is highly experimental and the format of the `gpgsig`
+command may change in the future without compatibility guarantees.
`encoding`
^^^^^^^^^^
@@ -579,9 +606,11 @@ Marks must be declared (via `mark`) before they can be used.
The special case of restarting an incremental import from the
current branch value should be written as:
+
----
from refs/heads/branch^0
----
+
The `^0` suffix is necessary as fast-import does not permit a branch to
start from itself, and the branch is created in memory before the
`from` command is even read from the input. Adding `^0` will force