1GIT-STATUS(1)                     Git Manual                     GIT-STATUS(1)
2
3
4

NAME

6       git-status - Show the working tree status
7

SYNOPSIS

9       git status [<options>...] [--] [<pathspec>...]
10

DESCRIPTION

12       Displays paths that have differences between the index file and the
13       current HEAD commit, paths that have differences between the working
14       tree and the index file, and paths in the working tree that are not
15       tracked by git (and are not ignored by gitignore(5)). The first are
16       what you would commit by running git commit; the second and third are
17       what you could commit by running git add before running git commit.
18

OPTIONS

20       -s, --short
21           Give the output in the short-format.
22
23       --porcelain
24           Give the output in a stable, easy-to-parse format for scripts.
25           Currently this is identical to --short output, but is guaranteed
26           not to change in the future, making it safe for scripts.
27
28       -u[<mode>], --untracked-files[=<mode>]
29           Show untracked files (Default: all).
30
31           The mode parameter is optional, and is used to specify the handling
32           of untracked files. The possible options are:
33
34           ·    no - Show no untracked files
35
36           ·    normal - Shows untracked files and directories
37
38           ·    all - Also shows individual files in untracked directories.
39               See git-config(1) for configuration variable used to change the
40               default for when the option is not specified.
41
42           -z
43               Terminate entries with NUL, instead of LF. This implies the
44               --porcelain output format if no other format is given.
45

OUTPUT

47       The output from this command is designed to be used as a commit
48       template comment, and all the output lines are prefixed with #. The
49       default, long format, is designed to be human readable, verbose and
50       descriptive. They are subject to change in any time.
51
52       The paths mentioned in the output, unlike many other git commands, are
53       made relative to the current directory if you are working in a
54       subdirectory (this is on purpose, to help cutting and pasting). See the
55       status.relativePaths config option below.
56
57       In short-format, the status of each path is shown as
58
59           XY PATH1 -> PATH2
60
61       where PATH1 is the path in the HEAD, and ` → PATH2` part is shown only
62       when PATH1 corresponds to a different path in the index/worktree (i.e.
63       the file is renamed). The XY is a two-letter status code.
64
65       The fields (including the →) are separated from each other by a single
66       space. If a filename contains whitespace or other nonprintable
67       characters, that field will be quoted in the manner of a C string
68       literal: surrounded by ASCII double quote (34) characters, and with
69       interior special characters backslash-escaped.
70
71       For paths with merge conflicts, X and Y show the modification states of
72       each side of the merge. For paths that do not have merge conflicts, X
73       shows the status of the index, and Y shows the status of the work tree.
74       For untracked paths, XY are ??. Other status codes can be interpreted
75       as follows:
76
77       ·   ´ ´ = unmodified
78
79       ·    M = modified
80
81       ·    A = added
82
83       ·    D = deleted
84
85       ·    R = renamed
86
87       ·    C = copied
88
89       ·    U = updated but unmerged
90
91       Ignored files are not listed.
92
93           X          Y     Meaning
94           -------------------------------------------------
95                     [MD]   not updated
96           M        [ MD]   updated in index
97           A        [ MD]   added to index
98           D         [ M]   deleted from index
99           R        [ MD]   renamed in index
100           C        [ MD]   copied in index
101           [MARC]           index and work tree matches
102           [ MARC]     M    work tree changed since index
103           [ MARC]     D    deleted in work tree
104           -------------------------------------------------
105           D           D    unmerged, both deleted
106           A           U    unmerged, added by us
107           U           D    unmerged, deleted by them
108           U           A    unmerged, added by them
109           D           U    unmerged, deleted by us
110           A           A    unmerged, both added
111           U           U    unmerged, both modified
112           -------------------------------------------------
113           ?           ?    untracked
114           -------------------------------------------------
115
116       There is an alternate -z format recommended for machine parsing. In
117       that format, the status field is the same, but some other things
118       change. First, the  is omitted from rename entries and the field order
119       is reversed (e.g from  to becomes to from). Second, a NUL (ASCII 0)
120       follows each filename, replacing space as a field separator and the
121       terminating newline (but a space still separates the status field from
122       the first filename). Third, filenames containing special characters are
123       not specially formatted; no quoting or backslash-escaping is performed.
124

CONFIGURATION

126       The command honors color.status (or status.color — they mean the same
127       thing and the latter is kept for backward compatibility) and
128       color.status.<slot> configuration variables to colorize its output.
129
130       If the config variable status.relativePaths is set to false, then all
131       paths shown are relative to the repository root, not to the current
132       directory.
133
134       If status.submodulesummary is set to a non zero number or true
135       (identical to -1 or an unlimited number), the submodule summary will be
136       enabled for the long format and a summary of commits for modified
137       submodules will be shown (see --summary-limit option of git-
138       submodule(1)).
139

SEE ALSO

141       gitignore(5)
142

AUTHOR

144       Written by Junio C Hamano <gitster@pobox.com[1]>.
145

DOCUMENTATION

147       Documentation by David Greaves, Junio C Hamano and the git-list
148       <git@vger.kernel.org[2]>.
149

GIT

151       Part of the git(1) suite
152

NOTES

154        1. gitster@pobox.com
155           mailto:gitster@pobox.com
156
157        2. git@vger.kernel.org
158           mailto:git@vger.kernel.org
159
160
161
162Git 1.7.1                         08/16/2017                     GIT-STATUS(1)
Impressum