Skip to content

Commit

Permalink
feat: update mkrepo workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
myml committed Aug 8, 2024
1 parent d4a3de0 commit 3d7b40b
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions tools/mkrepo/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ import (
"net/http"
"os"
"strconv"
"time"

"github.com/bradleyfalzon/ghinstallation/v2"
"github.com/google/go-github/github"
Expand Down Expand Up @@ -159,6 +160,8 @@ func createRepo(client *github.Client, github_org, github_repo, webhook_url, web
if err != nil {
return fmt.Errorf("create readme: %w", err)
}
// wait create file finish
time.Sleep(time.Second)
_, _, err = client.Repositories.CreateHook(ctx, github_org, github_repo, &github.Hook{
Name: github.String("web"),
Config: map[string]interface{}{"url": webhook_url, "content_type": "json", "secret": webhook_secret},
Expand Down

0 comments on commit 3d7b40b

Please sign in to comment.