gecko-dev/tools/moztreedocs
Mitchell Hentges 648ccad85b Bug 1654074: Publish glean handle to mach commands r=firefox-build-system-reviewers,rstewart
Allows mach commands to define their own glean metrics with the `metrics_path` @CommandProvider parameter.
When `metrics_path` is defined:
* A `metrics` kwarg is provided to the decorated class. This `metrics` handle is a Glean instance, so Glean documentation should be consulted for usage information.
* When `mach doc telemetry` is run, metrics docs will be generated from all the registered metrics files.

Note: there was some consideration between making `metrics_path` a @CommandProvider or @Command parameter.
In the end, @CommandProvider seemed like a better fit because:
* Metrics seem to be more associated with the entire class than a specific command/method. This is because a class represents a "domain", and that domain may have different commands that have overlapping metrics.  Accordingly, all the metrics should be defined once as available to the entire class.
* Currently, @Command methods only take parameters that map one-to-one with CLI arguments. It could seem inconsistent to have one exception: the metrics handle

Differential Revision: https://phabricator.services.mozilla.com/D85953
2020-09-15 21:15:20 +00:00
..
docs Bug 1663916 - mdn to in-tree: Update of the mdn import doc r=dmajor 2020-09-09 15:13:07 +00:00
__init__.py Bug 1660615 - ride along - reformat moztreedocs with black r=firefox-source-docs-reviewers,championshuttler 2020-08-23 08:49:52 +00:00
mach_commands.py Bug 1654074: Publish glean handle to mach commands r=firefox-build-system-reviewers,rstewart 2020-09-15 21:15:20 +00:00
package.py Bug 1660615 - ride along - reformat moztreedocs with black r=firefox-source-docs-reviewers,championshuttler 2020-08-23 08:49:52 +00:00
requirements.in Bug 1655107 - [moztreedocs] Use pip-tools rather than pipenv to manage doc dependencies r=championshuttler,sylvestre 2020-08-17 17:46:23 +00:00
requirements.txt Bug 1655107 - [moztreedocs] Use pip-tools rather than pipenv to manage doc dependencies r=championshuttler,sylvestre 2020-08-17 17:46:23 +00:00
upload.py Bug 1664771 - [docs] Remove bogus 'Expires' header when uploading docs, r=firefox-source-docs-reviewers,championshuttler 2020-09-14 20:06:57 +00:00