Commit eb983c61 authored by Tomáš Hübelbauer's avatar Tomáš Hübelbauer

Attach the script for getting installation counts for all of my own extensions

parent 2cf45069
......@@ -18,6 +18,38 @@
- Introduce a switch for telemetry, by default ask for eveyr report to be sent, can switch to never or always
- [ ] Follow [*TreeDataProvider: allow selecting a TreeItem without affecting its collapsibleState*](https://github.com/Microsoft/vscode/issues/34130)
### API
```javascript
void async function() {
try {
const url = 'https://marketplace.visualstudio.com/_apis/public/gallery/extensionquery?api-version=2.0-preview';
const body = {
filters: [
{
criteria: [
{
filterType: 8,
value: "Microsoft.VisualStudio.Code"
},
{
filterType: 10,
value: "publisher: \"Tomas Hubelbauer\""
}
]
}
],
flags: 914
};
const response = await fetch(url, { method: 'POST', headers: { 'Content-Type': 'application/json' }, body: JSON.stringify(body) });
const json = await response.json();
console.log(json.results[0].extensions.filter(extension => extension.flags.indexOf('unpublished') === -1).map(extension => `${extension.displayName}: ${extension.statistics.find(statistic => statistic.statisticName === 'install').value}`).join('\n'));
} catch (error) {
console.log(error);
}
}()
```
### [Box Drawing](https://marketplace.visualstudio.com/items?itemName=TomasHubelbauer.vscode-box-drawing) ![Installs](https://vsmarketplacebadge.apphb.com/installs-short/TomasHubelbauer.vscode-box-drawing.svg)
Draws boxes using ASCII or Unicode box drawing characters by enclosing mouse selection in Visual Studio Code.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment