@@ -79,14 +79,18 @@ def _setup_arguments(cls, parser, env_default_same=False):
7979 rev-list``; or Mercurial log command. See 'specifying ranges'
8080 section of the `gitrevisions` manpage, or 'hg help revisions',
8181 for more info. Also accepts the
82- special values 'NEW', 'ALL', 'EXISTING', and 'HASHFILE:xxx'.
82+ special values 'NEW', 'ALL', 'EXISTING', 'TAGS', and
83+ 'HASHFILE:xxx'.
8384 'NEW' will benchmark all commits since the latest
84- benchmarked on this machine. 'ALL' will benchmark all
85- commits in the project. 'EXISTING' will benchmark against
86- all commits for which there are existing benchmarks on any
87- machine. 'HASHFILE:xxx' will benchmark only a specific set
88- of hashes given in the file named 'xxx' ('-' means stdin),
89- which must have one hash per line. By default, will benchmark
85+ benchmarked on this machine.
86+ 'ALL' will benchmark all commits in the project.
87+ 'EXISTING' will benchmark against all commits for which there
88+ are existing benchmarks on any machine.
89+ 'TAGS' will benchmark against all tags in the project.
90+ 'HASHFILE:xxx' will benchmark only a specific set of hashes
91+ given in the file named 'xxx' ('-' means stdin), which must
92+ have one hash per line.
93+ By default, will benchmark
9094 the head of each configured of the branches.""" )
9195 parser .add_argument (
9296 "--date-period" , type = common_args .time_period , default = None ,
@@ -232,12 +236,15 @@ def run(cls, conf, range_spec=None, steps=None, date_period=None,
232236 branch in conf .branches ]))
233237 except NoSuchNameError as exc :
234238 raise util .UserError (f'Unknown branch { exc } in configuration' )
235- elif range_spec == ' EXISTING' :
239+ elif range_spec == " EXISTING" :
236240 commit_hashes = get_existing_hashes (conf .results_dir )
237241 elif range_spec == "NEW" :
238242 # New commits on each configured branches
239243 old_commit_hashes = get_existing_hashes (conf .results_dir )
240244 commit_hashes = repo .get_new_branch_commits (conf .branches , old_commit_hashes )
245+ elif range_spec == "TAGS" :
246+ # All tags on each configured branches
247+ commit_hashes = list (reversed (list (repo .get_tags ().keys ())))
241248 elif range_spec == "ALL" :
242249 # All commits on each configured branches
243250 commit_hashes = repo .get_new_branch_commits (conf .branches , [])
0 commit comments