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

[PATCH 2/1] pull: remove --update-head-ok from documentation

From
René Scharfe <l.s.r@web.de>
Date
Mar 28, 2020, 14:48 UTC
Message-ID
<c94f8c43-625c-8e99-fa04-aafb0c7cdd78@web.de>
In-Reply-To
<a406c273-9a2c-72ed-c5e3-4c19848f0f94@web.de>

'git pull' implicitly passes --update-head-ok to 'git fetch', but doesn't itself accept that option from users. That makes sense, as it wouldn't work without the possibility to update HEAD. Remove the option from the command's documentation to match its actual behavior.

Signed-off-by: René Scharfe <l.s.r@web.de>
---
 Documentation/fetch-options.txt | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/Documentation/fetch-options.txt b/Documentation/fetch-options.txt
index 00d03ec8c3..05709f67a1 100644
--- a/Documentation/fetch-options.txt
+++ b/Documentation/fetch-options.txt
@@ -204,7 +204,6 @@ ifndef::git-pull[]
 	recursion (such as settings in linkgit:gitmodules[5] and
 	linkgit:git-config[1]) override this option, as does
 	specifying --[no-]recurse-submodules directly.
-endif::git-pull[]

 -u::
 --update-head-ok::
@@ -214,6 +213,7 @@ endif::git-pull[]
 	to communicate with 'git fetch', and unless you are
 	implementing your own Porcelain you are not supposed to
 	use it.
+endif::git-pull[]

 --upload-pack <upload-pack>::
 	When given, and the repository to fetch from is handled
--
2.26.0
Previous: René ScharfeNext: Taylor Blau
Message 3 of 6 in “Documented option "--deepen" is unknown to git-pull”
  1. 天几Mar 8, 2020
  2. René ScharfeMar 9, 2020
  3. 2/1 pull: remove --update-head-ok from documentationRené Scharfe, Mar 28, 2020
  4. Taylor BlauMar 31, 2020
  5. René ScharfeMar 31, 2020
  6. 3/1 pull: pass documented fetch options onRené Scharfe, Mar 28, 2020

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.