Sachin
Sachin

Reputation: 3782

What does the parameter size mean in Github Repo information

I am using Github API to fetch the repo information. In that there is a parameter 'size', its not written in github api documentation what it exactly means. Is it the size of lines of code committed to the repository in bytes?

Here you can see the size parameter in the response returned http://developer.github.com/v3/repos/

Upvotes: 6

Views: 2593

Answers (1)

VonC
VonC

Reputation: 1329112

Considering the commands are for a full repo (list, get, edit, ...), it should reference the full size of the elements in that repo, as mentioned in "See the size of a github repo before cloning it?".

It seems to be in Kb:

  • for small repos like the example repo "HelloWorld": "size": 140,: once I clone it, it register on my hard-drive slightly under 140 Kb,
  • and for larger repos (like the git repo itself, more than 40Mo: "size": 40844,).

Update (February 2013, from nulltoken's comment)

The answer "See the size of a github repo before cloning it?" confirms that the size is in Kb for git alternates objects.

The disk usage against the bare repository doesn't account for the shared object store and thus returns an "incomplete" value through the API call.

Upvotes: 8

Related Questions