Don't prompt to publish branch after it was pushed (#188166)

This commit is contained in:
Joyce Er 2023-07-18 08:22:35 -07:00 committed by GitHub
parent 93846caad2
commit 1d96980398
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -191,6 +191,8 @@ export function getVscodeDevHost(): string {
}
export async function ensurePublished(repository: Repository, file: vscode.Uri) {
await repository.status();
if ((repository.state.HEAD?.type === RefType.Head || repository.state.HEAD?.type === RefType.Tag)
// If HEAD is not published, make sure it is
&& !repository?.state.HEAD?.upstream