Skip to content

Commit

Permalink
notify chat on nightly success also (#8832)
Browse files Browse the repository at this point in the history
  • Loading branch information
PrajwolAmatya authored Apr 11, 2024
1 parent e4a2760 commit 244ce97
Showing 1 changed file with 7 additions and 5 deletions.
12 changes: 7 additions & 5 deletions .drone.star
Original file line number Diff line number Diff line change
Expand Up @@ -289,7 +289,7 @@ def main(ctx):
# always append notification step
pipelines.append(
pipelineDependsOn(
notify(),
notify(ctx),
pipelines,
),
)
Expand Down Expand Up @@ -1956,7 +1956,11 @@ def makeGoGenerate(module):
},
]

def notify():
def notify(ctx):
status = ["failure"]
if ctx.build.event == "cron":
status.append("success")

return {
"kind": "pipeline",
"type": "docker",
Expand All @@ -1983,9 +1987,7 @@ def notify():
"refs/heads/release*",
"refs/tags/**",
],
"status": [
"failure",
],
"status": status,
},
}

Expand Down

0 comments on commit 244ce97

Please sign in to comment.