rewrite generator entirely, again
This commit is contained in:
32
src/config/output.rs
Normal file
32
src/config/output.rs
Normal file
@@ -0,0 +1,32 @@
|
||||
use std::path::PathBuf;
|
||||
|
||||
use serde::{Deserialize, Serialize};
|
||||
|
||||
#[derive(Deserialize, Serialize, Debug, Clone)]
|
||||
pub struct OutputConfig {
|
||||
pub path: PathBuf,
|
||||
pub models: OutputModelConfig,
|
||||
}
|
||||
|
||||
#[derive(Deserialize, Serialize, Debug, Clone)]
|
||||
pub struct OutputModelConfig {
|
||||
pub prelude: bool,
|
||||
pub enable: bool,
|
||||
pub path: PathBuf,
|
||||
pub comment: OutputCommentConfig,
|
||||
pub entities: String,
|
||||
}
|
||||
|
||||
#[derive(Deserialize, Serialize, Debug, Clone)]
|
||||
pub struct OutputCommentConfig {
|
||||
pub enable: bool,
|
||||
pub max_width: Option<u16>,
|
||||
pub table_name: bool,
|
||||
pub column_info: bool,
|
||||
pub column_name: bool,
|
||||
pub column_db_type: bool,
|
||||
pub column_rust_type: bool,
|
||||
pub column_attributes: bool,
|
||||
pub column_exclude_attributes: Vec<String>,
|
||||
pub ignore_errors: bool,
|
||||
}
|
||||
Reference in New Issue
Block a user