diff options
author | Yobmod <yobmod@gmail.com> | 2021-07-06 17:00:44 +0100 |
---|---|---|
committer | Yobmod <yobmod@gmail.com> | 2021-07-06 17:00:44 +0100 |
commit | f372187ade056a3069e68ba0a90bf53bd7d7e464 (patch) | |
tree | 1b2437ba83d1fbff53abb40e3735a5d20bc9f084 | |
parent | af7cee514632a4a3825dbb5655a208d2ebd1f67f (diff) | |
download | gitpython-f372187ade056a3069e68ba0a90bf53bd7d7e464.tar.gz |
Make subodule a forward ref in Index.base3
-rw-r--r-- | git/index/base.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/git/index/base.py b/git/index/base.py index 5a564b8c..edb79edf 100644 --- a/git/index/base.py +++ b/git/index/base.py @@ -593,7 +593,7 @@ class IndexFile(LazyMixin, diff.Diffable, Serializable): raise ValueError("Absolute path %r is not in git repository at %r" % (path, self.repo.working_tree_dir)) return os.path.relpath(path, self.repo.working_tree_dir) - def _preprocess_add_items(self, items: Sequence[Union[PathLike, Blob, BaseIndexEntry, Submodule]] + def _preprocess_add_items(self, items: Sequence[Union[PathLike, Blob, BaseIndexEntry, 'Submodule']] ) -> Tuple[List[PathLike], List[BaseIndexEntry]]: """ Split the items into two lists of path strings and BaseEntries. """ paths = [] @@ -664,7 +664,7 @@ class IndexFile(LazyMixin, diff.Diffable, Serializable): # END path handling return entries_added - def add(self, items: Sequence[Union[PathLike, Blob, BaseIndexEntry, Submodule]], force: bool = True, + def add(self, items: Sequence[Union[PathLike, Blob, BaseIndexEntry, 'Submodule']], force: bool = True, fprogress: Callable = lambda *args: None, path_rewriter: Callable = None, write: bool = True, write_extension_data: bool = False) -> List[BaseIndexEntry]: """Add files from the working tree, specific blobs or BaseIndexEntries |