@@ -3,21 +3,21 @@ import { readFile, writeFile } from "fs/promises";
3
3
import { globby } from "globby" ;
4
4
import pProps from "p-props" ;
5
5
import { $ } from "../cli/echoBunShell" ;
6
- import { parseUrlRepoOwner , stringifyGithubOrigin } from "../parseOwnerRepo" ;
6
+ import { parseGithubRepoUrl , stringifyGithubOrigin } from "../parseOwnerRepo" ;
7
7
import { parseTitleBodyOfMarkdown } from "../parseTitleBodyOfMarkdown" ;
8
8
import { yaml } from "../utils/yaml" ;
9
9
import { forkCheckoutRepoOnBranch } from "./forkCheckoutRepoOnBranch" ;
10
10
import { gptWriter } from "./gptWriter" ;
11
11
import {
12
- referenceActionContent ,
13
- referenceActionContentHash ,
14
- referencePullRequestMessage ,
12
+ referenceActionContent ,
13
+ referenceActionContentHash ,
14
+ referencePullRequestMessage ,
15
15
} from "./updateGithubActionTask" ;
16
16
export const updateGithubActionPrepareBranchBanPatterns = [
17
17
/ i f : \$ { { g i t h u b .r e p o s i t o r y _ o w n e r = = ' N O D E _ A U T H O R _ O W N E R ' } } / ,
18
18
/ - m a s t e r / ,
19
19
/ s u b m o d u l e s : t r u e / ,
20
- / \+ p e r s o n a l _ a c c e s s _ t o k e n : \$ { { s e c r e t s .R E G I S T R Y _ A C C E S S _ T O K E N } } /
20
+ / \+ p e r s o n a l _ a c c e s s _ t o k e n : \$ { { s e c r e t s .R E G I S T R Y _ A C C E S S _ T O K E N } } / ,
21
21
] ;
22
22
export async function updateGithubActionPrepareBranch ( repo : string ) {
23
23
console . log ( `$ updateGithubActionPrepareBranch("${ repo } ")` ) ;
@@ -48,7 +48,7 @@ export async function updateGithubActionPrepareBranch(repo: string) {
48
48
{ role : "developer" , content : "$ read Pull Request message template" } ,
49
49
{ role : "function" , name : "read" , content : referencePullRequestMessage } ,
50
50
{ role : "developer" , content : "$ read NODE_AUTHOR_OWNER" } ,
51
- { role : "function" , name : "read" , content : parseUrlRepoOwner ( repo ) . owner } ,
51
+ { role : "function" , name : "read" , content : parseGithubRepoUrl ( repo ) . owner } ,
52
52
{
53
53
role : "user" ,
54
54
content :
@@ -117,7 +117,7 @@ export async function updateGithubActionPrepareBranch(repo: string) {
117
117
} ,
118
118
] ) ,
119
119
} ) ;
120
- const origin = await stringifyGithubOrigin ( parseUrlRepoOwner ( html_url ) ) ;
120
+ const origin = await stringifyGithubOrigin ( parseGithubRepoUrl ( html_url ) ) ;
121
121
await $ `cd ${ cwd } && git add . && git commit -am ${ commitMessage } && git push -f ${ origin } ${ branch } ` ;
122
122
// ensure pr message is parsable
123
123
const { title, body } = parseTitleBodyOfMarkdown ( pullRequestMessage ) ;
0 commit comments