comparison mercurial/logcmdutil.py @ 46042:1bf2b44c4007

log: do not accept string-matcher pattern as -u/-b/-B parameter I'm pretty sure this is a bug introduced after we've switched the filtering backend to revset matcher.
author Yuya Nishihara <yuya@tcha.org>
date Tue, 01 Dec 2020 20:22:24 +0900
parents 9c0db3671008
children 4a012e531066 9842c00f0252
comparison
equal deleted inserted replaced
46041:9c0db3671008 46042:1bf2b44c4007
896 896
897 897
898 def _makerevset(repo, wopts, slowpath): 898 def _makerevset(repo, wopts, slowpath):
899 """Return a revset string built from log options and file patterns""" 899 """Return a revset string built from log options and file patterns"""
900 opts = { 900 opts = {
901 b'branch': [repo.lookupbranch(b) for b in wopts.branches], 901 b'branch': [b'literal:' + repo.lookupbranch(b) for b in wopts.branches],
902 b'date': wopts.date, 902 b'date': wopts.date,
903 b'keyword': wopts.keywords, 903 b'keyword': wopts.keywords,
904 b'no_merges': wopts.no_merges, 904 b'no_merges': wopts.no_merges,
905 b'only_merges': wopts.only_merges, 905 b'only_merges': wopts.only_merges,
906 b'prune': wopts.prune_ancestors, 906 b'prune': wopts.prune_ancestors,
907 b'user': wopts.users, 907 b'user': [b'literal:' + v for v in wopts.users],
908 } 908 }
909 909
910 if wopts.filter_revisions_by_pats and slowpath: 910 if wopts.filter_revisions_by_pats and slowpath:
911 # pats/include/exclude cannot be represented as separate 911 # pats/include/exclude cannot be represented as separate
912 # revset expressions as their filtering logic applies at file 912 # revset expressions as their filtering logic applies at file