Inspecting the status of a repository¶
Identify if any differences exist between the git staging area (known as the index) and the latest commit.
Porcelain status¶
To retrieve a parseable list of changes within a repository, call PorcelainStatus. Changes are listed using the porcelain V1 format, consisting of a two-character indicator followed by a path to the identified change.
Supported indicators¶
A two-character indicator, ' A', denotes the status of a file. It should be read as its status within the index, followed by its status within the working tree. Staging a file will move it from the working tree to the index, moving the indicator from the right (' A') to the left ('A ').
'A' Added
'C' Copied
'D' Deleted
'!' Ignored
'M' Modified
'R' Renamed
'T' Type Changed (e.g. regular file to symlink)
'U' Updated
' ' Unmodified
'?' Untracked
Check if a repository is clean¶
Calling Clean will return true if a repository has no outstanding changes.