comparison mercurial/revset.py @ 16528:5d803620ca05 stable

doc: flatten description of 'matching()' predicate to be formatted well current description of 'matching()' revset predicate can't be formatted well on "hg help revset" output. each descriptions for revset predicates (or something like them) are split-ed into lines, and spaces on left side of them are stripped before minirst processing. so, bullet list can't be nested. this patch just flattens description of 'matching()' predicate to be formatted well.
author FUJIWARA Katsunori <foozy@lares.dti.ne.jp>
date Thu, 26 Apr 2012 21:32:48 +0900
parents 592701c8eac6
children 00290bd359fe
comparison
equal deleted inserted replaced
16527:17a1f7690b49 16528:5d803620ca05
912 912
913 def matching(repo, subset, x): 913 def matching(repo, subset, x):
914 """``matching(revision [, field])`` 914 """``matching(revision [, field])``
915 Changesets in which a given set of fields match the set of fields in the 915 Changesets in which a given set of fields match the set of fields in the
916 selected revision or set. 916 selected revision or set.
917
917 To match more than one field pass the list of fields to match separated 918 To match more than one field pass the list of fields to match separated
918 by spaces (e.g. 'author description'). 919 by spaces (e.g. ``author description``).
919 Valid fields are most regular revision fields and some special fields: 920
920 * regular fields: 921 Valid fields are most regular revision fields and some special fields.
921 - description, author, branch, date, files, phase, parents, 922
922 substate, user. 923 Regular revision fields are ``description``, ``author``, ``branch``,
923 Note that author and user are synonyms. 924 ``date``, ``files``, ``phase``, ``parents``, ``substate`` and ``user``.
924 * special fields: summary, metadata. 925 Note that ``author`` and ``user`` are synonyms.
925 - summary: matches the first line of the description. 926
926 - metatadata: It is equivalent to matching 'description user date' 927 Special fields are ``summary`` and ``metadata``:
927 (i.e. it matches the main metadata fields). 928 ``summary`` matches the first line of the description.
928 metadata is the default field which is used when no fields are specified. 929 ``metatadata`` is equivalent to matching ``description user date``
929 You can match more than one field at a time. 930 (i.e. it matches the main metadata fields).
931
932 ``metadata`` is the default field which is used when no fields are
933 specified. You can match more than one field at a time.
930 """ 934 """
931 l = getargs(x, 1, 2, _("matching takes 1 or 2 arguments")) 935 l = getargs(x, 1, 2, _("matching takes 1 or 2 arguments"))
932 936
933 revs = getset(repo, xrange(len(repo)), l[0]) 937 revs = getset(repo, xrange(len(repo)), l[0])
934 938