@@ -152,20 +152,23 @@ pub enum AnalyzeCommand {
152152pub struct AnalyzeGraphCommand {
153153 /// List of files or directories to include.
154154 #[ clap( help = "List of files or directories to include [default: .]" ) ]
155- pub files : Vec < PathBuf > ,
155+ files : Vec < PathBuf > ,
156156 /// The direction of the import map. By default, generates a dependency map, i.e., a map from
157157 /// file to files that it depends on. Use `--direction dependents` to generate a map from file
158158 /// to files that depend on it.
159159 #[ clap( long, value_enum, default_value_t) ]
160- pub direction : Direction ,
160+ direction : Direction ,
161161 /// Attempt to detect imports from string literals.
162162 #[ clap( long) ]
163- pub detect_string_imports : bool ,
163+ detect_string_imports : bool ,
164164 /// Enable preview mode. Use `--no-preview` to disable.
165165 #[ arg( long, overrides_with( "no_preview" ) ) ]
166166 preview : bool ,
167167 #[ clap( long, overrides_with( "preview" ) , hide = true ) ]
168168 no_preview : bool ,
169+ /// The minimum Python version that should be supported.
170+ #[ arg( long, value_enum) ]
171+ target_version : Option < PythonVersion > ,
169172}
170173
171174// The `Parser` derive is for ruff_dev, for ruff `Args` would be sufficient
@@ -789,6 +792,7 @@ impl AnalyzeGraphCommand {
789792 None
790793 } ,
791794 preview : resolve_bool_arg ( self . preview , self . no_preview ) . map ( PreviewMode :: from) ,
795+ target_version : self . target_version ,
792796 ..ExplicitConfigOverrides :: default ( )
793797 } ;
794798
0 commit comments