@@ -49,6 +49,7 @@ def main(
49
49
output_dir : Path = typer .Option (..., "--output" , "-o" ),
50
50
model_file : str = typer .Option (None , "--model-file" , "-m" ),
51
51
template_dir : Optional [Path ] = typer .Option (None , "--template-dir" , "-t" ),
52
+ model_template_dir : Optional [Path ] = typer .Option (None , "--model-template-dir" ),
52
53
enum_field_as_literal : Optional [LiteralType ] = typer .Option (
53
54
None , "--enum-field-as-literal"
54
55
),
@@ -82,6 +83,7 @@ def main(
82
83
encoding ,
83
84
output_dir ,
84
85
template_dir ,
86
+ model_template_dir ,
85
87
model_path ,
86
88
enum_field_as_literal = enum_field_as_literal or None ,
87
89
custom_visitors = custom_visitors ,
@@ -109,6 +111,7 @@ def generate_code(
109
111
encoding : str ,
110
112
output_dir : Path ,
111
113
template_dir : Optional [Path ],
114
+ model_template_dir : Optional [Path ] = None ,
112
115
model_path : Optional [Path ] = None ,
113
116
enum_field_as_literal : Optional [LiteralType ] = None ,
114
117
custom_visitors : Optional [List [Path ]] = None ,
@@ -140,6 +143,7 @@ def generate_code(
140
143
data_model_field_type = data_model_types .field_model ,
141
144
data_type_manager_type = data_model_types .data_type_manager ,
142
145
dump_resolve_reference_action = data_model_types .dump_resolve_reference_action ,
146
+ custom_template_dir = model_template_dir ,
143
147
target_python_version = python_version ,
144
148
)
145
149
0 commit comments