summaryrefslogtreecommitdiffstats
path: root/git-checkout.txt
diff options
context:
space:
mode:
authorJunio C Hamano <gitster@pobox.com>2023-10-02 12:48:04 -0700
committerJunio C Hamano <gitster@pobox.com>2023-10-02 12:48:04 -0700
commitc4096feabf5efb4497b6808dfeea8d8693f93e5b (patch)
tree4c66b275c80cc92ea0c470b401fe633dc98df1b5 /git-checkout.txt
parent2b1164dcb4d39a0163d4ac1a7ba350140d59ce15 (diff)
downloadgit-htmldocs-c4096feabf5efb4497b6808dfeea8d8693f93e5b.tar.gz
Autogenerated HTML docs for v2.42.0-307-gd0e80
Diffstat (limited to 'git-checkout.txt')
-rw-r--r--git-checkout.txt9
1 files changed, 6 insertions, 3 deletions
diff --git a/git-checkout.txt b/git-checkout.txt
index 4af0904f4..a30e3ebc5 100644
--- a/git-checkout.txt
+++ b/git-checkout.txt
@@ -12,8 +12,10 @@ SYNOPSIS
'git checkout' [-q] [-f] [-m] --detach [<branch>]
'git checkout' [-q] [-f] [-m] [--detach] <commit>
'git checkout' [-q] [-f] [-m] [[-b|-B|--orphan] <new-branch>] [<start-point>]
-'git checkout' [-f|--ours|--theirs|-m|--conflict=<style>] [<tree-ish>] [--] <pathspec>...
-'git checkout' [-f|--ours|--theirs|-m|--conflict=<style>] [<tree-ish>] --pathspec-from-file=<file> [--pathspec-file-nul]
+'git checkout' [-f] <tree-ish> [--] <pathspec>...
+'git checkout' [-f] <tree-ish> --pathspec-from-file=<file> [--pathspec-file-nul]
+'git checkout' [-f|--ours|--theirs|-m|--conflict=<style>] [--] <pathspec>...
+'git checkout' [-f|--ours|--theirs|-m|--conflict=<style>] --pathspec-from-file=<file> [--pathspec-file-nul]
'git checkout' (-p|--patch) [<tree-ish>] [--] [<pathspec>...]
DESCRIPTION
@@ -260,7 +262,8 @@ and mark the resolved paths with `git add` (or `git rm` if the merge
should result in deletion of the path).
+
When checking out paths from the index, this option lets you recreate
-the conflicted merge in the specified paths.
+the conflicted merge in the specified paths. This option cannot be
+used when checking out paths from a tree-ish.
+
When switching branches with `--merge`, staged changes may be lost.