Skip to content

Commit fb941f4

Browse files
fix: auto-fix test failures from Test all (Linux) (#67)
Co-authored-by: kevinwang5658 <20214115+kevinwang5658@users.noreply.github.com>
1 parent 0bcb38c commit fb941f4

1 file changed

Lines changed: 2 additions & 0 deletions

File tree

src/resources/github-cli/github-cli-alias.ts

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -112,6 +112,8 @@ export class GithubCliAliasResource extends Resource<GithubCliAliasConfig> {
112112

113113
async destroy(plan: DestroyPlan<GithubCliAliasConfig>): Promise<void> {
114114
const $ = getPty();
115+
const { status } = await $.spawnSafe('which gh');
116+
if (status === SpawnStatus.ERROR) return;
115117
await $.spawn(`gh alias delete ${plan.currentConfig.alias}`);
116118
}
117119

0 commit comments

Comments
 (0)