← Back to team overview

dulwich-users team mailing list archive

Re: how to create an object from a SHA1 value

 

On 20:39 Tue 14 Aug     , Wenhao Xu wrote:
> Hi everyone,
> 
> I am new to dulwich and want to implement some functions like "git
> cat-file". I am wondering given a SH1 value, how to construct an object
> from it? I looked through the doc with no luck.

With any SHA1, you can use repo.get_object(sha1). What it returns is
based on what that sha1 represents - be it a commit, a blog, etc.

-milki


Follow ups

References