4

I want to delete the remote branch in Visual Studio Code but it seems like it's not supported.

GitLens supports Delete Branch (via Terminal) but I want to do it from the Command Palette.

I tried finding the extension but couldn't find one.

Can anyone suggest how can I delete remote branches via the command palette in Visual Studio Code?

Gino Mempin
  • 25,369
  • 29
  • 96
  • 135
Thu San
  • 1,400
  • 1
  • 17
  • 29

1 Answers1

1

but I want to do it from Command Palette.
Tried finding the extension but couldn't find one.

Currently, as shown in vscode-gitlens issue 385, this is done only though terminal:

  • Go to Source Control view (Ctrl + Shift + G) and expand the GITLENS section in the sidebar
  • Find branch to delete under Remotes (e.g. geolocation)
  • Right click on branch and choose Delete Branch (via Terminal)

Text entered into terminal reads: git push origin :aRemoteBranch

That remains (Q1 2019) the official way to delete a remote branch.

VonC
  • 1,262,500
  • 529
  • 4,410
  • 5,250