Allow import or sort single files
This commit is contained in:
		
							parent
							
								
									b7f0cafe98
								
							
						
					
					
						commit
						f6816c6c01
					
				@ -360,7 +360,7 @@ class Paths:
 | 
				
			|||||||
        :return: Path path
 | 
					        :return: Path path
 | 
				
			||||||
        """
 | 
					        """
 | 
				
			||||||
        if not path.exists():
 | 
					        if not path.exists():
 | 
				
			||||||
            self.log.error(f'Directory {path} does not exist')
 | 
					            self.log.error(f'Path {path} does not exist')
 | 
				
			||||||
            sys.exit(1)
 | 
					            sys.exit(1)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
        return path
 | 
					        return path
 | 
				
			||||||
 | 
				
			|||||||
@ -718,6 +718,11 @@ class Medias:
 | 
				
			|||||||
        """Get paths"""
 | 
					        """Get paths"""
 | 
				
			||||||
        for src_dir in src_dirs:
 | 
					        for src_dir in src_dirs:
 | 
				
			||||||
            src_dir = self.paths.check(src_dir)
 | 
					            src_dir = self.paths.check(src_dir)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
 | 
					            if src_dir.is_file():
 | 
				
			||||||
 | 
					                yield src_dir.parent, src_dir
 | 
				
			||||||
 | 
					                continue
 | 
				
			||||||
 | 
					
 | 
				
			||||||
            paths = self.paths.get_paths_list(src_dir)
 | 
					            paths = self.paths.get_paths_list(src_dir)
 | 
				
			||||||
 | 
					
 | 
				
			||||||
            # Get medias and src_dirs
 | 
					            # Get medias and src_dirs
 | 
				
			||||||
 | 
				
			|||||||
		Loading…
	
	
			
			x
			
			
		
	
		Reference in New Issue
	
	Block a user