Skip to main content

Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » EGit / JGit » Unable to delete remote branch
Unable to delete remote branch [message #1736241] Mon, 27 June 2016 19:17
Eric Walker is currently offline Eric WalkerFriend
Messages: 1
Registered: June 2016
Junior Member
I'm trying to use jgit to essentially do:

# git branch -d <branchToDelete>
# git push origin :<branchToDelete>

From what I've read on stack overflow, it seems like this was supported at one point, but

// Delete the local branch
// Push the changes to the remote
RefSpec refSpec = new RefSpec(":refs/heads/<branchToDelete>");
PushCommand push = git.push().setRefSpecs(refSpec).setRemote("origin").call();

is only deleting the branch locally, and the pushResult message is just "". Thoughts on why this isn't working?
Previous Topic:Unable to pull - Attempted to beginRule: R/, does not match outer scope rule: MultiRule
Next Topic:New Project Wizard fails on git clone
Goto Forum:

Current Time: Wed Feb 19 22:02:24 GMT 2020

Powered by FUDForum. Page generated in 0.07453 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top