Skip to content

Commit

Permalink
fix: format suites correctly
Browse files Browse the repository at this point in the history
  • Loading branch information
ericwenn committed Feb 11, 2022
1 parent 61d7a8a commit 02c665a
Show file tree
Hide file tree
Showing 2 changed files with 70 additions and 60 deletions.
7 changes: 4 additions & 3 deletions .sage/sagefile.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,8 @@ func main() {
}

func All(ctx context.Context) error {
sg.Deps(ctx, ConvcoCheck, FormatMarkdown, FormatYAML, Proto.All, ReadmeSnippet)
sg.Deps(ctx, ConvcoCheck, FormatYAML, Proto.All)
sg.SerialDeps(ctx, ReadmeSnippet, FormatMarkdown)
sg.Deps(ctx, GolangciLint, GoReview, GoTest)
sg.SerialDeps(ctx, GoModTidy, GitVerifyNoDiff)
return nil
Expand Down Expand Up @@ -81,8 +82,8 @@ func GitVerifyNoDiff(ctx context.Context) error {
func ReadmeSnippet(ctx context.Context) error {
suites := sg.Output(sg.Command(ctx, "go", "run", "./cmd/doc"))
suites = strings.TrimSpace(suites)
suites = "<!-- BEGIN suites -->\n\n```\n" + suites
suites += "\n```\n\n<!-- END suites -->"
suites = "<!-- BEGIN suites -->\n\n" + suites
suites += "\n\n<!-- END suites -->"
readme, err := os.ReadFile("README.md")
if err != nil {
return err
Expand Down
Loading

0 comments on commit 02c665a

Please sign in to comment.