diff options
author | Kostis Anagnostopoulos <ankostis@gmail.com> | 2016-10-21 00:33:43 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2016-10-21 00:33:43 +0200 |
commit | afcd64ebbb770908bd2a751279ff070dea5bb97c (patch) | |
tree | 0674f49f45996d533890e0f67498a6038c590168 /git/objects | |
parent | aab7dc2c7771118064334ee475dff8a6bb176b57 (diff) | |
parent | 66c41eb3b2b4130c7b68802dd2078534d1f6bf7a (diff) | |
download | gitpython-afcd64ebbb770908bd2a751279ff070dea5bb97c.tar.gz |
Merge pull request #539 from bryant1410/typos
Fix some typos
Diffstat (limited to 'git/objects')
-rw-r--r-- | git/objects/base.py | 6 | ||||
-rw-r--r-- | git/objects/commit.py | 4 | ||||
-rw-r--r-- | git/objects/submodule/base.py | 10 | ||||
-rw-r--r-- | git/objects/tree.py | 6 | ||||
-rw-r--r-- | git/objects/util.py | 8 |
5 files changed, 17 insertions, 17 deletions
diff --git a/git/objects/base.py b/git/objects/base.py index 0b849960..8027299c 100644 --- a/git/objects/base.py +++ b/git/objects/base.py @@ -127,7 +127,7 @@ class IndexObject(Object): SubModule objects""" __slots__ = ("path", "mode") - # for compatability with iterable lists + # for compatibility with iterable lists _id_attribute_ = 'path' def __init__(self, repo, binsha, mode=None, path=None): @@ -137,7 +137,7 @@ class IndexObject(Object): :param binsha: 20 byte sha1 :param mode: is the stat compatible file mode as int, use the stat module - to evaluate the infomration + to evaluate the information :param path: is the path to the file in the file system, relative to the git repository root, i.e. file.ext or folder/other.ext @@ -165,7 +165,7 @@ class IndexObject(Object): % (attr, type(self).__name__)) else: super(IndexObject, self)._set_cache_(attr) - # END hanlde slot attribute + # END handle slot attribute @property def name(self): diff --git a/git/objects/commit.py b/git/objects/commit.py index 1534c552..e537c0bb 100644 --- a/git/objects/commit.py +++ b/git/objects/commit.py @@ -163,7 +163,7 @@ class Commit(base.Object, Iterable, Diffable, Traversable, Serializable): """Count the number of commits reachable from this commit :param paths: - is an optinal path or a list of paths restricting the return value + is an optional path or a list of paths restricting the return value to commits actually containing the paths :param kwargs: @@ -192,7 +192,7 @@ class Commit(base.Object, Iterable, Diffable, Traversable, Serializable): :param repo: is the Repo :param rev: revision specifier, see git-rev-parse for viable options :param paths: - is an optinal path or list of paths, if set only Commits that include the path + is an optional path or list of paths, if set only Commits that include the path or paths will be considered :param kwargs: optional keyword arguments to git rev-list where diff --git a/git/objects/submodule/base.py b/git/objects/submodule/base.py index 9bb563d7..2e265a54 100644 --- a/git/objects/submodule/base.py +++ b/git/objects/submodule/base.py @@ -69,7 +69,7 @@ UPDWKTREE = UpdateProgress.UPDWKTREE # IndexObject comes via util module, its a 'hacky' fix thanks to pythons import # mechanism which cause plenty of trouble of the only reason for packages and -# modules is refactoring - subpackages shoudn't depend on parent packages +# modules is refactoring - subpackages shouldn't depend on parent packages class Submodule(IndexObject, Iterable, Traversable): """Implements access to a git submodule. They are special in that their sha @@ -137,7 +137,7 @@ class Submodule(IndexObject, Iterable, Traversable): return type(self).list_items(item.module()) except InvalidGitRepositoryError: return list() - # END handle intermeditate items + # END handle intermediate items @classmethod def _need_gitfile_submodules(cls, git): @@ -178,7 +178,7 @@ class Submodule(IndexObject, Iterable, Traversable): except ValueError: # We are most likely in an empty repository, so the HEAD doesn't point to a valid ref pass - # end hanlde parent_commit + # end handle parent_commit if not repo.bare and parent_matches_head: fp_module = os.path.join(repo.working_tree_dir, cls.k_modules_file) @@ -221,7 +221,7 @@ class Submodule(IndexObject, Iterable, Traversable): pc = self.parent_commit except ValueError: pc = None - # end hande empty parent repository + # end handle empty parent repository parser = self._config_parser(self.repo, pc, read_only) parser.set_submodule(self) return SectionConstraint(parser, sm_section(self.name)) @@ -940,7 +940,7 @@ class Submodule(IndexObject, Iterable, Traversable): # END handle checking mode # update our sha, it could have changed - # If check is False, we might see a parent-commit that doens't even contain the submodule anymore. + # If check is False, we might see a parent-commit that doesn't even contain the submodule anymore. # in that case, mark our sha as being NULL try: self.binsha = pctree[self.path].binsha diff --git a/git/objects/tree.py b/git/objects/tree.py index 4f853f92..18c0add1 100644 --- a/git/objects/tree.py +++ b/git/objects/tree.py @@ -77,7 +77,7 @@ class TreeModifier(object): """A utility class providing methods to alter the underlying cache in a list-like fashion. - Once all adjustments are complete, the _cache, which really is a refernce to + Once all adjustments are complete, the _cache, which really is a reference to the cache of a tree, will be sorted. Assuring it will be in a serializable state""" __slots__ = '_cache' @@ -294,7 +294,7 @@ class Tree(IndexObject, diff.Diffable, util.Traversable, util.Serializable): return self._map_id_to_type[info[1] >> 12](self.repo, info[0], info[1], join_path(self.path, info[2])) if isinstance(item, string_types): - # compatability + # compatibility return self.join(item) # END index is basestring @@ -308,7 +308,7 @@ class Tree(IndexObject, diff.Diffable, util.Traversable, util.Serializable): # END compare sha # END for each entry # END handle item is index object - # compatability + # compatibility # treat item as repo-relative path path = self.path diff --git a/git/objects/util.py b/git/objects/util.py index cbb9fe3c..5c085aec 100644 --- a/git/objects/util.py +++ b/git/objects/util.py @@ -270,7 +270,7 @@ class Traversable(object): def traverse(self, predicate=lambda i, d: True, prune=lambda i, d: False, depth=-1, branch_first=True, visit_once=True, ignore_self=1, as_edge=False): - """:return: iterator yieling of items found when traversing self + """:return: iterator yielding of items found when traversing self :param predicate: f(i,d) returns False if item i at depth d should not be included in the result @@ -282,7 +282,7 @@ class Traversable(object): define at which level the iteration should not go deeper if -1, there is no limit if 0, you would effectively only get self, the root of the iteration - i.e. if 1, you would only get the first level of predessessors/successors + i.e. if 1, you would only get the first level of predecessors/successors :param branch_first: if True, items will be returned branch first, otherwise depth first @@ -298,7 +298,7 @@ class Traversable(object): :param as_edge: if True, return a pair of items, first being the source, second the - destinatination, i.e. tuple(src, dest) with the edge spanning from + destination, i.e. tuple(src, dest) with the edge spanning from source to destination""" visited = set() stack = Deque() @@ -348,7 +348,7 @@ class Serializable(object): def _serialize(self, stream): """Serialize the data of this object into the given data stream - :note: a serialized object would ``_deserialize`` into the same objet + :note: a serialized object would ``_deserialize`` into the same object :param stream: a file-like object :return: self""" raise NotImplementedError("To be implemented in subclass") |