MCPcopy Create free account
hub / github.com/Persper/code-analytics / get_contents

Function get_contents

persper/analytics/git_tools.py:36–40  ·  view source on GitHub ↗

Get contents of a path within a specific commit

(repo, commit, path)

Source from the content-addressed store, hash-verified

34
35
36def get_contents(repo, commit, path):
37 """Get contents of a path within a specific commit"""
38 if type(commit) == Commit:
39 commit = commit.hexsha
40 return repo.git.show('{}:{}'.format(commit, path))

Callers 2

_analyze_commitMethod · 0.90
_analyzeCommitMethod · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected