File tree Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Expand file tree Collapse file tree 1 file changed +8
-1
lines changed Original file line number Diff line number Diff line change @@ -131,13 +131,17 @@ function safeExec(cmd: string, opts = {}) {
131
131
132
132
// ---- CREATE RELEASE BRANCH + PR ----
133
133
process . env . GITHUB_TOKEN = process . env . RELEASE_GITHUB_TOKEN
134
- // Remove ALL credential helpers to ensure only our token is used
134
+
135
+ // REMOVE ALL credential helpers and .extraheader IMMEDIATELY BEFORE PUSH
135
136
try {
136
137
safeExec ( 'git config --global --unset credential.helper || true' )
137
138
} catch { }
138
139
try {
139
140
safeExec ( 'git config --local --unset credential.helper || true' )
140
141
} catch { }
142
+ try {
143
+ safeExec ( 'git config --local --unset http.https://github.com/.extraheader || true' )
144
+ } catch { }
141
145
142
146
// Ensure remote is set again before push
143
147
if ( process . env . RELEASE_GITHUB_TOKEN ) {
@@ -172,6 +176,9 @@ function safeExec(cmd: string, opts = {}) {
172
176
console . log ( 'No changes to commit' )
173
177
}
174
178
179
+ // DEBUG: Show credential config and remote before push
180
+ safeExec ( 'git config --local --get http.https://github.com/.extraheader || true' )
181
+
175
182
safeExec ( `git push origin ${ branchName } ` )
176
183
177
184
// Open PR using GitHub CLI
You can’t perform that action at this time.
0 commit comments