##// END OF EJS Templates
revset: add option to make matcher takes the ordering of the input set...
Yuya Nishihara -
r29955:1b593160 default
parent child Browse files
Show More
@@ -2694,13 +2694,21 b' def posttreebuilthook(tree, repo):'
2694 # hook for extensions to execute code on the optimized tree
2694 # hook for extensions to execute code on the optimized tree
2695 pass
2695 pass
2696
2696
2697 def match(ui, spec, repo=None):
2697 def match(ui, spec, repo=None, order=defineorder):
2698 """Create a matcher for a single revision spec."""
2698 """Create a matcher for a single revision spec
2699 return matchany(ui, [spec], repo=repo)
2699
2700
2700 If order=followorder, a matcher takes the ordering specified by the input
2701 def matchany(ui, specs, repo=None):
2701 set.
2702 """
2703 return matchany(ui, [spec], repo=repo, order=order)
2704
2705 def matchany(ui, specs, repo=None, order=defineorder):
2702 """Create a matcher that will include any revisions matching one of the
2706 """Create a matcher that will include any revisions matching one of the
2703 given specs"""
2707 given specs
2708
2709 If order=followorder, a matcher takes the ordering specified by the input
2710 set.
2711 """
2704 if not specs:
2712 if not specs:
2705 def mfunc(repo, subset=None):
2713 def mfunc(repo, subset=None):
2706 return baseset()
2714 return baseset()
@@ -2718,7 +2726,7 b' def matchany(ui, specs, repo=None):'
2718 if ui:
2726 if ui:
2719 tree = expandaliases(ui, tree)
2727 tree = expandaliases(ui, tree)
2720 tree = foldconcat(tree)
2728 tree = foldconcat(tree)
2721 tree = analyze(tree)
2729 tree = analyze(tree, order)
2722 tree = optimize(tree)
2730 tree = optimize(tree)
2723 posttreebuilthook(tree, repo)
2731 posttreebuilthook(tree, repo)
2724 return makematcher(tree)
2732 return makematcher(tree)
General Comments 0
You need to be logged in to leave comments. Login now