From 2e3e7baffe34bb261b152af50701de2c1529bcd0 Mon Sep 17 00:00:00 2001 From: Frank Zhao Date: Thu, 23 Feb 2023 20:50:01 +0800 Subject: [PATCH] docs(website): add file structure (#1214) Signed-off-by: frank-zsy --- docs/_sidebar.md | 3 +- docs/file_structure.md | 54 ++++++++++++++++++++++++++++++++++++ docs/zh-cn/_sidebar.md | 1 + docs/zh-cn/file_structure.md | 54 ++++++++++++++++++++++++++++++++++++ 4 files changed, 111 insertions(+), 1 deletion(-) create mode 100644 docs/file_structure.md create mode 100644 docs/zh-cn/file_structure.md diff --git a/docs/_sidebar.md b/docs/_sidebar.md index 6fc306db2..0bb17c783 100644 --- a/docs/_sidebar.md +++ b/docs/_sidebar.md @@ -1,7 +1,8 @@ +- [File Structure](/file_structure.md) - [Contributing Guide](/CONTRIBUTING.md) - [Workflow](/workflow.md) - [Data Description](/data.md) - Metrics - [Global OpenRank](/metrics/global_openrank.md) - [Project OpenRank](/metrics/project_openrank.md) - - [Technical Fork](/metrics/technical_fork.md) \ No newline at end of file + - [Technical Fork](/metrics/technical_fork.md) diff --git a/docs/file_structure.md b/docs/file_structure.md new file mode 100644 index 000000000..410a1e76b --- /dev/null +++ b/docs/file_structure.md @@ -0,0 +1,54 @@ +# File structure + +The file structure of OpenDigger are shown as below + +. ++-- .github +|   +-- hypertrons-components +|      +-- auto_update_contribution # A hypertrons workflow to generate CONTRIBUTORS file every week +|   +-- workflows +|      +-- check_label_pr.yml # Action to check label data in pull request +|      +-- node_ci.yml # Action to run unit tests for Node.js libs +|      +-- parse_github_id.yml # Action to parse GitHub ID in label data issue +|      +-- reply-label-issue*.yml # Action to add reply status to issue +|   +-- hypertrons.json # Hypertrons config file ++-- cooperations # Cooperations events or reports with OpenDigger ++-- docs # OpenDigger website root folder, host by GitHub Pages and powered by docsify ++-- labeled_data # All labeled data in OpenDigger ++-- notebook # Notebooks about how to use OpenDigger ++-- python # Python lib to access OpenDigger ++-- sample_data +|   +-- build # Files to build sample data ClickHouse images +|   +-- sql_files # SQL files to export data from ClickHouse +|   +-- export_sample.sh # Shell to export sample data ++-- src # Node.js lib to access OpenDigger +|   +-- ci +|      +-- pull_label_file_test.ts # Source file for pull request label data test action +|      +-- utils.ts # Basic utils to run actions +|   +-- cron # Scheduled tasks +|       +-- tasks +|         +-- monthly_export.ts # Task to export metrics data for every month +|         +-- network_export.ts # Task to export network data for Hypercrx +|         +-- open_galaxy.ts # Task to export data for OpenGalaxy +|         +-- open_leaderboard.ts # Task to export data for OpenLeaderboard +|         +-- remove_renames.ts # Task to remove renamed repos and users on OSS +|       +-- index.ts # Task control +|   +-- db +|      +-- clickhouse.ts # Driver to access ClickHouse database +|      +-- neo4j.ts # Driver to access Neo4j database +|   +-- metrics +|      +-- basic.ts # Basic function to generate SQLs +|      +-- chaoss.ts # Metric implementations of CHAOSS metrics +|      +-- indices.ts # Index implementations +|      +-- metrics.ts # Metrics implementations not from CHAOSS +|      +-- related_users.ts # Related user from graph database +|   +-- config.ts # Config file +|   +-- label_data_utils.ts # Utils to access label data +|   +-- open_digger.js # Expose to Node.js kernel notebook ++-- test +|   +-- driver.test.ts # Unit tests for database drivers +|   +-- label.test.ts # Unit tests for label data and label utils +|   +-- metrics.test.ts # Unit tests for metrics functions ++-- CITATION.cff # Citation file to citate OpenDigger in papers ++-- COUNTRIBUTING.md # Contributing guide ++-- LICENSE # License declaration diff --git a/docs/zh-cn/_sidebar.md b/docs/zh-cn/_sidebar.md index 55f43fd21..b7b4b92e6 100644 --- a/docs/zh-cn/_sidebar.md +++ b/docs/zh-cn/_sidebar.md @@ -1,3 +1,4 @@ +- [文件结构](/zh-cn/file_structure.md) - [贡献指南](/zh-cn/CONTRIBUTING.md) - [工作流](/zh-cn/workflow.md) - [数据描述](/zh-cn/data.md) diff --git a/docs/zh-cn/file_structure.md b/docs/zh-cn/file_structure.md new file mode 100644 index 000000000..e5cc40446 --- /dev/null +++ b/docs/zh-cn/file_structure.md @@ -0,0 +1,54 @@ +# 文件结构 + +以下是 OpenDigger 的文件结构 + +. ++-- .github +|   +-- hypertrons-components +|      +-- auto_update_contribution # 用于每周生成 CONTRIBUTORS 文件的 Hypertrons 组件 +|   +-- workflows +|      +-- check_label_pr.yml # 测试 PR 中标签数据的 action +|      +-- node_ci.yml # 为 Node.js 代码提供测试的 action +|      +-- parse_github_id.yml # 用来解析 Issue 中的 GitHub ID 的 action +|      +-- reply-label-issue*.yml # 用来为 Issue 添加回复状态的 action +|   +-- hypertrons.json # Hypertrons 配置文件 ++-- cooperations # OpenDigger 合作的大赛或报告 ++-- docs # OpenDigger 官网文件夹,由 GitHub Pages 与 Docsify 服务 ++-- labeled_data # OpenDigger 中的所有标签数据 ++-- notebook # 使用 OpenDigger 的 Notebook 文件 ++-- python # 用于使用 OpenDigger 的 Python 库 ++-- sample_data # 样例数据的相关文件 +|   +-- build # 用于构建 ClickHouse 镜像的文件 +|   +-- sql_files # 从 ClickHouse 导出样例数据的 SQL 文件 +|   +-- export_sample.sh # 用于导出样例数据的脚本 ++-- src # 用于使用 OpenDigger 的 Node.js 库 +|   +-- ci +|      +-- pull_label_file_test.ts # PR 测试标签数据文件的 action 源文件 +|      +-- utils.ts # 运行 action 的基础工具 +|   +-- cron # 定时任务 +|      +-- tasks +|         +-- monthly_export.ts # 用于每月导出指标数据的任务 +|         +-- network_export.ts # 用于为 Hypercrx 导出网络数据的任务 +|         +-- open_galaxy.ts # 用于为 OpenGalaxy 导出数据的任务 +|         +-- open_leaderboard.ts # 用于为 OpenLeaderboard 导出数据的任务 +|         +-- remove_renames.ts # 用于删除 OSS 上更名仓库或用户数据的任务 +|      +-- index.ts # 任务控制器 +|   +-- db +|      +-- clickhouse.ts # 用于访问 ClickHouse 数据库的底层库 +|      +-- neo4j.ts # 用于访问 Neo4j 图数据库的底层库 +|   +-- metrics +|      +-- basic.ts # 用于生成 SQL 的底层通用函数 +|      +-- chaoss.ts # CHAOSS 度量的具体实现 +|      +-- indices.ts # 指标的具体实现 +|      +-- metrics.ts # 非 CHAOSS 度量的具体实现 +|      +-- related_users.ts # 图数据库获取关联用户的实现 +|   +-- config.ts # 配置文件 +|   +-- label_data_utils.ts # 访问标签数据的函数库 +|   +-- open_digger.js # 向 Node.js 内核的 Notebook 暴露的接口 ++-- test +|   +-- driver.test.ts # 数据库底层库的单元测试 +|   +-- label.test.ts # 标签数据与工具的单元测试 +|   +-- metrics.test.ts # 度量与指标函数的单元测试 ++-- CITATION.cff # 在论文中引用 OpenDigger 的文本 ++-- COUNTRIBUTING.md # 贡献指南 ++-- LICENSE # 许可声明