• If you are still using CentOS 7.9, it's time to convert to Alma 8 with the free centos2alma tool by Plesk or Plesk Migrator. Please let us know your experiences or concerns in this thread:
    CentOS2Alma discussion

Issue Git Extension - How to delete old branches?

TurnRound

New Pleskian
I'm successfully using the Plesk Git Extension to pull updates from Github to my development and production sites.

However, branches I've deleted from my local dev environment and Github are not deleted from the Branch menu in the extension (under Change branch and path).

Every branch I've ever created is still listed there, despite having been deleted from Github.

How do I remove these? Clicking the Pull Updates button doesn't do it.

Thanks.
 
I have the same question.
I have a lot of already deleted branches appearing in the branch select dropdown.
I saw that all of the branches are in yourDomain.com/git/yourRepository.git/refs/heads/
I read here that it is "save" (note the quotes!) to simply delete those (https://stackoverflow.com/a/42258262/3038364) but I haven't tried it jet.

Would be cool if somebody from Plesk (or the git extension) could give some insides...

Best,
Felix
 
You may submit a detailed report here Reports and I will forward it to Plesk developers.
 
Hi,

Plesk Git extension creates the repository in the {WEBSPACEROOT}/git/{reponame.git}. The branches you see in the dropdown are in that repository. From {WEBSPACEROOT} (system user home) you can interact with it like this
Bash:
git --git-dir=git/{name}.git/ --work-tree={deployPath}/ branch -a
  dev
* master
You can delete the dev branch using:
Code:
git --git-dir=git/{name}.git/ --work-tree={deployPath}/ branch -d dev
Deleted branch dev (was edae48f).

P.S. It will remove the branch but it won't reduce the repository size.

Regards,
Raul
 
Back
Top