diff options
Diffstat (limited to 'org.eclipse.jgit/src/org/eclipse/jgit/api/PushCommand.java')
-rw-r--r-- | org.eclipse.jgit/src/org/eclipse/jgit/api/PushCommand.java | 24 |
1 files changed, 23 insertions, 1 deletions
diff --git a/org.eclipse.jgit/src/org/eclipse/jgit/api/PushCommand.java b/org.eclipse.jgit/src/org/eclipse/jgit/api/PushCommand.java index 0a49f78069..bd4521b517 100644 --- a/org.eclipse.jgit/src/org/eclipse/jgit/api/PushCommand.java +++ b/org.eclipse.jgit/src/org/eclipse/jgit/api/PushCommand.java @@ -96,6 +96,8 @@ public class PushCommand extends private OutputStream out; + private List<String> pushOptions; + /** * @param repo */ @@ -149,6 +151,7 @@ public class PushCommand extends if (receivePack != null) transport.setOptionReceivePack(receivePack); transport.setDryRun(dryRun); + transport.setPushOptions(pushOptions); configure(transport); final Collection<RemoteRefUpdate> toPush = transport @@ -189,7 +192,6 @@ public class PushCommand extends } return pushResults; - } /** @@ -453,4 +455,24 @@ public class PushCommand extends this.out = out; return this; } + + /** + * @return the option strings associated with the push operation + * @since 4.5 + */ + public List<String> getPushOptions() { + return pushOptions; + } + + /** + * Sets the option strings associated with the push operation. + * + * @param pushOptions + * @return {@code this} + * @since 4.5 + */ + public PushCommand setPushOptions(List<String> pushOptions) { + this.pushOptions = pushOptions; + return this; + } } |