pub struct PRGenerationConfig {
pub enabled: bool,
pub provider: PRProvider,
pub owner: String,
pub repo: String,
pub token: Option<String>,
pub base_branch: String,
pub branch_prefix: String,
pub auto_merge: bool,
pub reviewers: Vec<String>,
pub labels: Vec<String>,
}Expand description
Configuration for PR generation
Fields§
§enabled: boolWhether PR generation is enabled
provider: PRProviderPR provider
owner: StringRepository owner/org
repo: StringRepository name
token: Option<String>Authentication token (GitHub PAT or GitLab token) Can be set via environment variable: GITHUB_TOKEN or GITLAB_TOKEN
base_branch: StringBase branch (default: main)
branch_prefix: StringBranch prefix for generated branches
auto_merge: boolWhether to auto-merge PRs (requires auto-merge enabled in repo)
reviewers: Vec<String>List of reviewers (usernames)
labels: Vec<String>Labels to add to PRs
Implementations§
Source§impl PRGenerationConfig
impl PRGenerationConfig
Sourcepub fn from_env() -> PRGenerationConfig
pub fn from_env() -> PRGenerationConfig
Load configuration from environment variables
This method loads configuration from environment variables, with the following priority:
- Explicit config values (if set)
- Environment variables
- Default values
Trait Implementations§
Source§impl Clone for PRGenerationConfig
impl Clone for PRGenerationConfig
Source§fn clone(&self) -> PRGenerationConfig
fn clone(&self) -> PRGenerationConfig
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for PRGenerationConfig
impl Debug for PRGenerationConfig
Source§impl Default for PRGenerationConfig
impl Default for PRGenerationConfig
Source§fn default() -> PRGenerationConfig
fn default() -> PRGenerationConfig
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for PRGenerationConfig
impl<'de> Deserialize<'de> for PRGenerationConfig
Source§fn deserialize<__D>(
__deserializer: __D,
) -> Result<PRGenerationConfig, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D,
) -> Result<PRGenerationConfig, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl JsonSchema for PRGenerationConfig
impl JsonSchema for PRGenerationConfig
Source§fn schema_name() -> String
fn schema_name() -> String
The name of the generated JSON Schema. Read more
Source§fn schema_id() -> Cow<'static, str>
fn schema_id() -> Cow<'static, str>
Returns a string that uniquely identifies the schema produced by this type. Read more
Source§fn json_schema(generator: &mut SchemaGenerator) -> Schema
fn json_schema(generator: &mut SchemaGenerator) -> Schema
Generates a JSON Schema for this type. Read more
Source§fn is_referenceable() -> bool
fn is_referenceable() -> bool
Whether JSON Schemas generated for this type should be re-used where possible using the
$ref keyword. Read moreSource§impl Serialize for PRGenerationConfig
impl Serialize for PRGenerationConfig
Source§fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
fn serialize<__S>(
&self,
__serializer: __S,
) -> Result<<__S as Serializer>::Ok, <__S as Serializer>::Error>where
__S: Serializer,
Serialize this value into the given Serde serializer. Read more
Auto Trait Implementations§
impl Freeze for PRGenerationConfig
impl RefUnwindSafe for PRGenerationConfig
impl Send for PRGenerationConfig
impl Sync for PRGenerationConfig
impl Unpin for PRGenerationConfig
impl UnsafeUnpin for PRGenerationConfig
impl UnwindSafe for PRGenerationConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more