MCPcopy
hub / github.com/peter-evans/create-pull-request / configureToken

Method configureToken

src/git-config-helper.ts:144–153  ·  view source on GitHub ↗
(token: string)

Source from the content-addressed store, hash-verified

142 }
143
144 async configureToken(token: string): Promise<void> {
145 // Encode and configure the basic credential for HTTPS access
146 const basicCredential = Buffer.from(
147 `x-access-token:${token}`,
148 'utf8'
149 ).toString('base64')
150 core.setSecret(basicCredential)
151 const extraheaderConfigValue = `AUTHORIZATION: basic ${basicCredential}`
152 await this.setExtraheaderConfig(extraheaderConfigValue)
153 }
154
155 async removeAuth(): Promise<void> {
156 await this.getAndUnset()

Callers 2

createPullRequestFunction · 0.80

Calls 1

setExtraheaderConfigMethod · 0.95

Tested by

no test coverage detected