MCPcopy Create free account
hub / github.com/gitless-vcs/gitless / Index

Class Index

gitless/core.py:698–713  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

696 def _index(self):
697 """Convenience wrapper of Git's index."""
698 class Index(object):
699
700 def __init__(self, git_index):
701 self._git_index = git_index
702 self._git_index.read()
703
704 def __enter__(self):
705 return self
706
707 def __exit__(self, type, value, traceback):
708 if not value: # no exception
709 self._git_index.write()
710 return True
711
712 def __getattr__(self, name):
713 return getattr(self._git_index, name)
714
715 return Index(self.gl_repo.git_repo.index)
716

Callers 1

_indexMethod · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected