Changes the script for creating change notes to read the EDITOR environment variable, and use the editor specified therein. This makes the script more convenient when used from a terminal. The VSCode task is updated to the set EDITOR to `code -r` which preserves the current behavior.
Use this script if you want to quickly calculate the totals of some
query across all the queries in a MRVA run.
For an example of such a query, see e.g.
`python/ql/src/Metrics/Internal/TypeAnnotations.ql`
The script expects the query to produce an output table of the form
```
| header0 | header1 | header2 | header3 | ...
|----------|----------|----------|----------|----
| message1 | value11 | value12 | value13 | ...
| message2 | value21 | value22 | value23 | ...
...
```
where all of the `values` are numbers. For each `(message, header)`
pair, it then calculates the total of all the values in that cell,
across all of the repos in the MRVA run.
To use the script, simply pass it the URL of the exported Gist of the
MRVA run. After calculating the totals, the script will then
(optionally, but by default) add the totals to the `_summary.md` file,
and push these changes to the Gist.
Adds a VSCode Task (accessible from the "Run Task" menu) for creating
change notes, prompting the user for the language, name, and category of
the change.
The language options presented are based on the existing occurrences of
`change-notes` folders in the repo. There are more such files (in
particular every shared library has a `change-notes` directory), but it
seemed to me that the language change notes are the ones that are most
common, and so in an effort to not clutter the list too much, I only
included the languages.
The selection of categories is based on existing usage -- more
specifically the result of grepping for occurrences of '^category: ' in
the repo. It's possible there are more change categories that could be
added.
Hopefully this should make it more convenient to create change notes
from within VSCode.
When using a sufficiently new version of Python, it will give a warning
about the escape sequence `\_` in `¯\_(ツ)_/¯` not being a valid escape
:D fix is to make the docstring a raw string.
Thanks @owen-mc