Switch from `status` + `ls-files` to `status --ignored`
This commit is contained in:
parent
b8b7cfbbea
commit
baaf6cde1d
|
@ -70,6 +70,7 @@ recommended for optimal performance and extra features:
|
|||
* ``pygit2``
|
||||
* ``mercurial``
|
||||
* ``psutil``
|
||||
* ``git`` version 1.7.2 and later. Not needed if you have ``pygit2``.
|
||||
|
||||
Installation
|
||||
============
|
||||
|
|
|
@ -107,13 +107,9 @@ except ImportError:
|
|||
def status(self, path=None):
|
||||
if path:
|
||||
try:
|
||||
return next(self._gitcmd('status', '--porcelain', '--', path))[:2]
|
||||
return next(self._gitcmd('status', '--porcelain', '--ignored', '--', path))[:2]
|
||||
except StopIteration:
|
||||
try:
|
||||
next(self._gitcmd('ls-files', '--ignored', '--exclude-standard', '--others', '--', path))
|
||||
return '!!'
|
||||
except StopIteration:
|
||||
return None
|
||||
return None
|
||||
else:
|
||||
wt_column = ' '
|
||||
index_column = ' '
|
||||
|
|
Loading…
Reference in New Issue