Upgrade gadgets when they change

This adds a --upgrade option to install_gadget.py and makes
VimspectorUpdate only update things which have changed.

To do this, we record the gadget spec in a manfiest file and compare it
with the current spec when in upgrade mode.

'Changed' in this case means that the gadget spec has changed from the
last time the installer was run. It does _not_ actually check the
presence of the gadget.
This commit is contained in:
Ben Jackson 2020-07-24 17:01:16 +01:00
commit f9d20b9537
5 changed files with 162 additions and 70 deletions

View file

@ -234,8 +234,7 @@ GADGETS = {
},
'macos': {
'file_name': 'netcoredbg-osx-master.tar.gz',
'checksum':
'c1dc6ed58c3f5b0473cfb4985a96552999360ceb9795e42d9c9be64af054f821',
'checksum': '',
},
'linux': {
'file_name': 'netcoredbg-linux-master.tar.gz',
@ -385,7 +384,7 @@ GADGETS = {
'enabled': False,
'repo': {
'url': 'https://github.com/microsoft/vscode-node-debug2',
'ref': 'v1.42.0',
'ref': 'v1.42.5'
},
'do': lambda name, root, gadget: installer.InstallNodeDebug( name,
root,