@ -609,6 +609,12 @@
< li >
< a href = "#list-pull-requests" class = "toc-h2 toc-link" data-title = "List pull requests" > List pull requests< / a >
< / li >
< li >
< a href = "#12fc53a2d2" class = "toc-h2 toc-link" data-title = "获取合并请求版本列表" > 获取合并请求版本列表< / a >
< / li >
< li >
< a href = "#diff" class = "toc-h2 toc-link" data-title = "获取合并请求版本Diff" > 获取合并请求版本Diff< / a >
< / li >
< / ul >
< / li >
< li >
@ -10786,7 +10792,7 @@ http://localhost:3000/api/v1/yystopf/csfjkkj/compare.json
< tr >
< td > diff.files.is_lfs_file< / td >
< td > bool< / td >
< td > < / td >
< td > 是否为LFS文件 < / td >
< / tr >
< tr >
< td > diff.files.is_renamed< / td >
@ -10816,12 +10822,12 @@ http://localhost:3000/api/v1/yystopf/csfjkkj/compare.json
< tr >
< td > diff.files.sections.lines.left_index< / td >
< td > int< / td >
< td > < / td >
< td > 文件变动之前所在行数 < / td >
< / tr >
< tr >
< td > diff.files.sections.lines.right_index< / td >
< td > int< / td >
< td > < / td >
< td > 文件变动之后所在行数 < / td >
< / tr >
< tr >
< td > diff.files.sections.lines.match< / td >
@ -10831,17 +10837,17 @@ http://localhost:3000/api/v1/yystopf/csfjkkj/compare.json
< tr >
< td > diff.files.sections.lines.type< / td >
< td > int< / td >
< td > < / td >
< td > 文件变更类型 < / td >
< / tr >
< tr >
< td > diff.files.sections.lines.content< / td >
< td > string< / td >
< td > < / td >
< td > 文件变更内容 < / td >
< / tr >
< tr >
< td > diff.files.sections.lines.section_path< / td >
< td > string< / td >
< td > < / td >
< td > 文件路径 < / td >
< / tr >
< tr >
< td > diff.files.sections.lines.section_last_left_index< / td >
@ -10856,22 +10862,37 @@ http://localhost:3000/api/v1/yystopf/csfjkkj/compare.json
< tr >
< td > diff.files.sections.lines.section_left_index< / td >
< td > int< / td >
< td > < / td >
< td > 文件变更之前所在行数 < / td >
< / tr >
< tr >
< td > diff.files.sections.lines.section_right_index< / td >
< td > int< / td >
< td > < / td >
< td > 文件变更之后所在行数(即:页面编辑器开始显示的行数) < / td >
< / tr >
< tr >
< td > diff.files.sections.lines.section_left_hunk_size< / td >
< td > int< / td >
< td > < / td >
< td > 文件变更之前的行数 < / td >
< / tr >
< tr >
< td > diff.files.sections.lines.section_right_hunk_size< / td >
< td > int< / td >
< td > < / td >
< td > 文件变更之后的行数(及当前页面编辑器显示的总行数)< / td >
< / tr >
< tr >
< td > diff.files.is_incomplete< / td >
< td > bool< / td >
< td > 是否不完整< / td >
< / tr >
< tr >
< td > diff.files.is_incomplete_line_too_long< / td >
< td > bool< / td >
< td > 文件是否不完整是因为太长了< / td >
< / tr >
< tr >
< td > diff.files.is_protected< / td >
< td > bool< / td >
< td > 文件是否被保护< / td >
< / tr >
< / tbody > < / table >
@ -12936,6 +12957,670 @@ http://localhost:3000/api/Jason/test-txt/compare/master...Jason/test-txt:develop
< / span > < span class = "p" > }< / span > < span class = "w" >
< / span > < span class = "p" > ]< / span > < span class = "w" >
< / span > < span class = "p" > }< / span > < span class = "w" >
< / span > < / code > < / pre > < / div > < h2 id = '12fc53a2d2' > 获取合并请求版本列表< / h2 >
< p > 获取合并请求版本列表< / p >
< blockquote >
< p > 示例:< / p >
< / blockquote >
< div class = "highlight" > < pre class = "highlight shell tab-shell" > < code > curl < span class = "nt" > -X< / span > GET http://localhost:3000/api/v1/yystopf/ceshi_commit/pulls/3/versions.json
< / code > < / pre > < / div > < div class = "highlight" > < pre class = "highlight javascript tab-javascript" > < code > < span class = "k" > await< / span > < span class = "nx" > octokit< / span > < span class = "p" > .< / span > < span class = "nx" > request< / span > < span class = "p" > (< / span > < span class = "dl" > '< / span > < span class = "s1" > GET /api/v1/yystopf/ceshi_commit/pulls/3/versions.json< / span > < span class = "dl" > '< / span > < span class = "p" > )< / span >
< / code > < / pre > < / div > < h3 id = 'http-6' > HTTP 请求< / h3 >
< p > < code > GET /api/v1/:owner/:repo/pulls/:index/versions.json< / code > < / p >
< h3 id = '2eb6f47757-6' > 请求参数:< / h3 >
< table > < thead >
< tr >
< th > 参数< / th >
< th > 必选< / th >
< th > 默认< / th >
< th > 类型< / th >
< th > 字段说明< / th >
< / tr >
< / thead > < tbody >
< tr >
< td > owner< / td >
< td > 是< / td >
< td > < / td >
< td > string< / td >
< td > 用户登录名< / td >
< / tr >
< tr >
< td > repo< / td >
< td > 是< / td >
< td > < / td >
< td > string< / td >
< td > 项目标识identifier< / td >
< / tr >
< tr >
< td > index< / td >
< td > 是< / td >
< td > < / td >
< td > int< / td >
< td > 合并请求序号< / td >
< / tr >
< / tbody > < / table >
< h3 id = '7447e4874e-4' > 返回字段说明:< / h3 >
< table > < thead >
< tr >
< th > 参数< / th >
< th > 类型< / th >
< th > 字段说明< / th >
< / tr >
< / thead > < tbody >
< tr >
< td > total_count< / td >
< td > int< / td >
< td > 合并请求版本总数< / td >
< / tr >
< tr >
< td > versions.id< / td >
< td > int< / td >
< td > 版本ID< / td >
< / tr >
< tr >
< td > versions.add_line_num< / td >
< td > int< / td >
< td > 该版本新增行数< / td >
< / tr >
< tr >
< td > versions.del_line_num< / td >
< td > int< / td >
< td > 该版本删除行数< / td >
< / tr >
< tr >
< td > versions.commits_count< / td >
< td > int< / td >
< td > 该版本提交总数< / td >
< / tr >
< tr >
< td > versions.files_count< / td >
< td > int< / td >
< td > 该版本提交文件总数< / td >
< / tr >
< tr >
< td > versions.base_commit_sha< / td >
< td > string< / td >
< td > 目标commit ID< / td >
< / tr >
< tr >
< td > versions.head_commit_sha< / td >
< td > string< / td >
< td > 源commit ID< / td >
< / tr >
< tr >
< td > versions.start_commit_sha< / td >
< td > string< / td >
< td > 该版本起始commit ID< / td >
< / tr >
< tr >
< td > versions.created_time< / td >
< td > int< / td >
< td > 版本创建时间< / td >
< / tr >
< tr >
< td > versions.updated_time< / td >
< td > int< / td >
< td > 版本更新时间< / td >
< / tr >
< / tbody > < / table >
< blockquote >
< p > 返回的JSON示例:< / p >
< / blockquote >
< div class = "highlight" > < pre class = "highlight json tab-json" > < code > < span class = "p" > {< / span > < span class = "w" >
< / span > < span class = "nl" > "total_count"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 1< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "versions"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "p" > [< / span > < span class = "w" >
< / span > < span class = "p" > {< / span > < span class = "w" >
< / span > < span class = "nl" > "id"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 33< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "add_line_num"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 5< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "del_line_num"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 2< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "commits_count"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 31< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "files_count"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 29< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "base_commit_sha"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "s2" > "4a277037093c1248e46d2946ee30b61cccdb9df9"< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "head_commit_sha"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "s2" > "fa3b1cdc8e0727d0fb9c96d28c545867c39815b8"< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "start_commit_sha"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "s2" > "e49b1fd335e093a440fcf35a21e050afd48ef932"< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "created_time"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 1658469499< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "updated_time"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 1658469499< / span > < span class = "w" >
< / span > < span class = "p" > }< / span > < span class = "w" >
< / span > < span class = "p" > ]< / span > < span class = "w" >
< / span > < span class = "p" > }< / span > < span class = "w" >
< / span > < / code > < / pre > < / div > < h2 id = 'diff' > 获取合并请求版本Diff< / h2 >
< p > 获取合并请求版本Diff( 支持获取单文件Diff) < / p >
< blockquote >
< p > 示例:< / p >
< / blockquote >
< div class = "highlight" > < pre class = "highlight shell tab-shell" > < code > curl < span class = "nt" > -X< / span > GET < span class = "se" > \< / span >
< span class = "nt" > -d< / span > < span class = "s2" > "filepath=ceshi_dir_1/new_file_1"< / span > < span class = "se" > \< / span >
http://localhost:3000/api/v1/yystopf/ceshi_commit/pulls/3/versions/33/diff.json
< / code > < / pre > < / div > < div class = "highlight" > < pre class = "highlight javascript tab-javascript" > < code > < span class = "k" > await< / span > < span class = "nx" > octokit< / span > < span class = "p" > .< / span > < span class = "nx" > request< / span > < span class = "p" > (< / span > < span class = "dl" > '< / span > < span class = "s1" > GET /api/v1/yystopf/ceshi_commit/pulls/3/versions/33/diff.json< / span > < span class = "dl" > '< / span > < span class = "p" > )< / span >
< / code > < / pre > < / div > < h3 id = 'http-7' > HTTP 请求< / h3 >
< p > < code > GET /api/v1/:owner/:repo/pulls/:index/versions/:version_id/diff.json< / code > < / p >
< h3 id = '2eb6f47757-7' > 请求参数:< / h3 >
< table > < thead >
< tr >
< th > 参数< / th >
< th > 必选< / th >
< th > 默认< / th >
< th > 类型< / th >
< th > 字段说明< / th >
< / tr >
< / thead > < tbody >
< tr >
< td > owner< / td >
< td > 是< / td >
< td > < / td >
< td > string< / td >
< td > 用户登录名< / td >
< / tr >
< tr >
< td > repo< / td >
< td > 是< / td >
< td > < / td >
< td > string< / td >
< td > 项目标识identifier< / td >
< / tr >
< tr >
< td > index< / td >
< td > 是< / td >
< td > < / td >
< td > int< / td >
< td > 合并请求序号< / td >
< / tr >
< tr >
< td > version_id< / td >
< td > 是< / td >
< td > < / td >
< td > int< / td >
< td > 版本ID< / td >
< / tr >
< tr >
< td > filepath< / td >
< td > 否< / td >
< td > < / td >
< td > string< / td >
< td > 文件路径< / td >
< / tr >
< / tbody > < / table >
< h3 id = 'a88770b445' > 列表返回字段说明:< / h3 >
< table > < thead >
< tr >
< th > 参数< / th >
< th > 类型< / th >
< th > 字段说明< / th >
< / tr >
< / thead > < tbody >
< tr >
< td > file_nums< / td >
< td > int< / td >
< td > 文件数量< / td >
< / tr >
< tr >
< td > total_addition< / td >
< td > int< / td >
< td > 新增行数< / td >
< / tr >
< tr >
< td > total_deletion< / td >
< td > int< / td >
< td > 删除行数< / td >
< / tr >
< tr >
< td > files.name< / td >
< td > string< / td >
< td > 文件名称< / td >
< / tr >
< tr >
< td > files.oldname< / td >
< td > string< / td >
< td > 文件修改前名称< / td >
< / tr >
< tr >
< td > files.addition< / td >
< td > int< / td >
< td > 文件新增行数< / td >
< / tr >
< tr >
< td > files.deletion< / td >
< td > int< / td >
< td > 文件删除行数< / td >
< / tr >
< tr >
< td > files.type< / td >
< td > int< / td >
< td > 文件类型 1: 新增 2: 更改 3: 删除 4: 重命名 5: 复制< / td >
< / tr >
< tr >
< td > files.is_created< / td >
< td > bool< / td >
< td > 是否为新建文件< / td >
< / tr >
< tr >
< td > files.is_deleted< / td >
< td > bool< / td >
< td > 是否为删除文件< / td >
< / tr >
< tr >
< td > files.is_bin< / td >
< td > bool< / td >
< td > 是否为二进制文件< / td >
< / tr >
< tr >
< td > files.is_lfs_file< / td >
< td > bool< / td >
< td > 是否为LFS文件< / td >
< / tr >
< tr >
< td > files.is_renamed< / td >
< td > bool< / td >
< td > 是否重命名< / td >
< / tr >
< tr >
< td > files.is_ambiguous< / td >
< td > bool< / td >
< td > < / td >
< / tr >
< tr >
< td > files.is_submodule< / td >
< td > bool< / td >
< td > 是否为子模块< / td >
< / tr >
< tr >
< td > files.sections.file_name< / td >
< td > string< / td >
< td > 文件名称< / td >
< / tr >
< tr >
< td > files.sections.name< / td >
< td > string< / td >
< td > < / td >
< / tr >
< tr >
< td > files.sections.lines.left_index< / td >
< td > int< / td >
< td > 文件变动之前所在行数< / td >
< / tr >
< tr >
< td > files.sections.lines.right_index< / td >
< td > int< / td >
< td > 文件变动之后所在行数< / td >
< / tr >
< tr >
< td > files.sections.lines.match< / td >
< td > int< / td >
< td > < / td >
< / tr >
< tr >
< td > files.sections.lines.type< / td >
< td > int< / td >
< td > 文件变更类型< / td >
< / tr >
< tr >
< td > files.sections.lines.content< / td >
< td > string< / td >
< td > 文件变更内容< / td >
< / tr >
< tr >
< td > files.sections.lines.section_path< / td >
< td > string< / td >
< td > 文件路径< / td >
< / tr >
< tr >
< td > files.sections.lines.section_last_left_index< / td >
< td > int< / td >
< td > < / td >
< / tr >
< tr >
< td > files.sections.lines.section_last_right_index< / td >
< td > int< / td >
< td > < / td >
< / tr >
< tr >
< td > files.sections.lines.section_left_index< / td >
< td > int< / td >
< td > 文件变更之前所在行数< / td >
< / tr >
< tr >
< td > files.sections.lines.section_right_index< / td >
< td > int< / td >
< td > 文件变更之后所在行数(即:页面编辑器开始显示的行数)< / td >
< / tr >
< tr >
< td > files.sections.lines.section_left_hunk_size< / td >
< td > int< / td >
< td > 文件变更之前的行数< / td >
< / tr >
< tr >
< td > files.sections.lines.section_right_hunk_size< / td >
< td > int< / td >
< td > 文件变更之后的行数(及当前页面编辑器显示的总行数)< / td >
< / tr >
< tr >
< td > files.is_incomplete< / td >
< td > bool< / td >
< td > 是否不完整< / td >
< / tr >
< tr >
< td > files.is_incomplete_line_too_long< / td >
< td > bool< / td >
< td > 文件是否不完整是因为太长了< / td >
< / tr >
< tr >
< td > files.is_protected< / td >
< td > bool< / td >
< td > 文件是否被保护< / td >
< / tr >
< / tbody > < / table >
< blockquote >
< p > 列表返回的JSON示例:< / p >
< / blockquote >
< div class = "highlight" > < pre class = "highlight json tab-json" > < code > < span class = "p" > {< / span > < span class = "w" >
< / span > < span class = "nl" > "file_nums"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 29< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "total_addition"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 5< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "total_deletion"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 2< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "files"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "p" > [< / span > < span class = "w" >
< / span > < span class = "p" > {< / span > < span class = "w" >
< / span > < span class = "nl" > "name"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "s2" > "README.md"< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "oldname"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "s2" > "README.md"< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "addition"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 1< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "deletion"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 2< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "type"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 2< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "is_created"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "kc" > false< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "is_deleted"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "kc" > false< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "is_bin"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "kc" > false< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "is_lfs_file"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "kc" > false< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "is_renamed"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "kc" > false< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "is_ambiguous"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "kc" > false< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "is_submodule"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "kc" > false< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "sections"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "p" > [< / span > < span class = "w" >
< / span > < span class = "p" > {< / span > < span class = "w" >
< / span > < span class = "nl" > "file_name"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "s2" > "README.md"< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "name"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "s2" > ""< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "lines"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "p" > [< / span > < span class = "w" >
< / span > < span class = "p" > {< / span > < span class = "w" >
< / span > < span class = "nl" > "left_index"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 0< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "right_index"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 0< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "match"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 0< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "type"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 4< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "content"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "s2" > "@@ -1,2 +1 @@"< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "section_path"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "s2" > "README.md"< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "section_last_left_index"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 0< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "section_last_right_index"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 0< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "section_left_index"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 1< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "section_right_index"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 1< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "section_left_hunk_size"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 2< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "section_right_hunk_size"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 0< / span > < span class = "w" >
< / span > < span class = "p" > },< / span > < span class = "w" >
< / span > < span class = "p" > {< / span > < span class = "w" >
< / span > < span class = "nl" > "left_index"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 1< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "right_index"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 0< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "match"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 3< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "type"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 3< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "content"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "s2" > "-# ceshi_commit"< / span > < span class = "w" >
< / span > < span class = "p" > },< / span > < span class = "w" >
< / span > < span class = "p" > {< / span > < span class = "w" >
< / span > < span class = "nl" > "left_index"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 2< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "right_index"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 0< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "match"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > -1< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "type"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 3< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "content"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "s2" > "-"< / span > < span class = "w" >
< / span > < span class = "p" > },< / span > < span class = "w" >
< / span > < span class = "p" > {< / span > < span class = "w" >
< / span > < span class = "nl" > "left_index"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 0< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "right_index"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 1< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "match"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 1< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "type"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 2< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "content"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "s2" > "+adsa"< / span > < span class = "w" >
< / span > < span class = "p" > }< / span > < span class = "w" >
< / span > < span class = "p" > ]< / span > < span class = "w" >
< / span > < span class = "p" > },< / span > < span class = "w" >
< / span > < span class = "p" > {}< / span > < span class = "w" >
< / span > < span class = "p" > ],< / span > < span class = "w" >
< / span > < span class = "nl" > "is_incomplete"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "kc" > false< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "is_incomplete_line_too_long"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "kc" > false< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "is_protected"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "kc" > false< / span > < span class = "w" >
< / span > < span class = "p" > }< / span > < span class = "w" >
< / span > < span class = "p" > ]< / span > < span class = "w" >
< / span > < span class = "p" > }< / span > < span class = "w" >
< / span > < / code > < / pre > < / div > < h3 id = '7e3fc7ebbc' > 单个文件返回字段说明:< / h3 >
< table > < thead >
< tr >
< th > 参数< / th >
< th > 类型< / th >
< th > 字段说明< / th >
< / tr >
< / thead > < tbody >
< tr >
< td > name< / td >
< td > string< / td >
< td > 文件名称< / td >
< / tr >
< tr >
< td > oldname< / td >
< td > string< / td >
< td > 文件修改前名称< / td >
< / tr >
< tr >
< td > addition< / td >
< td > int< / td >
< td > 文件新增行数< / td >
< / tr >
< tr >
< td > deletion< / td >
< td > int< / td >
< td > 文件删除行数< / td >
< / tr >
< tr >
< td > type< / td >
< td > int< / td >
< td > 文件类型 1: 新增 2: 更改 3: 删除 4: 重命名 5: 复制< / td >
< / tr >
< tr >
< td > is_created< / td >
< td > bool< / td >
< td > 是否为新建文件< / td >
< / tr >
< tr >
< td > is_deleted< / td >
< td > bool< / td >
< td > 是否为删除文件< / td >
< / tr >
< tr >
< td > is_bin< / td >
< td > bool< / td >
< td > 是否为二进制文件< / td >
< / tr >
< tr >
< td > is_lfs_file< / td >
< td > bool< / td >
< td > 是否为LFS文件< / td >
< / tr >
< tr >
< td > is_renamed< / td >
< td > bool< / td >
< td > 是否重命名< / td >
< / tr >
< tr >
< td > is_ambiguous< / td >
< td > bool< / td >
< td > < / td >
< / tr >
< tr >
< td > is_submodule< / td >
< td > bool< / td >
< td > 是否为子模块< / td >
< / tr >
< tr >
< td > sections.file_name< / td >
< td > string< / td >
< td > 文件名称< / td >
< / tr >
< tr >
< td > sections.name< / td >
< td > string< / td >
< td > < / td >
< / tr >
< tr >
< td > sections.lines.left_index< / td >
< td > int< / td >
< td > 文件变动之前所在行数< / td >
< / tr >
< tr >
< td > sections.lines.right_index< / td >
< td > int< / td >
< td > 文件变动之后所在行数< / td >
< / tr >
< tr >
< td > sections.lines.match< / td >
< td > int< / td >
< td > < / td >
< / tr >
< tr >
< td > sections.lines.type< / td >
< td > int< / td >
< td > 文件变更类型< / td >
< / tr >
< tr >
< td > sections.lines.content< / td >
< td > string< / td >
< td > 文件变更内容< / td >
< / tr >
< tr >
< td > sections.lines.section_path< / td >
< td > string< / td >
< td > 文件路径< / td >
< / tr >
< tr >
< td > sections.lines.section_last_left_index< / td >
< td > int< / td >
< td > < / td >
< / tr >
< tr >
< td > sections.lines.section_last_right_index< / td >
< td > int< / td >
< td > < / td >
< / tr >
< tr >
< td > sections.lines.section_left_index< / td >
< td > int< / td >
< td > 文件变更之前所在行数< / td >
< / tr >
< tr >
< td > sections.lines.section_right_index< / td >
< td > int< / td >
< td > 文件变更之后所在行数(即:页面编辑器开始显示的行数)< / td >
< / tr >
< tr >
< td > sections.lines.section_left_hunk_size< / td >
< td > int< / td >
< td > 文件变更之前的行数< / td >
< / tr >
< tr >
< td > sections.lines.section_right_hunk_size< / td >
< td > int< / td >
< td > 文件变更之后的行数(及当前页面编辑器显示的总行数)< / td >
< / tr >
< tr >
< td > is_incomplete< / td >
< td > bool< / td >
< td > 是否不完整< / td >
< / tr >
< tr >
< td > is_incomplete_line_too_long< / td >
< td > bool< / td >
< td > 文件是否不完整是因为太长了< / td >
< / tr >
< tr >
< td > is_protected< / td >
< td > bool< / td >
< td > 文件是否被保护< / td >
< / tr >
< / tbody > < / table >
< blockquote >
< p > 单个文件返回的JSON示例:< / p >
< / blockquote >
< div class = "highlight" > < pre class = "highlight json tab-json" > < code > < span class = "p" > {< / span > < span class = "w" >
< / span > < span class = "nl" > "name"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "s2" > "README.md"< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "oldname"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "s2" > "README.md"< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "addition"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 1< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "deletion"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 2< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "type"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 2< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "is_created"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "kc" > false< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "is_deleted"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "kc" > false< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "is_bin"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "kc" > false< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "is_lfs_file"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "kc" > false< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "is_renamed"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "kc" > false< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "is_ambiguous"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "kc" > false< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "is_submodule"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "kc" > false< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "sections"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "p" > [< / span > < span class = "w" >
< / span > < span class = "p" > {< / span > < span class = "w" >
< / span > < span class = "nl" > "file_name"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "s2" > "README.md"< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "name"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "s2" > ""< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "lines"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "p" > [< / span > < span class = "w" >
< / span > < span class = "p" > {< / span > < span class = "w" >
< / span > < span class = "nl" > "left_index"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 0< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "right_index"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 0< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "match"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 0< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "type"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 4< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "content"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "s2" > "@@ -1,2 +1 @@"< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "section_path"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "s2" > "README.md"< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "section_last_left_index"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 0< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "section_last_right_index"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 0< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "section_left_index"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 1< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "section_right_index"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 1< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "section_left_hunk_size"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 2< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "section_right_hunk_size"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 0< / span > < span class = "w" >
< / span > < span class = "p" > },< / span > < span class = "w" >
< / span > < span class = "p" > {< / span > < span class = "w" >
< / span > < span class = "nl" > "left_index"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 1< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "right_index"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 0< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "match"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 3< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "type"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 3< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "content"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "s2" > "-# ceshi_commit"< / span > < span class = "w" >
< / span > < span class = "p" > },< / span > < span class = "w" >
< / span > < span class = "p" > {< / span > < span class = "w" >
< / span > < span class = "nl" > "left_index"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 2< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "right_index"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 0< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "match"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > -1< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "type"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 3< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "content"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "s2" > "-"< / span > < span class = "w" >
< / span > < span class = "p" > },< / span > < span class = "w" >
< / span > < span class = "p" > {< / span > < span class = "w" >
< / span > < span class = "nl" > "left_index"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 0< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "right_index"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 1< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "match"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 1< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "type"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 2< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "content"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "s2" > "+adsa"< / span > < span class = "w" >
< / span > < span class = "p" > }< / span > < span class = "w" >
< / span > < span class = "p" > ]< / span > < span class = "w" >
< / span > < span class = "p" > },< / span > < span class = "w" >
< / span > < span class = "p" > {< / span > < span class = "w" >
< / span > < span class = "nl" > "file_name"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "s2" > "README.md"< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "name"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "s2" > ""< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "lines"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "p" > [< / span > < span class = "w" >
< / span > < span class = "p" > {< / span > < span class = "w" >
< / span > < span class = "nl" > "left_index"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 0< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "right_index"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 0< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "match"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 0< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "type"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 4< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "content"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "s2" > " "< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "section_path"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "s2" > "README.md"< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "section_last_left_index"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 0< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "section_last_right_index"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 1< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "section_left_index"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 3< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "section_right_index"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 2< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "section_left_hunk_size"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 0< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "section_right_hunk_size"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "mi" > 0< / span > < span class = "w" >
< / span > < span class = "p" > }< / span > < span class = "w" >
< / span > < span class = "p" > ]< / span > < span class = "w" >
< / span > < span class = "p" > }< / span > < span class = "w" >
< / span > < span class = "p" > ],< / span > < span class = "w" >
< / span > < span class = "nl" > "is_incomplete"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "kc" > false< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "is_incomplete_line_too_long"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "kc" > false< / span > < span class = "p" > ,< / span > < span class = "w" >
< / span > < span class = "nl" > "is_protected"< / span > < span class = "p" > :< / span > < span class = "w" > < / span > < span class = "kc" > false< / span > < span class = "w" >
< / span > < span class = "p" > }< / span > < span class = "w" >
< / span > < / code > < / pre > < / div > < h1 id = 'issues' > Issues< / h1 > < h1 id = 'organizations' > Organizations< / h1 > < h1 id = 'teams' > Teams< / h1 > < h1 id = 'errors' > Errors< / h1 >
< aside class = "notice" >
This error section is stored in a separate file in < code > includes/_errors.md< / code > . Slate allows you to optionally separate out your docs into many files...just save them to the < code > includes< / code > folder and add them to the top of your < code > index.md< / code > 's frontmatter. Files are included in the order listed.