@@ -183,24 +183,24 @@ fn get_known_conda_locations() -> Vec<PathBuf> {
183183#[ cfg( unix) ]
184184fn get_known_conda_locations ( ) -> Vec < PathBuf > {
185185 let mut known_paths = vec ! [
186- Path :: new ( "/opt/anaconda3/bin" ) . to_path_buf ( ) ,
187- Path :: new ( "/opt/miniconda3/bin" ) . to_path_buf ( ) ,
188- Path :: new ( "/usr/local/anaconda3/bin" ) . to_path_buf ( ) ,
189- Path :: new ( "/usr/local/miniconda3/bin" ) . to_path_buf ( ) ,
190- Path :: new ( "/usr/anaconda3/bin" ) . to_path_buf ( ) ,
191- Path :: new ( "/usr/miniconda3/bin" ) . to_path_buf ( ) ,
192- Path :: new ( "/home/anaconda3/bin" ) . to_path_buf ( ) ,
193- Path :: new ( "/home/miniconda3/bin" ) . to_path_buf ( ) ,
194- Path :: new ( "/anaconda3/bin" ) . to_path_buf ( ) ,
195- Path :: new ( "/miniconda3/bin" ) . to_path_buf ( ) ,
196- Path :: new ( "/usr/local/anaconda3/bin" ) . to_path_buf ( ) ,
197- Path :: new ( "/usr/local/miniconda3/bin" ) . to_path_buf ( ) ,
198- Path :: new ( "/usr/anaconda3/bin" ) . to_path_buf ( ) ,
199- Path :: new ( "/usr/miniconda3/bin" ) . to_path_buf ( ) ,
200- Path :: new ( "/home/anaconda3/bin" ) . to_path_buf ( ) ,
201- Path :: new ( "/home/miniconda3/bin" ) . to_path_buf ( ) ,
202- Path :: new ( "/anaconda3/bin" ) . to_path_buf ( ) ,
203- Path :: new ( "/miniconda3/bin" ) . to_path_buf ( ) ,
186+ PathBuf :: from ( "/opt/anaconda3/bin" ) ,
187+ PathBuf :: from ( "/opt/miniconda3/bin" ) ,
188+ PathBuf :: from ( "/usr/local/anaconda3/bin" ) ,
189+ PathBuf :: from ( "/usr/local/miniconda3/bin" ) ,
190+ PathBuf :: from ( "/usr/anaconda3/bin" ) ,
191+ PathBuf :: from ( "/usr/miniconda3/bin" ) ,
192+ PathBuf :: from ( "/home/anaconda3/bin" ) ,
193+ PathBuf :: from ( "/home/miniconda3/bin" ) ,
194+ PathBuf :: from ( "/anaconda3/bin" ) ,
195+ PathBuf :: from ( "/miniconda3/bin" ) ,
196+ PathBuf :: from ( "/usr/local/anaconda3/bin" ) ,
197+ PathBuf :: from ( "/usr/local/miniconda3/bin" ) ,
198+ PathBuf :: from ( "/usr/anaconda3/bin" ) ,
199+ PathBuf :: from ( "/usr/miniconda3/bin" ) ,
200+ PathBuf :: from ( "/home/anaconda3/bin" ) ,
201+ PathBuf :: from ( "/home/miniconda3/bin" ) ,
202+ PathBuf :: from ( "/anaconda3/bin" ) ,
203+ PathBuf :: from ( "/miniconda3/bin" ) ,
204204 ] ;
205205 known_paths. append ( & mut known:: get_know_global_search_locations ( ) ) ;
206206 known_paths
@@ -333,7 +333,7 @@ fn get_distinct_conda_envs(conda_bin: PathBuf) -> Vec<CondaEnv> {
333333
334334 let locations = get_known_env_locations ( conda_bin) ;
335335 let mut conda_envs = vec ! [ ] ;
336- for env in envs. clone ( ) {
336+ for env in envs {
337337 let env = Path :: new ( & env) ;
338338 let mut named = false ;
339339 let mut name = "" . to_string ( ) ;
0 commit comments