Skip to content

Commit 32eb556

Browse files
authored
Add DRONE_BUILD_PARENT for threaded builds (#131)
1 parent ac6588d commit 32eb556

File tree

2 files changed

+7
-0
lines changed

2 files changed

+7
-0
lines changed

main.go

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -146,6 +146,11 @@ func main() {
146146
Usage: "build number",
147147
EnvVar: "DRONE_BUILD_NUMBER",
148148
},
149+
cli.IntFlag{
150+
Name: "build.parent",
151+
Usage: "build parent",
152+
EnvVar: "DRONE_BUILD_PARENT",
153+
},
149154
cli.StringFlag{
150155
Name: "build.status",
151156
Usage: "build status",
@@ -202,6 +207,7 @@ func run(c *cli.Context) error {
202207
Build: Build{
203208
Tag: c.String("build.tag"),
204209
Number: c.Int("build.number"),
210+
Parent: c.Int("build.parent"),
205211
Event: c.String("build.event"),
206212
Status: c.String("build.status"),
207213
Commit: c.String("commit.sha"),

plugin.go

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ type (
1818
Tag string
1919
Event string
2020
Number int
21+
Parent int
2122
Commit string
2223
Ref string
2324
Branch string

0 commit comments

Comments
 (0)