File tree Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -8,12 +8,12 @@ function resolveCurrentBranch(ref: string): string {
8
8
return github . context . payload . pull_request ?. head ?. ref ?? ''
9
9
} else if ( ref . startsWith ( 'refs/tags/' ) ) {
10
10
// Get the repository default branch
11
- const octokit = github . getOctokit ( github . context . token )
12
- const { data : default_branch } = octokit . rest . repos . get ( {
13
- owner : ( github . context . repo as string ) . split ( '/' ) [ 0 ] ,
14
- repo : ( github . context . repo as string ) . split ( '/' ) [ 1 ] ,
15
- } ) ;
16
- return default_branch ;
11
+ // const octokit = github.getOctokit(github.context.token)
12
+ // const { data: default_branch } = octokit.rest.repos.get({
13
+ // owner: (github.context.repo as string).split('/')[0],
14
+ // repo: (github.context.repo as string).split('/')[1],
15
+ // });
16
+ return github . context . payload . repo . default_branch ;
17
17
}
18
18
19
19
throw new Error ( `Unsupported ref: ${ ref } ` )
You can’t perform that action at this time.
0 commit comments