Github:我能看到回购的下载次数吗? [英] Github: Can I see the number of downloads for a repo?

查看:564
本文介绍了Github:我能看到回购的下载次数吗?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在Github中,有没有办法可以看到回购下载的数量?

解决方案

更新2017年b / b
$ b

不再有交通屏幕提及回购克隆的数量。

相反,您必须依赖第三方服务






2014年8月更新



GitHub还在其流量图中提出了回购的克隆数量:

请参阅通过 andyberry88 和作为我详述最后七月,GitHub的现在建议发布(请参阅其API ),其中具有 download_count 字段



Michele Milidoni 他的(upvoted)答案中,在他的python脚本
非常小的提取物



  c.setopt(c.URL,'https://api.github.com/repos/'+ full_name +'/ releases' )
for myobj:
如果p中包含assets:
中包含p ['assets']中的资产:
print(asset ['name'] +: + str(资产['download_count'])+
下载)






原始答案(2010年12月)

我不确定你能否看到这些信息(如果它被记录的话),因为我没有在 GitHub存储库API 中看到它:

  $ curl http://github.com/api/v2/yaml/repos/show/schacon/grit 
---
存储库:
:名称:砂砾
:所有者:schacon
:源: mojombo /砂砾#金字塔
顶部的原始回购:父:德芬克特/砂砾#这个回购的直接父
:说明:砂砾是一个Ruby库从
Git仓库中提取信息以面向对象的方式 - 这个分支尝试
集成尽可能多的纯ruby功能
:分支:4
:watchers:67
:private:false
:url:http://github.com/schacon/grit
:fork:true
:homepage:http://grit.rubyforge.org/
:has_wiki:true
:has_issues:false
:has_downloads:true

您只能看到它是否有下载与否。


In Github, is there a way I can see the number of downloads for a repo?

解决方案

Update 2017

There is no longer a traffic screen mentioning the number of repo clones.
Instead, you have to rely on third-party services like GitItBack (at www.netguru.co/gititback) but even that does not include the number of clones.

You still can use the GitHub API to get the download count for your releases (which is not exactly what was asked)
See "Get a single release", the download_count field.

See also www.somsubhra.com/github-release-stats, mentioned below.
For instance, here are the number for the latest git for Windows release


Update August 2014

GitHub also proposes the number of clones for a repo in its Traffic Graph:
See "Clone Graphs"


Update October 2013

As mentioned below by andyberry88, and as I detailed last July, GitHub now proposes releases (see its API), which has a download_count field.

Michele Milidoni, in his (upvoted) answer, does use that field in his python script.
(very small extract)

c.setopt(c.URL, 'https://api.github.com/repos/' + full_name + '/releases')
for p in myobj:
    if "assets" in p:
        for asset in p['assets']:
            print (asset['name'] + ": " + str(asset['download_count']) +
                   " downloads")


Original answer (December 2010)

I am not sure you can see that information (if it is recorded at all), because I don't see it in the GitHub Repository API:

$ curl http://github.com/api/v2/yaml/repos/show/schacon/grit
---
repository:
  :name: grit
  :owner: schacon
  :source: mojombo/grit # The original repo at top of the pyramid
  :parent: defunkt/grit # This repo's direct parent
  :description: Grit is a Ruby library for extracting information from a
  git repository in an object oriented manner - this fork tries to
  intergrate as much pure-ruby functionality as possible
  :forks: 4
  :watchers: 67
  :private: false
  :url: http://github.com/schacon/grit
  :fork: true
  :homepage: http://grit.rubyforge.org/
  :has_wiki: true
  :has_issues: false
  :has_downloads: true

You can only see if it has downloads or not.

这篇关于Github:我能看到回购的下载次数吗?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆