Skip to content

Commit

Permalink
Read repository configuration file (#24)
Browse files Browse the repository at this point in the history
Signed-off-by: Sergio Castaño Arteaga <[email protected]>
  • Loading branch information
tegioz authored Sep 3, 2024
1 parent cd5b60d commit 220dbde
Show file tree
Hide file tree
Showing 8 changed files with 215 additions and 3 deletions.
2 changes: 2 additions & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

1 change: 1 addition & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ pem = "3.0.4"
regex = "1.10.6"
serde = { version = "1.0.209", features = ["derive"] }
serde_json = "1.0.127"
serde_yaml = "0.9.34"
sha2 = "0.10.8"
thiserror = "1.0.63"
tokio = { version = "1.39.3", features = [
Expand Down
2 changes: 2 additions & 0 deletions dco2/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ rust-version.workspace = true
anyhow = { workspace = true }
askama = { workspace = true }
async-trait = { workspace = true }
base64 = { workspace = true }
bytes = { workspace = true }
chrono = { workspace = true }
email_address = { workspace = true }
Expand All @@ -19,6 +20,7 @@ pem = { workspace = true }
regex = { workspace = true }
serde = { workspace = true }
serde_json = { workspace = true }
serde_yaml = { workspace = true }
thiserror = { workspace = true }
tokio = { workspace = true }
tracing = { workspace = true }
Expand Down
5 changes: 4 additions & 1 deletion dco2/src/dco/check/mod.rs
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
//! This module contains the DCO check logic.
use crate::github::Commit;
use crate::github::{Commit, Config};
use askama::Template;
use email_address::EmailAddress;
use regex::Regex;
Expand All @@ -17,6 +17,7 @@ mod tests;
#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
pub(crate) struct CheckInput {
pub commits: Vec<Commit>,
pub config: Config,
pub head_ref: String,
}

Expand Down Expand Up @@ -169,6 +170,8 @@ struct SignOff {
#[derive(Debug, Clone, PartialEq, Serialize, Deserialize)]
enum SignOffKind {
Explicit,
IndividualRemediation,
ThirdPartyRemediation,
}

/// Get sign-offs found in the commit message.
Expand Down
Loading

0 comments on commit 220dbde

Please sign in to comment.