Skip to content

Commit b38f6d1

Browse files
committed
fix: better handling of separate tokens
1 parent 2bf55b2 commit b38f6d1

File tree

2 files changed

+3
-2
lines changed

2 files changed

+3
-2
lines changed

.github/workflows/sync-files.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,4 +11,5 @@ jobs:
1111
- uses: actions/setup-go@v4
1212
- run: go run main.go
1313
env:
14-
GH_TOKEN: ${{ secrets.SEAUBOT_ECSACT_DEV_GH_TOKEN }}
14+
GIT_CLONE_GH_TOKEN: ${{ secrets.SEAUBOT_ECSACT_DEV_GH_TOKEN }}
15+
GH_TOKEN: ${{ secrets.GITHUB_TOKEN }}

main.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -244,7 +244,7 @@ func main() {
244244
repo_clone_dir := fmt.Sprintf("./clones/%s", repo_name)
245245

246246
var clone_url string
247-
gh_token := os.Getenv("GH_TOKEN")
247+
gh_token := os.Getenv("GIT_CLONE_GH_TOKEN")
248248
if gh_token != "" {
249249
clone_url = fmt.Sprintf("https://%s:%s@github.com/ecsact-dev/%s.git", c.AuthorLogin, gh_token, repo_name)
250250
} else {

0 commit comments

Comments
 (0)