final String featureName= GitflowConfigUtil.getFeatureNameFromBranch(myProject, currentBranchName);
new Task.Backgroundable(myProject,"Publishing feature "+featureName,false){
@Override
public void run(@NotNull ProgressIndicator indicator) {
GitCommandResult result = myGitflow.publishFeature(repo,featureName,new GitflowErrorsListener(myProject));
if (result.success()) {
String publishedFeatureMessage = String.format("A new remote branch '%s%s' was created", featurePrefix, featureName);
NotifyUtil.notifySuccess(myProject, featureName, publishedFeatureMessage);
}
else {
NotifyUtil.notifyError(myProject, "Error", "Please have a look at the Version Control console for more details");