jetbrains.buildServer.configs.kotlin.v2018_1.triggers / ScheduleTrigger

ScheduleTrigger

open class ScheduleTrigger : Trigger

Base class for Schedule Build Triggers. Schedule trigger runs builds by specified schedule.

See Also

schedule

Types

DAY

enum class DAY

SchedulingPolicy

sealed class SchedulingPolicy : CompoundParam<SchedulingPolicy>

TriggerBuild

sealed class TriggerBuild : CompoundParam<TriggerBuild>

WatchedBuildRule

enum class WatchedBuildRule

Specifies which build to watch

Constructors

<init>

ScheduleTrigger(init: ScheduleTrigger.() -> Unit)ScheduleTrigger()

Base class for Schedule Build Triggers. Schedule trigger runs builds by specified schedule.

Properties

branchFilter

var branchFilter: String?

Branch filter specifies set of branches where build should be triggered

enableQueueOptimization

var enableQueueOptimization: Boolean?

Whether the trigger should allow builds optimization in the build queue. By default optimization is enabled.

enforceCleanCheckout

var enforceCleanCheckout: Boolean?

Whether the build should be triggered with clean checkout

enforceCleanCheckoutForDependencies

var enforceCleanCheckoutForDependencies: Boolean?

When the enforceCleanCheckout is set to true specifies whether the clean checkout should also be applied to all dependencies.

schedulingPolicy

var schedulingPolicy: SchedulingPolicy?

Specifies when the build should be triggered. Use daily, weekly, or cron methods to specify it.

triggerBuild

var triggerBuild: TriggerBuild?

Specifies whether build should be triggered only when the specified watched build changes. Use always, or onWatchedBuildChange methods to specify it.

triggerBuildOnAllCompatibleAgents

var triggerBuildOnAllCompatibleAgents: Boolean?

When this option is enabled the build will be triggered on all enabled compatible agents

triggerRules

var triggerRules: String?

Specifies trigger rules

withPendingChangesOnly

var withPendingChangesOnly: Boolean?

Whether the trigger should run build only when there are pending changes in the build configuration

Inherited Properties

enabled

var enabled: Boolean

Specifies whether the trigger is enabled

id

var id: String?

Trigger id, if not set will be generated

type

var type: String

Trigger type

Functions

always

fun always(): Always

Don't watch any build, trigger build using the specified schedule

cron

fun cron(init: Cron.() -> Unit = {}): Cron

Build is triggered by time in the cron expression

daily

fun daily(init: Daily.() -> Unit = {}): Daily

Build is triggered daily on the specified hour and minuted in the given timezone

onWatchedBuildChange

fun onWatchedBuildChange(init: OnWatchedBuildChange.() -> Unit = {}): OnWatchedBuildChange

Trigger build only when the watched build changes

validate

open fun validate(consumer: ErrorConsumer): Unit

Validates this object and reports found errors to the provided consumer

weekly

fun weekly(init: Weekly.() -> Unit = {}): Weekly

Build is triggered weekly on the specified day on the specified hour and minuted in the given timezone

Inherited Functions

create

open fun create(): Trigger

Creates an instance of this trigger via reflection using a no argument constructor, used during copying. Throws an error if this class doesn't have a default constructor. Subclasses can override it to create an instance without using a default constructor.

toString

open fun toString(): String