gpt4 book ai didi

GitHub API - 语言列表

转载 作者:行者123 更新时间:2023-12-04 22:11:28 25 4
gpt4 key购买 nike

GitHub API 中是否有一个端点可以为我提供 GitHub 上所有语言的列表?我正在寻找与 github.com 网站“趋势”部分中的“语言”下拉菜单类似的结果。

最佳答案

不是直接来自 GitHub API。

OP AgileAce添加 the comments :

I've discovered that there is a Linguist library maintained by GitHub.
In this repo, there is a YAML file (lib/linguist/languages.yml) containing all the languages, and related info.
I'm just going to write a script that will parse this file.

我在“How does github figure out a project's language?”中提到了语言学家图书馆。


您还可以从各种 GitHub 统计站点获取该数据,例如 www.githubarchive.org :

参见“Top Github Languages for 2013 (so far)”,作者:ADAM BARD:

I just discovered the Github Archive, a dataset of Github events queryable using Google BigQuery. What fun! So I decided to count how many repositories have been created this year by language.

SELECT repository_language, count(repository_language) AS repos_by_lang
FROM [githubarchive:github.timeline]
WHERE repository_fork == "false"
AND type == "CreateEvent"
AND PARSE_UTC_USEC(repository_created_at) >= PARSE_UTC_USEC('2013-01-01 00:00:00')
AND PARSE_UTC_USEC(repository_created_at) < PARSE_UTC_USEC('2013-08-30 00:00:00')
GROUP BY repository_language
ORDER BY repos_by_lang DESC
LIMIT 100

coderstats.net也可能是一个很好的来源,它的 language section .

关于GitHub API - 语言列表,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/21423956/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com