From 3b99e6a41cbbe9663902cc2fb74cfa35d5d99387 Mon Sep 17 00:00:00 2001 From: XBPk3T Date: Tue, 10 Dec 2024 18:58:52 +0800 Subject: [PATCH] fix: add admonition for sub repos --- Taskfile.yml | 4 +--- yaml2md/cmd/gh.go | 2 +- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/Taskfile.yml b/Taskfile.yml index ec0e815..2237075 100644 --- a/Taskfile.yml +++ b/Taskfile.yml @@ -27,9 +27,7 @@ tasks: - fieldalignment -fix ./... - go test `go list ./... | grep -v examples` -coverprofile=coverage.out -covermode=atomic - task: pre-commit - - # - go vet -vettool=$(which shadow) -strict # 这个回去扫描官方pkg的版本,报错类似 shadow: package requires newer Go version go1.23,所以移除 - - nilaway ./... # - # go build -race cmd # - # hadolint --config Dockerfile +# - go vet -vettool=$(which shadow) -strict # 这个回去扫描官方pkg的版本,报错类似 shadow: package requires newer Go version go1.23,所以移除 diff --git a/yaml2md/cmd/gh.go b/yaml2md/cmd/gh.go index 291781c..857321d 100644 --- a/yaml2md/cmd/gh.go +++ b/yaml2md/cmd/gh.go @@ -190,7 +190,7 @@ func RenderRepos(repos gh.Repos) (res strings.Builder) { // 渲染该repo的sub repos if len(repo.Sub) != 0 { flag = true - res.WriteString(RenderRepositoriesAsMarkdownTable(repo.Sub)) + res.WriteString(utils.RenderMarkdownAdmonitions(utils.AdmonitionTip, "Sub Repos", RenderRepositoriesAsMarkdownTable(repo.Sub))) } // 渲染该repo的rep repos if len(repo.Rep) != 0 {