D21589: Duplicate Visual Studio 2017 hack for VS 2019

Petros Siligkounas noreply at phabricator.kde.org
Fri Jun 5 19:59:21 BST 2020


Petross404 added a comment.


  Hi,
  
  I have installed Build Tools for VS2019 and the installation is at
  
    C:\Program Files (x86)\Microsoft Visual Studio\2019\BuildTools
  
  I found this string inside HKEY_LOCAL_MACHINE\SOFTWARE\WOW6432Node\Microsoft\Windows\CurrentVersion\Uninstall\1eb19443 which honestly doesn't seem the proper key to extract this value but anyway.
  
  A small preview of what I wrote is this:
  
    @echo off
    
    setlocal enabledelayedexpansion
    setlocal enableextensions
    
    REM Visual Studio 2019 is tricky to be found.
    set VS2019_KEY_NAME="HKEY_LOCAL_MACHINE\SOFTWARE\WOW6432Node\Microsoft\Windows\CurrentVersion\Uninstall\1eb19443"
    set VS2019_VAL_NAME="InstallLocation"
    for /f "usebackq skip=2 tokens=3*" %%a in (`^(reg query %VS2019_KEY_NAME% /v %VS2019_VAL_NAME% ^| find "%VS2019_VAL_NAME%"^) 2^>nul `) do (
    	set vs16_path=%%b
    	if exist "!vs16_path!Common7\Tools\LaunchDevCmd.bat" (
    		set "VS160COMNTOOLS=!vs15_path!Common7\Tools\"
    		goto :end
    	)
    )
  
  No matter what I try I get the error "ERROR: The system was unable to find the specified registry key or value." Any ideas?

REPOSITORY
  R32 KDevelop

REVISION DETAIL
  https://phabricator.kde.org/D21589

To: sredman, #kdevelop
Cc: kossebau, Petross404, apol, kfunk, brauch, kdevelop-devel, hmitonneau, christiant, glebaccon, domson, antismap, iodelay, alexeymin, geetamc, Pilzschaf, akshaydeo, surgenight, arrowd
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/kdevelop-devel/attachments/20200605/41577fcb/attachment.htm>


More information about the KDevelop-devel mailing list