Fix VC runtime detection (detect additional GUID's)

This commit is contained in:
2019-10-15 14:33:15 -05:00
parent f751f673a0
commit 655e5abee4
4 changed files with 58 additions and 48 deletions

View File

@@ -1,5 +1,8 @@
# Changelog # Changelog
## 1.0.10 (Windows only)
* Fix VC runtime detection (detect additional GUID's)
## 1.0.8 ## 1.0.8
* \#8: Add tooltips to settings * \#8: Add tooltips to settings
* \#36: Add ability to select Linux distribution type if OS is unsupported * \#36: Add ability to select Linux distribution type if OS is unsupported

View File

@@ -1,6 +1,6 @@
{ {
"name": "repertory-ui", "name": "repertory-ui",
"version": "1.0.8", "version": "1.0.10",
"private": true, "private": true,
"author": "scott.e.graves@protonmail.com", "author": "scott.e.graves@protonmail.com",
"description": "GUI for Repertory - Repertory allows you to mount Sia and/or SiaPrime blockchain storage solutions via FUSE on Linux/OS X or via WinFSP on Windows.", "description": "GUI for Repertory - Repertory allows you to mount Sia and/or SiaPrime blockchain storage solutions via FUSE on Linux/OS X or via WinFSP on Windows.",

View File

@@ -151,13 +151,10 @@
} }
}, },
"win32": { "win32": {
"1.0.8": { "1.0.10": {
"sha256": "1dcf2ca95ee9ce1893166e7966e4aaa465735d00476d99414c57d18e7232212f", "sha256": "",
"sig": "AzXf0WkuGx4lXoGPgxsj2LDCAHwotKnvZHBFZv1f2A77sNtJaDQAgS3b4Hjg0AiWCRL9HzjJNprBv5lEUwc7AeRLXuj+4AI6Z7PeRaVs2NBgEHlIqldPwjime8bE2NBrkKfdDDdiAzhm3AqxgRzwhZ4sxkb3vNDdKIj4WnH79LsVCEcBgtuWalNvt3Q0i5ppBvu6+Iy/gZuGa7z+Jv2WU+Ijm7WjkmmmTdpcvP1UQTBL2UkriYOxVMIfrjHM0b2ch6RGBKUxS2h26h0xmJ7SzFoZ6lHcHDIxi8fsi7DIO/QDpottJPVgZLRuufSTyXLCbehLRI3dd1IWhQns0OTU11MBAUTRczJTaZ8nrjMesKdwbWqDDGMWOHyl39EuGIaGm3Mbi4iQWI3gz4RmX9kIWf0OSaT73okPvfjWA2Onn8IOs57TDw5fIyKKFjMkxqAPy0O+WonjJ5bd4Q/8HUpVx9M9NoClbztMQUhom2hVPkPiD3jQ8I9YcrmD9phZYkMf5As1G6RBsITsbpRA0bu9426y6K+nNJLPAM0TrW33oOziYV2z5HD1/Z+TsUMcusAPTbatjPLyLZ9kWIUqybPga8iPZW9iqszei2ywKl3EgAP/rZx2fn3qko9PvdpsoV6VBp9FxT2mguoRnkIo3lPGYXssBlfVBz0treGyjDoqcOrtciVLJbal54FTPU5o+Acuffi0Ft2F4qW7d3VglhEeA2i4zzPH2l8R0CuStei8ePMhOpebtByTPrclkvlbcOCg5adF+3/zTH9H261+P/IyrPct1ucvVpa6FlpcKfErWttRmxc9QhqiepyPUonLkHgB4Ur/ft6PzlE/+wD6arA7avSKdZqzeSksFSdnX/41fD8gL5CHfsCdbeqPvPd97CliiMCeGjVngQ5qFbC1+5DHuDopvs0yWcmDAO+nFrcQt3K01VjDYT+5plb263Ba3HKHqkT9N2gH8yWK/DdfT4Y8WAABomcgPeRSg6lAtNFv5RtWbSq9Q4dLFuhGM55EtXPG15zYAZqePCcyWYieP0wNuszcSsVNDScU8gqilwtn1oKO0ISZSYZUbdzI3fDc6SbaJNLwYdT/AlELZy0fAKILmJJN8MUXvcC7we6zyPOqwEf1ESLOb84Zw3+gPtH+Ao9dWHKdHOlyNyRzPvTYrcqSn2Uf3iHOLeoazqEEJ5Bh7jbDgVBkB4XEwijb+BvFV3cBcLdSg1Id3zZF02jkpaN4SMbEmqPbUv393CKRNs47p6ffFKKS5oUEpF6GpZq/wtjmKkdMSIzGVurbHPIaZI8JfLrEu/GAxAMGM7G3O5AiKOf0AH0wexhP5Vh6iE3MLNMA7n8SEQL5i/YUIL6b0tDL/wc=", "sig": "",
"urls": [ "urls": []
"https://pixeldrain.com/api/file/u_pP3IAk",
"https://bitbucket.org/blockstorage/repertory-ui/downloads/repertory-ui_1.0.8_win.exe"
]
} }
} }
}, },
@@ -214,7 +211,7 @@
"unavailable" "unavailable"
], ],
"win32": [ "win32": [
"1.0.8" "1.0.10"
] ]
} }
} }

View File

@@ -462,9 +462,13 @@ module.exports.getMissingDependencies = dependencies => {
}; };
const Registry = require('winreg'); const Registry = require('winreg');
for (const dep of dependencies) { const checkRegistry = (dep, index) => {
if (index >= dep.registry.length) {
missing.push(dep);
resolveIfComplete();
} else {
let hive = null; let hive = null;
const hiveName = dep.registry[0].split('\\')[0]; const hiveName = dep.registry[index].split('\\')[0];
switch (hiveName) { switch (hiveName) {
case 'HKEY_CLASSES_ROOT': case 'HKEY_CLASSES_ROOT':
hive = Registry.HKCR; hive = Registry.HKCR;
@@ -485,7 +489,7 @@ module.exports.getMissingDependencies = dependencies => {
throw Error('Invalid registry hive: ' + hiveName); throw Error('Invalid registry hive: ' + hiveName);
} }
const key = dep.registry[0].substr(hiveName.length); const key = dep.registry[index].substr(hiveName.length);
const regKey = new Registry({ const regKey = new Registry({
hive: hive, hive: hive,
key: key key: key
@@ -494,15 +498,21 @@ module.exports.getMissingDependencies = dependencies => {
if (err || !exists) { if (err || !exists) {
regKey.valueExists('ProductName', (err, exists) => { regKey.valueExists('ProductName', (err, exists) => {
if (err || !exists) { if (err || !exists) {
missing.push(dep); checkRegistry(dep, ++index);
} } else {
resolveIfComplete(); resolveIfComplete();
}
}); });
} else { } else {
resolveIfComplete(); resolveIfComplete();
} }
}); });
} }
};
for (const dependency of dependencies) {
checkRegistry(dependency,0);
}
} else { } else {
for (const dep of dependencies) { for (const dep of dependencies) {
try { try {