git/list[1] front-page[2] threads[3] people[4] search[5] about
 

[PATCH 1/2] fast-import: clarify documentation of "feature" command

From
Jonathan Nieder <jrnieder@gmail.com>
Date
Feb 9, 2011, 22:43 UTC
Message-ID
<20110209224302.GA17128@elie>
In-Reply-To
<20110209214638.GA16716@elie>
Date: Sun, 28 Nov 2010 13:43:57 -0600

The "feature" command allows streams to specify options for the import that must not be ignored. Logically, they are part of the stream, even though technically most supported features are synonyms to command-line options.

Make this more obvious by being more explicit about how the analogy between most "feature" commands and command-line options works. Treat the feature (import-marks) that does not fit this analogy separately.

Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
Acked-by: Sverre Rabbelier <srabbelier@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Signed-off-by: Jonathan Nieder <jrnieder@gmail.com>
---
Just a cherry-pick.
 Documentation/git-fast-import.txt |   33 +++++++++++++++------------------
 1 files changed, 15 insertions(+), 18 deletions(-)
diff --git a/Documentation/git-fast-import.txt b/Documentation/git-fast-import.txt
index 19082b0..3bf04e3 100644
--- a/Documentation/git-fast-import.txt
+++ b/Documentation/git-fast-import.txt
@@ -878,28 +878,25 @@ Require that fast-import supports the specified feature, or abort if
 it does not.
 
 ....
-	'feature' SP <feature> LF
+	'feature' SP <feature> ('=' <argument>)? LF
 ....
 
-The <feature> part of the command may be any string matching
-^[a-zA-Z][a-zA-Z-]*$ and should be understood by fast-import.
+The <feature> part of the command may be any one of the following:
 
-Feature work identical as their option counterparts with the
-exception of the import-marks feature, see below.
+date-format::
+export-marks::
+relative-marks::
+no-relative-marks::
+force::
+	Act as though the corresponding command-line option with
+	a leading '--' was passed on the command line
+	(see OPTIONS, above).
 
-The following features are currently supported:
-
-* date-format
-* import-marks
-* export-marks
-* relative-marks
-* no-relative-marks
-* force
-
-The import-marks behaves differently from when it is specified as
-commandline option in that only one "feature import-marks" is allowed
-per stream. Also, any --import-marks= specified on the commandline
-will override those from the stream (if any).
+import-marks::
+	Like --import-marks except in two respects: first, only one
+	"feature import-marks" command is allowed per stream;
+	second, an --import-marks= command-line option overrides
+	any "feature import-marks" command in the stream.
 
 `option`
 ~~~~~~~~
-- 
1.7.4
Previous: Jonathan NiederNext: Jonathan Nieder
Message 8 of 10 in “fast-import: introduce "feature notes" command”
  1. 0/2 fast-import: introduce "feature notes" commandJonathan Nieder, Feb 2, 2011
  2. 1/2 Documentation/fast-import: explain how to remove a noteJonathan Nieder, Feb 2, 2011
  3. 2/2 fast-import: introduce "feature notes" commandJonathan Nieder, Feb 2, 2011
  4. Thomas RastFeb 2, 2011
  5. Sverre RabbelierFeb 2, 2011
  6. Jonathan NiederFeb 2, 2011
  7. 0/2 fast-import: introduce "feature notes" commandJonathan Nieder, Feb 9, 2011
  8. 1/2 fast-import: clarify documentation of "feature" commandJonathan Nieder, Feb 9, 2011
  9. 2/2 fast-import: introduce "feature notes" commandJonathan Nieder, Feb 9, 2011
  10. Sverre RabbelierFeb 9, 2011

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.