本文整理了Java中org.eclipse.jgit.api.Git.remoteRemove()
方法的一些代码示例,展示了Git.remoteRemove()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Git.remoteRemove()
方法的具体详情如下:
包路径:org.eclipse.jgit.api.Git
类名称:Git
方法名:remoteRemove
[英]Return a command used to remove an existing remote.
[中]返回用于删除现有远程服务器的命令。
代码示例来源:origin: jphp-group/jphp
@Signature
public Memory remoteRemove(String name) throws URISyntaxException, GitAPIException {
RemoteRemoveCommand command = getWrappedObject().remoteRemove();
command.setName(name);
return GitUtils.valueOf(command.call());
}
代码示例来源:origin: org.openmrs.maven.plugins/openmrs-sdk-maven-plugin
private void removeRemote(Git git, String name) {
RemoteRemoveCommand remoteRemove = git.remoteRemove();
remoteRemove.setName(name);
try {
remoteRemove.call();
} catch (GitAPIException e) {
throw new IllegalStateException(e);
}
}
代码示例来源:origin: org.openmrs.maven.plugins/openmrs-sdk-maven-plugin
/**
* Deletes upstream remote repo
*/
private void deleteUpstreamRepo(Git git) throws Exception {
RemoteRemoveCommand remoteRemoveCommand = git.remoteRemove();
remoteRemoveCommand.setName(UPSTREAM);
try {
remoteRemoveCommand.call();
} catch (GitAPIException e) {
throw new Exception(DELETING_REMOTE_UPSTREAM_REASON, e);
}
}
代码示例来源:origin: kiegroup/appformer
private void removeOriginRemote(Repository repository) throws GitAPIException {
final org.eclipse.jgit.api.Git git = org.eclipse.jgit.api.Git.wrap(repository);
final RemoteRemoveCommand cmd = git.remoteRemove();
cmd.setName(origin);
cmd.call();
}
内容来源于网络,如有侵权,请联系作者删除!