|
@@ -28,6 +28,7 @@ pub(crate) struct Config {
|
|
|
pub(crate) autolabel: Option<AutolabelConfig>,
|
|
|
pub(crate) notify_zulip: Option<NotifyZulipConfig>,
|
|
|
pub(crate) github_releases: Option<GitHubReleasesConfig>,
|
|
|
+ pub(crate) review_submitted: Option<ReviewSubmittedConfig>,
|
|
|
}
|
|
|
|
|
|
#[derive(PartialEq, Eq, Debug, serde::Deserialize)]
|
|
@@ -142,6 +143,12 @@ pub(crate) struct GlacierConfig {}
|
|
|
#[derive(PartialEq, Eq, Debug, serde::Deserialize)]
|
|
|
pub(crate) struct CloseConfig {}
|
|
|
|
|
|
+#[derive(PartialEq, Eq, Debug, serde::Deserialize)]
|
|
|
+pub(crate) struct ReviewSubmittedConfig {
|
|
|
+ pub(crate) review_labels: Vec<String>,
|
|
|
+ pub(crate) reviewed_label: String,
|
|
|
+}
|
|
|
+
|
|
|
pub(crate) async fn get(gh: &GithubClient, repo: &str) -> Result<Arc<Config>, ConfigurationError> {
|
|
|
if let Some(config) = get_cached_config(repo) {
|
|
|
log::trace!("returning config for {} from cache", repo);
|
|
@@ -290,6 +297,7 @@ mod tests {
|
|
|
autolabel: None,
|
|
|
notify_zulip: None,
|
|
|
github_releases: None,
|
|
|
+ review_submitted: None,
|
|
|
}
|
|
|
);
|
|
|
}
|