mirror of
https://github.com/clearml/clearml
synced 2025-03-03 18:52:12 +00:00
Add git diff on repository submodule (requires git 2.14 or above)
This commit is contained in:
parent
3466cc0789
commit
2a2d4b6114
@ -65,6 +65,7 @@ class Detector(object):
|
|||||||
modified = attr.ib(default=None, type=list)
|
modified = attr.ib(default=None, type=list)
|
||||||
# alternative commands
|
# alternative commands
|
||||||
branch_fallback = attr.ib(default=None, type=list)
|
branch_fallback = attr.ib(default=None, type=list)
|
||||||
|
diff_fallback = attr.ib(default=None, type=list)
|
||||||
|
|
||||||
def __init__(self, type_name, name=None):
|
def __init__(self, type_name, name=None):
|
||||||
self.type_name = type_name
|
self.type_name = type_name
|
||||||
@ -195,9 +196,10 @@ class GitDetector(Detector):
|
|||||||
commit=["git", "rev-parse", "HEAD"],
|
commit=["git", "rev-parse", "HEAD"],
|
||||||
root=["git", "rev-parse", "--show-toplevel"],
|
root=["git", "rev-parse", "--show-toplevel"],
|
||||||
status=["git", "status", "-s"],
|
status=["git", "status", "-s"],
|
||||||
diff=["git", "diff"],
|
diff=["git", "diff", "--submodule=diff"],
|
||||||
modified=["git", "ls-files", "-m"],
|
modified=["git", "ls-files", "-m"],
|
||||||
branch_fallback=["git", "rev-parse", "--abbrev-ref", "HEAD"],
|
branch_fallback=["git", "rev-parse", "--abbrev-ref", "HEAD"],
|
||||||
|
diff_fallback=["git", "diff"],
|
||||||
)
|
)
|
||||||
|
|
||||||
def _post_process_info(self, info):
|
def _post_process_info(self, info):
|
||||||
|
Loading…
Reference in New Issue
Block a user