Add repo_blob #121

Closed
lunny wants to merge 1 commits from clee/add-repo-blob into master
Owner

Author: @clee

This adds a new Repository.GetBlob(id) method for use by gitea.

Part of an attempt to fix go-gitea/gitea#4048.

Author: @clee This adds a new `Repository.GetBlob(id)` method for use by gitea. Part of an attempt to fix go-gitea/gitea#4048.
Author
Owner

Author: @lunny

@clee could you add some unit test?

Author: @lunny @clee could you add some unit test?
Author
Owner

Author: @clee

@lunny I added a test for GetBlob, but, uh... maybe I'm doing something wrong? Try running the test and see what you get. Is Blob.Data() returning the right data?

Author: @clee @lunny I added a test for `GetBlob`, but, uh... maybe I'm doing something wrong? Try running the test and see what you get. Is `Blob.Data()` returning the right data?
Author
Owner

Author: @clee

I think I figured it out. I copied the Blob initializer from blob_test.go, and it's setting the ptree to the root of the repository. I need to figure out how to rebuild the parent tree from just having the SHA.

Author: @clee I think I figured it out. I copied the `Blob` initializer from `blob_test.go`, and it's setting the `ptree` to the root of the repository. I need to figure out how to rebuild the parent tree from just having the SHA.
Author
Owner

Author: @ghost

Any update?

Author: @ghost Any update?
Author
Owner

Author: @lafriks

Closing in favour of #132

Author: @lafriks Closing in favour of #132
This repo is archived. You cannot comment on pull requests.
No description provided.