Skip to content

Commit 8826554

Browse files
authored
Automate lint FCP Zulip topic creation with triagebot (rust-lang#16614)
As discussed in [#clippy > Automatic creation of FCP Zulip topics](https://rust-lang.zulipchat.com/#narrow/channel/257328-clippy/topic/Automatic.20creation.20of.20FCP.20Zulip.20topics/with/575155235), this PR configures triagebot to automatically create a Zulip topic in `#clippy` for lint nomination. It is triggered by the `lint-nominated` label (need to be created). In addition to containing a link to the pull request, the topic will also contain a Zulip poll with three per-determined answers: approve, decline, don't know. cc @samueltardieu r? @flip1995 changelog: none
2 parents 3120b98 + cd8bee3 commit 8826554

File tree

1 file changed

+20
-0
lines changed

1 file changed

+20
-0
lines changed

triagebot.toml

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,26 @@ labels = ["S-waiting-on-concerns"]
6060
[view-all-comments-link]
6161
threshold = 20
6262

63+
[notify-zulip."lint-nominated"]
64+
zulip_stream = 577190 # #clippy/fcp
65+
topic = "FCP rust-clippy#{number}: {title}"
66+
# Zulip polls may not be preceded by any other text and pings & short links inside
67+
# the title of a poll don't get recognized. Therefore we need to send two messages.
68+
message_on_add = [
69+
"""\
70+
PR rust-clippy#{number} "{title}" has been nominated for lint inclusion.
71+
""",
72+
"""\
73+
/poll Approve lint inclusion of rust-clippy#{number}?
74+
approve
75+
decline
76+
don't know
77+
""",
78+
]
79+
message_on_remove = "PR rust-clippy#{number} lint nomination has been removed."
80+
message_on_close = "PR rust-clippy#{number} has been closed. Thanks for participating!"
81+
message_on_reopen = "PR rust-clippy#{number} has been reopened."
82+
6383
[assign]
6484
contributing_url = "https://github.com/rust-lang/rust-clippy/blob/master/CONTRIBUTING.md"
6585
users_on_vacation = [

0 commit comments

Comments
 (0)