Skip to content
This repository was archived by the owner on Sep 11, 2020. It is now read-only.

packfile: get object size correctly for delta objects #1060

Merged

Conversation

strib
Copy link
Contributor

@strib strib commented Feb 1, 2019

Signed-off-by: Jeremy Stribling strib@alum.mit.edu

Signed-off-by: Jeremy Stribling <strib@alum.mit.edu>
defer packfile.Close()

// Get the size of binary.jpg, which is not delta-encoded.
offset, err := packfile.FindOffset(plumbing.NewHash("d5c0f4ab811897cadf03aec358ae60d21f91c50d"))
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please let me know if there's a non-hardcoded way to get this hash.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not really

@mcuadros mcuadros merged commit 00629a1 into src-d:master Feb 5, 2019
# for free to subscribe to this conversation on GitHub. Already have an account? #.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants