{"id":13813825,"url":"https://github.com/rydesun/awesome-github","last_synced_at":"2025-10-19T23:30:29.958Z","repository":{"id":57534480,"uuid":"279046019","full_name":"rydesun/awesome-github","owner":"rydesun","description":"Dive into Awesome lists and explore GitHub repositories for you.","archived":false,"fork":false,"pushed_at":"2023-02-25T06:11:29.000Z","size":122,"stargazers_count":10,"open_issues_count":2,"forks_count":2,"subscribers_count":1,"default_branch":"master","last_synced_at":"2024-05-20T01:16:26.948Z","etag":null,"topics":["awesome","cli-app"],"latest_commit_sha":null,"homepage":"","language":"Go","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/rydesun.png","metadata":{"files":{"readme":"README-zh_CN.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null}},"created_at":"2020-07-12T11:00:53.000Z","updated_at":"2024-03-20T08:30:14.000Z","dependencies_parsed_at":"2024-01-04T20:32:06.531Z","dependency_job_id":null,"html_url":"https://github.com/rydesun/awesome-github","commit_stats":null,"previous_names":[],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rydesun%2Fawesome-github","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rydesun%2Fawesome-github/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rydesun%2Fawesome-github/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/rydesun%2Fawesome-github/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/rydesun","download_url":"https://codeload.github.com/rydesun/awesome-github/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":237226241,"owners_count":19275303,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["awesome","cli-app"],"created_at":"2024-08-04T04:01:31.809Z","updated_at":"2025-10-19T23:30:24.653Z","avatar_url":"https://github.com/rydesun.png","language":"Go","funding_links":[],"categories":["Utilities","Go"],"sub_categories":["Packages"],"readme":"# Awesome GitHub\n\n[![Build](https://github.com/rydesun/awesome-github/workflows/Build/badge.svg)](https://github.com/rydesun/awesome-github/actions?query=workflow%3ABuild)\n[![Unit-Tests](https://github.com/rydesun/awesome-github/workflows/Unit-Tests/badge.svg)](https://github.com/rydesun/awesome-github/actions?query=workflow%3AUnit-Tests)\n[![Coverage Status](https://coveralls.io/repos/github/rydesun/awesome-github/badge.svg?branch=master)](https://coveralls.io/github/rydesun/awesome-github?branch=master)\n[![Go Report Card](https://goreportcard.com/badge/github.com/rydesun/awesome-github)](https://goreportcard.com/report/github.com/rydesun/awesome-github)\n[![License: MIT](https://img.shields.io/badge/License-MIT-blue.svg)](https://github.com/rydesun/awesome-github/blob/master/LICENSE)\n\n通过命令行工具 awg，探索你钟爱的 Awesome GitHub 仓库！\n\n## Awesome Lists\n\n什么是 Awesome Lists？\n\n比如著名的 [awesome-go](https://github.com/avelino/awesome-go) 就是 Awesome Lists 的一员，\n我们可以从中快速找到很多和 Go 相关的框架、库、软件等资源。\n\n不止是 Go，还可以从 [Awesome Lists](https://github.com/topics/awesome)\n寻找更多你感兴趣的内容。\n\n## 命令行工具 awg\n\n当前，Awesome List 一般会列举很多 GitHub 仓库，\n就比如 awesome-go 包含了上千个 GitHub 仓库。\n但是，Awesome List 不包含这些仓库的 star 数、\n更新时间 (最后一次 commit 时间) 之类的信息。\n很多时候，我们需要这些信息作为参考，只能手动打开链接以查看这些仓库的信息。\n\n命令行工具 awg，帮助我们进一步挖掘 Awesome List 中所有 GitHub 仓库的惊人信息！\n\nawg 将一次性获取指定 Awesome List 中的 GitHub 仓库信息，\n并输出获取到的数据到指定文件中。\n稍后可以用 awg 生成一个 [浏览器页面](#浏览器中查看) 用于查看，\n或者你也可以使用喜欢的数据处理工具，比如 jq 和 python，对这些数据进行分析。\n\n![Screenshot](https://user-images.githubusercontent.com/19602440/88459895-f3897480-ce87-11ea-8fe7-13773037c56d.gif)\n\n最终输出的文件内容：\n\n```javascript\n{\n  \"data\": {\n    \"Command Line\": [\n      {\n        \"id\": {\n          \"owner\": \"urfave\",\n          \"name\": \"cli\"\n        },\n        \"owner\": \"urfave\",\n        \"awesome_name\": \"urfave/cli\",\n        \"link\": \"https://github.com/urfave/cli\",\n        \"watch\": 295,\n        \"star\": 14171,\n        \"fork\": 1134,\n        \"last_commit\": \"2020-07-12T13:32:01Z\",\n        \"description\": \"A simple, fast, and fun package for building command line apps in Go\",\n        \"awesome_description\": \"urfave/cli - Simple, fast, and fun package for building command line apps in Go (formerly codegangsta/cli).\"\n      },\n      // ...\n    ]\n    // ...\n  }\n}\n```\n\n### 数据分析\n\n可以使用任何工具去分析获得的数据文件。\n\n比如在获取 awesome-go 的数据文件`awg.json`后，\n\n#### 浏览器中查看\n\n![Screenshot](https://user-images.githubusercontent.com/19602440/89290996-3fd37200-d649-11ea-8807-a6a117d016f0.png)\n\n```bash\n# 获取用于处理数据的JS脚本：view.js\ncurl -fLO https://raw.githubusercontent.com/rydesun/awesome-github/master/web/static/js/view.js\n# 启动服务\nawg view --script view.js --data awg.json avelino/awesome-go\n```\n\n向 awg 提供 view.js 和数据文件，\n并且表明数据文件指向的 awesome list 是 avelino/awesome-go，\n这将在本地运行一个简单的 Web 服务器，默认监听在`127.0.0.1:3000`，\n用浏览器打开此页面。可以使用`--listen`指定其它地址。\n\n注意：这不代表着可以离线查看。互联网的连接是必要的。\n\n甚至可以不需要自己获取数据，直接使用他人提供的远程数据文件！\n用`--data`指定一个 URL，例如`https://example.com/awesome-go.json`(这是一个无效的例子)\n\n```bash\n# 获取用于处理数据的JS脚本：view.js\ncurl -fLO https://raw.githubusercontent.com/rydesun/awesome-github/master/web/static/js/view.js\n# 启动服务\nawg view --script view.js --data https://example.com/awesome-go.json avelino/awesome-go\n```\n\n在指定远程在线的数据文件时，需要在 URL 中加上`http`或者`https`协议，表明来自网络而不是本地。\n\n#### 虚拟终端中查看\n\n通过使用流行的命令行工具 jq，你可以：\n\n查看 awesome-go 列表中 [Command Line](https://github.com/avelino/awesome-go#command-line)\n一节的内容，并按照仓库的 star 数进行排序\n\n```bash\ncat awg.json | jq '.data | .\"Command Line\" | sort_by(.star)'\n```\n\n## 安装\n\n获取命令行工具 awg\n\n```bash\ngo get github.com/rydesun/awesome-github/cmd/awg\n```\n\n## 获取数据\n\n在运行 awg 之前，先准备好：\n\n- GitHub personal access token\n- awg 配置文件\n\n### Access Token\n\nawg 通过调用 GitHub GraphQL API 获取 GitHub 仓库信息，\n该官方 API 需要验证你的 personal access token 后才能使用。\n所以，需要向 awg 提供一个 GitHub personal access token。\n\n如果没有该 token，请先\n[创建 personal access token](https://docs.github.com/en/github/authenticating-to-github/creating-a-personal-access-token)。\n\n注意！awg 不需要该 token 有任何作用域或权限。所以，不要授予该 token 任何作用域或权限。\n\n### 配置\n\n必须准备一个配置文件。可以参考目录`configs`中的\n[配置文件模板](https://github.com/rydesun/awesome-github/blob/master/configs/config.yaml)。\n\nawg 会优先从环境变量`GITHUB_ACCESS_TOKEN`中读取 personal access token，\n所以可以不用将该值储存在配置文件中。\n\n提升并发查询请求数可以提升查询速度，但数量不要过大 (当前推荐值为 3)，\n否则会被 GitHub 视作滥用 API 的行为而遭到临时封禁。\n\n所有的在配置文件中的相对路径，均相对于 awg 的当前工作目录，而不是配置文件所在的目录。\n也可以使用绝对路径。\n\n### 运行\n\n获取 JSON 数据文件\n\n```bash\nawg fetch --config path/to/config.yaml\n```\n\n(推荐) 从环境变量中指定 GitHub Personal Access Token 的形式运行\n\n```bash\nGITHUB_ACCESS_TOKEN=\u003cYour Token\u003e awg fetch --config path/to/config.yaml\n```\n\n请注意速率限制 (RateLimit)，该值不是并发请求数。\n当前 awg 每小时最多查询 5000 个 GitHub 仓库。\n如果查询次数过多，会受到 GitHub 的限制从而导致失败。\n具体信息请参考 [GitHub Resource limitations](https://docs.github.com/en/graphql/overview/resource-limitations#rate-limit)。\n\n## 注意事项\n\n当前该项目仅测试了 awesome-go 的列表，其他 Awesome List 的结果待检验。\n\nawg 不支持 Windows 平台。\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frydesun%2Fawesome-github","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Frydesun%2Fawesome-github","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Frydesun%2Fawesome-github/lists"}