Push command. It has setters for all
supported options and arguments of this command and a call() method
to finally execute the command.
| Modifier and Type | Field and Description |
|---|---|
| private boolean | |
| private boolean | |
| private boolean | |
| private PrintStream | |
| private PrintStream | |
| private ProgressMonitor | |
| private OutputStream | |
| private PushConfig. | |
| private List | |
| private String | |
| private final Map | |
| private final List | |
| private String | |
| private boolean | |
| private boolean |
| Access | Constructor and Description |
|---|---|
| protected |
| Modifier and Type | Method and Description |
|---|---|
| public PushCommand | |
| public PushCommand | |
| public Iterable | call()
Implements abstract org. Implements java. Computes a result, or throws an exception if unable to do so. |
| private void | |
| private String | |
| private String | |
| public ProgressMonitor | |
| public PushConfig. | |
| public List | |
| public String | Returns: the receive-pack used for the remote operationGet the name of the remote executable providing the receive-pack service |
| public List | |
| public List | |
| public String | |
| public int | |
| public boolean | Returns: true if all-or-nothing behavior is requested.Whether this push should be executed atomically (all references updated, or none) |
| public boolean | Returns: the dry run preference for the push operationWhether to run the push operation as a dry run |
| public boolean | |
| public boolean | |
| public boolean | |
| public PushCommand | Returns: thiswhether to run the push atomically atomic)Requests atomic push (all references updated, or no updates). |
| public PushCommand | |
| public PushCommand | Returns: thiswhether to push forcefully force)Sets the force preference for push operation. |
| public PushCommand | Returns: thisSets a |
| public PushCommand | Returns: thisSets a |
| public PushCommand | |
| public PushCommand | Returns: thisThe progress monitor associated with the push operation. |
| public PushCommand | |
| public PushCommand | Returns: thisPushDefault to set; if null the value defined
in the git config will be used.Sets an explicit |
| public PushCommand | Returns: thisa pushOptions)java. of push option stringsSet the option strings associated with the push operation. |
| public PushCommand | |
| public PushCommand | Returns: thisname of the remote executable providing the receive-pack
service receivePack)The remote executable providing receive-pack service for pack transports. |
| public PushCommand | Returns: thisa specs)org. object.The ref lease specs to be used in the push operation, for a force-with-lease push operation. |
| public PushCommand | Returns: thislist of specs)RefLeaseSpecsThe ref lease specs to be used in the push operation, for a force-with-lease push operation. |
| public PushCommand | Returns: thisa specs)org. object.The ref specs to be used in the push operation |
| public PushCommand | Returns: thislist of specs)org.sThe ref specs to be used in the push operation |
| public PushCommand | |
| public PushCommand | Returns: thisthe thin-pack preference value thinPack)Set the thin-pack preference for push operation. |
| public PushCommand | Returns: thisfalse to disable use of bitmaps for push, true otherwise. useBitmaps)Set whether to use bitmaps for push. |
| atomic | back to summary |
|---|---|
| private boolean atomic | |
| dryRun | back to summary |
|---|---|
| private boolean dryRun | |
| force | back to summary |
|---|---|
| private boolean force | |
| hookErrRedirect | back to summary |
|---|---|
| private PrintStream hookErrRedirect | |
| hookOutRedirect | back to summary |
|---|---|
| private PrintStream hookOutRedirect | |
| monitor | back to summary |
|---|---|
| private ProgressMonitor monitor | |
| out | back to summary |
|---|---|
| private OutputStream out | |
| pushDefault | back to summary |
|---|---|
| private PushConfig. | |
| pushOptions | back to summary |
|---|---|
| private List<String> pushOptions | |
| receivePack | back to summary |
|---|---|
| private String receivePack | |
| refLeaseSpecs | back to summary |
|---|---|
| private final Map<String, RefLeaseSpec> refLeaseSpecs | |
| refSpecs | back to summary |
|---|---|
| private final List<RefSpec> refSpecs | |
| remote | back to summary |
|---|---|
| private String remote | |
| thin | back to summary |
|---|---|
| private boolean thin | |
| useBitmaps | back to summary |
|---|---|
| private boolean useBitmaps | |
| PushCommand | back to summary |
|---|---|
| protected PushCommand(Repository repo) Constructor for PushCommand.
| |
| add | back to summary |
|---|---|
| public PushCommand add(Ref ref) Add a reference to push.
| |
| add | back to summary |
|---|---|
| public PushCommand add(String nameOrSpec) Add a reference to push.
| |
| call | back to summary |
|---|---|
| public Iterable Implements abstract org. Implements java. Doc from org. Computes a result, or throws an exception if unable to do so. Execute the command
Execute the
| |
| determineDefaultRefSpecs | back to summary |
|---|---|
| private void determineDefaultRefSpecs(Config config) throws IOException, GitAPIException | |
| determineRemote | back to summary |
|---|---|
| private String determineRemote(Config config, String remoteName) throws IOException | |
| getCurrentBranch | back to summary |
|---|---|
| private String getCurrentBranch() throws IOException, DetachedHeadException | |
| getProgressMonitor | back to summary |
|---|---|
| public ProgressMonitor getProgressMonitor() Get the progress monitor
| |
| getPushDefault | back to summary |
|---|---|
| public PushConfig. Retrieves the
| |
| getPushOptions | back to summary |
|---|---|
| public List Get push options | |
| getReceivePack | back to summary |
|---|---|
| public String getReceivePack() Get the name of the remote executable providing the receive-pack service
| |
| getRefLeaseSpecs | back to summary |
|---|---|
| public List Get the
| |
| getRefSpecs | back to summary |
|---|---|
| public List Get | |
| getRemote | back to summary |
|---|---|
| public String getRemote() Get remote name
| |
| getTimeout | back to summary |
|---|---|
| public int getTimeout() Get timeout used for push operation
| |
| isAtomic | back to summary |
|---|---|
| public boolean isAtomic() Whether this push should be executed atomically (all references updated, or none)
| |
| isDryRun | back to summary |
|---|---|
| public boolean isDryRun() Whether to run the push operation as a dry run
| |
| isForce | back to summary |
|---|---|
| public boolean isForce() Whether to push forcefully
| |
| isThin | back to summary |
|---|---|
| public boolean isThin() Get the thin-pack preference
| |
| isUseBitmaps | back to summary |
|---|---|
| public boolean isUseBitmaps() Whether to use bitmaps for push.
| |
| setAtomic | back to summary |
|---|---|
| public PushCommand setAtomic(boolean atomic) Requests atomic push (all references updated, or no updates). Default setting is false.
| |
| setDryRun | back to summary |
|---|---|
| public PushCommand setDryRun(boolean dryRun) Sets whether the push operation should be a dry run
| |
| setForce | back to summary |
|---|---|
| public PushCommand setForce(boolean force) Sets the force preference for push operation.
| |
| setHookErrorStream | back to summary |
|---|---|
| public PushCommand setHookErrorStream(PrintStream redirect) Sets a When pushing to several remote repositories the stream is shared for all pushes.
| |
| setHookOutputStream | back to summary |
|---|---|
| public PushCommand setHookOutputStream(PrintStream redirect) Sets a When pushing to several remote repositories the stream is shared for all pushes.
| |
| setOutputStream | back to summary |
|---|---|
| public PushCommand setOutputStream(OutputStream out) Sets the output stream to write sideband messages to
| |
| setProgressMonitor | back to summary |
|---|---|
| public PushCommand setProgressMonitor(ProgressMonitor monitor) The progress monitor associated with the push operation. By default, this
is set to
| |
| setPushAll | back to summary |
|---|---|
| public PushCommand setPushAll() Push all branches under refs/heads/*.
| |
| setPushDefault | back to summary |
|---|---|
| public PushCommand setPushDefault(PushConfig. Sets an explicit
| |
| setPushOptions | back to summary |
|---|---|
| public PushCommand setPushOptions(List<String> pushOptions) Set the option strings associated with the push operation.
| |
| setPushTags | back to summary |
|---|---|
| public PushCommand setPushTags() Push all tags under refs/tags/*.
| |
| setReceivePack | back to summary |
|---|---|
| public PushCommand setReceivePack(String receivePack) The remote executable providing receive-pack service for pack transports.
If no receive-pack is set, the default value of
| |
| setRefLeaseSpecs | back to summary |
|---|---|
| public PushCommand setRefLeaseSpecs(RefLeaseSpec... specs) The ref lease specs to be used in the push operation, for a force-with-lease push operation.
| |
| setRefLeaseSpecs | back to summary |
|---|---|
| public PushCommand setRefLeaseSpecs(List<RefLeaseSpec> specs) The ref lease specs to be used in the push operation, for a force-with-lease push operation.
| |
| setRefSpecs | back to summary |
|---|---|
| public PushCommand setRefSpecs(RefSpec... specs) The ref specs to be used in the push operation
| |
| setRefSpecs | back to summary |
|---|---|
| public PushCommand setRefSpecs(List<RefSpec> specs) The ref specs to be used in the push operation
| |
| setRemote | back to summary |
|---|---|
| public PushCommand setRemote(String remote) The remote (uri or name) used for the push operation. If no remote is
set, the default value of
| |
| setThin | back to summary |
|---|---|
| public PushCommand setThin(boolean thinPack) Set the thin-pack preference for push operation. Default setting is Transport.DEFAULT_PUSH_THIN
| |
| setUseBitmaps | back to summary |
|---|---|
| public PushCommand setUseBitmaps(boolean useBitmaps) Set whether to use bitmaps for push. Default setting is true
| |