hgext/narrow/narrowtemplates.py
changeset 42358 45c18f7345c1
parent 38964 05ded838c997
child 43076 2372284d9457
equal deleted inserted replaced
42357:5b795108dd17 42358:45c18f7345c1
    35     """String. 'outsidenarrow' if the change affects no tracked files,
    35     """String. 'outsidenarrow' if the change affects no tracked files,
    36     else ''."""
    36     else ''."""
    37     repo = context.resource(mapping, 'repo')
    37     repo = context.resource(mapping, 'repo')
    38     ctx = context.resource(mapping, 'ctx')
    38     ctx = context.resource(mapping, 'ctx')
    39     m = repo.narrowmatch()
    39     m = repo.narrowmatch()
    40     if not m.always():
    40     if ctx.files() and not m.always():
    41         if not any(m(f) for f in ctx.files()):
    41         if not any(m(f) for f in ctx.files()):
    42             return 'outsidenarrow'
    42             return 'outsidenarrow'
    43     return ''
    43     return ''
    44 
    44 
    45 @revsetpredicate('ellipsis()')
    45 @revsetpredicate('ellipsis()')