(type: string, name: string, sha: string, opts: { force?: boolean } = {})
| 1249 | } |
| 1250 | |
| 1251 | async patchRef(type: string, name: string, sha: string, opts: { force?: boolean } = {}) { |
| 1252 | const force = opts.force || false; |
| 1253 | const result: Endpoints['PATCH /repos/{owner}/{repo}/git/refs/{ref}']['response']['data'] = |
| 1254 | await this.request(`${this.repoURL}/git/refs/${type}/${encodeURIComponent(name)}`, { |
| 1255 | method: 'PATCH', |
| 1256 | body: JSON.stringify({ sha, force }), |
| 1257 | }); |
| 1258 | return result; |
| 1259 | } |
| 1260 | |
| 1261 | deleteRef(type: string, name: string) { |
| 1262 | return this.request(`${this.repoURL}/git/refs/${type}/${encodeURIComponent(name)}`, { |
no test coverage detected