|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objecthudson.plugins.mercurial.HgExe
public class HgExe
Encapsulates the invocation of "hg".
This reduces the amount of code in the main logic. TODO: perhaps a subtype 'Repository' with a repository location field would be good.
| Nested Class Summary | |
|---|---|
private static class |
HgExe.Capability
Capability of a particular hg invocation configuration (and location) on a specific node. |
| Field Summary | |
|---|---|
private ArgumentListBuilder |
base
|
private HgExe.Capability |
capability
|
private EnvVars |
env
Environment variables to invoke hg with. |
Launcher |
launcher
|
TaskListener |
listener
|
Node |
node
|
private static Pattern |
REVISIONID_PATTERN
Pattern that matches revision ID. |
| Constructor Summary | |
|---|---|
HgExe(MercurialSCM scm,
Launcher launcher,
AbstractBuild build,
TaskListener listener,
EnvVars env)
|
|
HgExe(MercurialSCM scm,
Launcher launcher,
Node node,
TaskListener listener,
EnvVars env)
|
|
| Method Summary | |
|---|---|
Launcher.ProcStarter |
bundle(Collection<String> bases,
String file)
|
Launcher.ProcStarter |
bundleAll(String file)
|
Launcher.ProcStarter |
cleanAll()
|
Launcher.ProcStarter |
clone(String... args)
|
Set<String> |
heads(FilePath repo,
boolean useTimeout)
Obtains the heads of the repository. |
private Set<String> |
heads(FilePath repo,
boolean useTimeout,
boolean usingHg15Syntax)
|
Launcher.ProcStarter |
init(FilePath path)
|
private Launcher.ProcStarter |
l(ArgumentListBuilder args)
|
String |
popen(FilePath repository,
TaskListener listener,
boolean useTimeout,
ArgumentListBuilder args)
Runs the command and captures the output. |
Launcher.ProcStarter |
pull()
|
Launcher.ProcStarter |
run(ArgumentListBuilder args)
|
Launcher.ProcStarter |
run(String... args)
Runs arbitrary command. |
private ArgumentListBuilder |
seed()
|
String |
tip(FilePath repository)
Gets the revision ID of the tip of the workspace. |
List<String> |
toArgList()
|
Launcher.ProcStarter |
unbundle(String bundleFile)
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
private final ArgumentListBuilder base
private final EnvVars env
public final Launcher launcher
public final Node node
public final TaskListener listener
private final HgExe.Capability capability
private static final Pattern REVISIONID_PATTERN
| Constructor Detail |
|---|
public HgExe(MercurialSCM scm,
Launcher launcher,
AbstractBuild build,
TaskListener listener,
EnvVars env)
throws IOException,
InterruptedException
IOException
InterruptedException
public HgExe(MercurialSCM scm,
Launcher launcher,
Node node,
TaskListener listener,
EnvVars env)
throws IOException,
InterruptedException
IOException
InterruptedException| Method Detail |
|---|
private Launcher.ProcStarter l(ArgumentListBuilder args)
private ArgumentListBuilder seed()
public Launcher.ProcStarter pull()
public Launcher.ProcStarter clone(String... args)
public Launcher.ProcStarter bundleAll(String file)
public Launcher.ProcStarter bundle(Collection<String> bases,
String file)
public Launcher.ProcStarter init(FilePath path)
public Launcher.ProcStarter unbundle(String bundleFile)
public Launcher.ProcStarter cleanAll()
public Launcher.ProcStarter run(String... args)
public Launcher.ProcStarter run(ArgumentListBuilder args)
public Set<String> heads(FilePath repo,
boolean useTimeout)
throws IOException,
InterruptedException
IOException
InterruptedException
private Set<String> heads(FilePath repo,
boolean useTimeout,
boolean usingHg15Syntax)
throws IOException,
InterruptedException
IOException
InterruptedException
public String tip(FilePath repository)
throws IOException,
InterruptedException
IOException
InterruptedExceptionpublic List<String> toArgList()
public String popen(FilePath repository,
TaskListener listener,
boolean useTimeout,
ArgumentListBuilder args)
throws IOException,
InterruptedException
IOException
InterruptedException
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||