Documentation
¶
Index ¶
- Variables
- type Branch
- type Branches
- type Client
- func (client Client) CreateJob(jobName, jobConfigXML string) error
- func (client Client) DeleteJob(jobName string) error
- func (client Client) GetJobConfig(jobName string) (JobConfig, error)
- func (client Client) GetJobSummaries() ([]JobSummary, error)
- func (client Client) GetJobSummariesFromFilesystem(root string) ([]JobSummary, error)
- func (client Client) GetJobs() (map[string]JobDescriptor, error)
- func (client Client) GetLastBuild(jobName string) (LastBuild, error)
- type FreeStyleJobConfig
- type Jenkins
- type JobConfig
- type JobDescriptor
- type JobSummary
- type JobType
- type Jobs
- type LastBuild
- type Publishers
- type RedeployPublisher
- type RootModule
- type Scm
- type UserRemoteConfig
- type UserRemoteConfigs
Constants ¶
This section is empty.
Variables ¶
Functions ¶
This section is empty.
Types ¶
type Client ¶
type Client struct {
Jenkins
// contains filtered or unexported fields
}
func (Client) CreateJob ¶
CreateJob creates a Jenkins job with the given name for the given XML job config.
func (Client) DeleteJob ¶
DeleteJob creates a Jenkins job with the given name for the given XML job config.
func (Client) GetJobConfig ¶
GetJobConfig retrieves the Jenkins jobs config for the named job.
func (Client) GetJobSummaries ¶
func (client Client) GetJobSummaries() ([]JobSummary, error)
func (Client) GetJobSummariesFromFilesystem ¶
func (client Client) GetJobSummariesFromFilesystem(root string) ([]JobSummary, error)
type FreeStyleJobConfig ¶
type FreeStyleJobConfig struct {
XMLName xml.Name `xml:"project"`
SCM Scm `xml:"scm"`
JobName string
}
Freestyle project
type Jenkins ¶
type Jenkins interface {
GetJobs() (map[string]JobDescriptor, error)
GetJobConfig(jobName string) (JobConfig, error)
GetJobSummaries() ([]JobSummary, error)
GetJobSummariesFromFilesystem(root string) ([]JobSummary, error)
GetLastBuild(jobName string) (LastBuild, error)
CreateJob(jobName, jobConfigXML string) error
DeleteJob(jobName string) error
}
type JobConfig ¶
type JobConfig struct {
XMLName xml.Name `xml:"maven2-moduleset"`
SCM Scm `xml:"scm"`
Publishers Publishers `xml:"publishers"`
RootModule RootModule `xml:"rootModule"`
JobName string
}
Maven project
type JobDescriptor ¶
type JobSummary ¶
type JobSummary struct {
JobDescriptor JobDescriptor
JobType JobType
GitURL string // the use of this field is deprecated
Branch string // the use of this field is deprecated
}
Model of both Maven and Freestyle job types
type Jobs ¶
type Jobs struct {
Jobs []JobDescriptor `json:"jobs"`
}
type Publishers ¶
type Publishers struct {
XMLName xml.Name `xml:"publishers"`
RedeployPublishers []RedeployPublisher `xml:"hudson.maven.RedeployPublisher"`
}
type RedeployPublisher ¶
type RootModule ¶
type Scm ¶
type Scm struct {
XMLName xml.Name `xml:"scm"`
Class string `xml:"class,attr"`
UserRemoteConfigs UserRemoteConfigs `xml:"userRemoteConfigs"`
Branches Branches `xml:"branches"`
}
type UserRemoteConfig ¶
type UserRemoteConfigs ¶
type UserRemoteConfigs struct {
XMLName xml.Name `xml:"userRemoteConfigs"`
UserRemoteConfig []UserRemoteConfig `xml:"hudson.plugins.git.UserRemoteConfig"`
}