mirror of
https://github.com/woodpecker-ci/woodpecker.git
synced 2025-01-23 17:53:23 +02:00
Expose parent build number
This commit is contained in:
parent
823175605f
commit
c1b500665f
@ -144,6 +144,10 @@ var Command = cli.Command{
|
||||
Name: "build-number",
|
||||
EnvVar: "DRONE_BUILD_NUMBER",
|
||||
},
|
||||
cli.IntFlag{
|
||||
Name: "parent-build-number",
|
||||
EnvVar: "DRONE_PARENT_BUILD_NUMBER",
|
||||
},
|
||||
cli.Int64Flag{
|
||||
Name: "build-created",
|
||||
EnvVar: "DRONE_BUILD_CREATED",
|
||||
@ -389,6 +393,7 @@ func metadataFromContext(c *cli.Context) frontend.Metadata {
|
||||
},
|
||||
Curr: frontend.Build{
|
||||
Number: c.Int("build-number"),
|
||||
Parent: c.Int("parent-build-number"),
|
||||
Created: c.Int64("build-created"),
|
||||
Started: c.Int64("build-started"),
|
||||
Finished: c.Int64("build-finished"),
|
||||
|
@ -329,6 +329,7 @@ func metadataFromStruct(repo *model.Repo, build, last *model.Build, proc *model.
|
||||
},
|
||||
Curr: frontend.Build{
|
||||
Number: build.Number,
|
||||
Parent: build.Parent,
|
||||
Created: build.Created,
|
||||
Started: build.Started,
|
||||
Finished: build.Finished,
|
||||
|
Loading…
x
Reference in New Issue
Block a user