Changeset 4409:3fc3e9d231b3 in livinglogic.python.xist for src/ll/scripts/ucat.py

Show
Ignore:
Timestamp:
03/07/11 12:34:29 (9 years ago)
Author:
Walter Doerwald <walter@…>
Branch:
default
Message:

The filename of a directory is empty -> treat dirs differently in match().

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • src/ll/scripts/ucat.py

    r4403 r4409  
    3333        if args.exclude is not None and args.exclude.search(strurl) is not None: 
    3434            return False 
    35         if not args.all and url.file.startswith("."): 
    36             return False 
     35        if not args.all: 
     36            if url.file: 
     37                name = url.file 
     38            elif len(url.path) >=2: 
     39                name = url.path[-2] 
     40            else: 
     41                name = "" 
     42            if name.startswith("."): 
     43                return False 
    3744        return True 
    3845