license¶

                                                                                
 Usage: lftools-uv license [OPTIONS] COMMAND [ARGS]...                          
                                                                                
 Scan code for license headers                                                  
                                                                                
╭─ Options ────────────────────────────────────────────────────────────────────╮
│ --help        <bool>  Show this message and exit.                            │
╰──────────────────────────────────────────────────────────────────────────────╯
╭─ Commands ───────────────────────────────────────────────────────────────────╮
│ check       Check files for missing license headers.                         │
│ check-dir   Check directory for files missing license headers.               │
╰──────────────────────────────────────────────────────────────────────────────╯

Commands¶

check¶

                                                                                
 Usage: lftools-uv license check [OPTIONS] {source}                             
                                                                                
 Check files for missing license headers.                                       
                                                                                
 Does not care about line formatting of the license as long as all of the text  
 is there and in the correct order.                                             
                                                                                
 Note: This code only supports '#' comments for license headers.                
                                                                                
 Args: source: Source file or directory to check for license headers            
 license_file: License header file to compare against regex: File regex pattern 
 to match on when checking a directory                                          
                                                                                
 Examples: lftools-uv license check src/ lftools-uv license check myfile.py     
 --license custom-header.txt lftools-uv license check scripts/ --regex '.+.sh$' 
                                                                                
╭─ Arguments ──────────────────────────────────────────────────────────────────╮
│ *    source      <path>  Source file or directory to check                   │
│                          [required]                                          │
╰──────────────────────────────────────────────────────────────────────────────╯
╭─ Options ────────────────────────────────────────────────────────────────────╮
│ --license  -l      <str>   License header file to compare against            │
│                            [default: license-header.txt]                     │
│ --regex    -r      <str>   File regex pattern to match on when checking a    │
│                            directory                                         │
│                            [default: .+\.py$]                                │
│ --help             <bool>  Show this message and exit.                       │
╰──────────────────────────────────────────────────────────────────────────────╯

check-dir¶

                                                                                
 Usage: lftools-uv license check-dir [OPTIONS] {directory}                      
                                                                                
 Check directory for files missing license headers.                             
                                                                                
 Uses a regex pattern to find files to check for approved license headers.      
 Exits 1 when a matching file lacks the header, when the directory does not     
 exist, or when no file matches, logging each finding to stderr.                
                                                                                
 Note: This code only supports '#' comments for license headers.                
                                                                                
 Examples: lftools-uv license check-dir lftools_uv lftools-uv license check-dir 
 --license header.txt scripts                                                   
                                                                                
╭─ Arguments ──────────────────────────────────────────────────────────────────╮
│ *    directory      <str>  Directory to search for files to check            │
│                            [required]                                        │
╰──────────────────────────────────────────────────────────────────────────────╯
╭─ Options ────────────────────────────────────────────────────────────────────╮
│ --license  -l      <str>   License header file to compare against            │
│                            [default: license-header.txt]                     │
│ --regex    -r      <str>   File regex pattern to match on when searching     │
│                            [default: .+\.py$]                                │
│ --help             <bool>  Show this message and exit.                       │
╰──────────────────────────────────────────────────────────────────────────────╯