0
0
mirror of https://github.com/thegeeklab/wp-plugin-go.git synced 2024-11-25 09:30:39 +00:00

Sort lines

This commit is contained in:
Don 2019-09-09 17:03:34 -07:00
parent 703857da2f
commit 799bb0f53a
2 changed files with 21 additions and 21 deletions

View File

@ -35,26 +35,26 @@ const (
BuildActionEnvVar = "DRONE_BUILD_ACTION" BuildActionEnvVar = "DRONE_BUILD_ACTION"
// BuildCreatedEnvVar corresponds to Build.Created. // BuildCreatedEnvVar corresponds to Build.Created.
BuildCreatedEnvVar = "DRONE_BUILD_CREATED" BuildCreatedEnvVar = "DRONE_BUILD_CREATED"
// BuildDeployToEnvVar corresponds to Build.DeployTo.
BuildDeployToEnvVar = "DRONE_DEPLOY_TO"
// BuildEventEnvVar corresponds to Build.Event. // BuildEventEnvVar corresponds to Build.Event.
BuildEventEnvVar = "DRONE_BUILD_EVENT" BuildEventEnvVar = "DRONE_BUILD_EVENT"
// BuildFailedStagesEnvVar corresponds to Build.FailedStages.
BuildFailedStagesEnvVar = "DRONE_FAILED_STAGES"
// BuildFailedStepsEnvVar corresponds to Build.FailedSteps.
BuildFailedStepsEnvVar = "DRONE_FAILED_STEPS"
// BuildFinishedEnvVar corresponds to Build.Finished. // BuildFinishedEnvVar corresponds to Build.Finished.
BuildFinishedEnvVar = "DRONE_BUILD_FINISHED" BuildFinishedEnvVar = "DRONE_BUILD_FINISHED"
// BuildNumberEnvVar corresponds to Build.Created. // BuildNumberEnvVar corresponds to Build.Created.
BuildNumberEnvVar = "DRONE_BUILD_NUMBER" BuildNumberEnvVar = "DRONE_BUILD_NUMBER"
// BuildParentEnvVar corresponds to Build.Parent. // BuildParentEnvVar corresponds to Build.Parent.
BuildParentEnvVar = "DRONE_BUILD_PARENT" BuildParentEnvVar = "DRONE_BUILD_PARENT"
// BuildPullRequestEnvVar corresponds to Build.PullRequest.
BuildPullRequestEnvVar = "DRONE_PULL_REQUEST"
// BuildStartedEnvVar corresponds to Build.Started. // BuildStartedEnvVar corresponds to Build.Started.
BuildStartedEnvVar = "DRONE_BUILD_STARTED" BuildStartedEnvVar = "DRONE_BUILD_STARTED"
// BuildStatusEnvVar corresponds to Build.Status. // BuildStatusEnvVar corresponds to Build.Status.
BuildStatusEnvVar = "DRONE_BUILD_STATUS" BuildStatusEnvVar = "DRONE_BUILD_STATUS"
// BuildDeployToEnvVar corresponds to Build.DeployTo.
BuildDeployToEnvVar = "DRONE_DEPLOY_TO"
// BuildFailedStagesEnvVar corresponds to Build.FailedStages.
BuildFailedStagesEnvVar = "DRONE_FAILED_STAGES"
// BuildFailedStepsEnvVar corresponds to Build.FailedSteps.
BuildFailedStepsEnvVar = "DRONE_FAILED_STEPS"
// BuildPullRequestEnvVar corresponds to Build.PullRequest.
BuildPullRequestEnvVar = "DRONE_PULL_REQUEST"
// BuildSourceBranchEnvVar corresponds to Build.SourceBranch. // BuildSourceBranchEnvVar corresponds to Build.SourceBranch.
BuildSourceBranchEnvVar = "DRONE_SOURCE_BRANCH" BuildSourceBranchEnvVar = "DRONE_SOURCE_BRANCH"
// BuildTagEnvVar corresponds to Build.Tag. // BuildTagEnvVar corresponds to Build.Tag.

View File

@ -34,26 +34,26 @@ type (
Action string Action string
// Created time of the build. // Created time of the build.
Created time.Time Created time.Time
// DeployTo the environment.
DeployTo string
// Event that triggered the build. // Event that triggered the build.
Event string Event string
// FailedStages of the build.
FailedStages []string
// FailedSteps of the build.
FailedSteps []string
// Finished time of the build. // Finished time of the build.
Finished time.Time Finished time.Time
// Number for the build. // Number for the build.
Number int Number int
// Parent build number for the build. // Parent build number for the build.
Parent int Parent int
// PullRequest number of the build.
PullRequest int
// Started time of the build. // Started time of the build.
Started time.Time Started time.Time
// Status of the build. // Status of the build.
Status string Status string
// DeployTo the environment.
DeployTo string
// FailedStages of the build.
FailedStages []string
// FailedSteps of the build.
FailedSteps []string
// PullRequest number of the build.
PullRequest int
// SourceBranch for the pull request. // SourceBranch for the pull request.
SourceBranch string SourceBranch string
// Tag of the build. // Tag of the build.
@ -194,17 +194,17 @@ func BuildFromEnv() Build {
return Build{ return Build{
Action: StringEnvVar(BuildActionEnvVar), Action: StringEnvVar(BuildActionEnvVar),
Created: TimeEnvVar(BuildCreatedEnvVar), Created: TimeEnvVar(BuildCreatedEnvVar),
DeployTo: StringEnvVar(BuildDeployToEnvVar),
Event: StringEnvVar(BuildEventEnvVar), Event: StringEnvVar(BuildEventEnvVar),
FailedStages: StringSliceEnvVar(BuildFailedStagesEnvVar),
FailedSteps: StringSliceEnvVar(BuildFailedStepsEnvVar),
Finished: TimeEnvVar(BuildFinishedEnvVar), Finished: TimeEnvVar(BuildFinishedEnvVar),
Number: IntEnvVar(BuildNumberEnvVar), Number: IntEnvVar(BuildNumberEnvVar),
Parent: IntEnvVar(BuildParentEnvVar), Parent: IntEnvVar(BuildParentEnvVar),
Started: TimeEnvVar(BuildStartedEnvVar),
Status: StringEnvVar(BuildStatusEnvVar),
DeployTo: StringEnvVar(BuildDeployToEnvVar),
FailedStages: StringSliceEnvVar(BuildFailedStagesEnvVar),
FailedSteps: StringSliceEnvVar(BuildFailedStepsEnvVar),
PullRequest: IntEnvVar(BuildPullRequestEnvVar), PullRequest: IntEnvVar(BuildPullRequestEnvVar),
SourceBranch: StringEnvVar(BuildSourceBranchEnvVar), SourceBranch: StringEnvVar(BuildSourceBranchEnvVar),
Started: TimeEnvVar(BuildStartedEnvVar),
Status: StringEnvVar(BuildStatusEnvVar),
Tag: StringEnvVar(BuildTagEnvVar), Tag: StringEnvVar(BuildTagEnvVar),
TargetBranch: StringEnvVar(BuildTargetBranchEnvVar), TargetBranch: StringEnvVar(BuildTargetBranchEnvVar),
} }