[AC-6518] Changed the selected visual studio version if multiple version installed on machine
GitHub Issue | n/a |
---|---|
Type | Bug |
Priority | n/a |
Status | Open |
Resolution | Unresolved |
Affected Version/s | Appcelerator Studio 4.3.0 |
Fix Version/s | n/a |
Components | Studio |
Labels | n/a |
Reporter | shishir.roy |
Assignee | Abir Mukherjee |
Created | 2020-04-02T17:07:32.000+0000 |
Updated | 2020-04-03T13:30:56.000+0000 |
Description
I have installed visual studio 2017 and 2019 on same machine. And I wanted to run windows app from the Appcelerator studio. But it is failed to build.
[ERROR] : Failed to run command "build"
[ERROR] : TypeError: Cannot read property 'cyan' of undefined
As per my understanding, it will only build with vs 2017. But by default, it is selecting vs 2019 which assuming the problem.
I have checked the environment setting:
Microsoft (R) Visual Studio
Visual Studio Enterprise 2017
Path = C:\Program Files (x86)\Microsoft Visual Studio\2017\Enterprise
CLR Version = null
MSBuild Version = v15.9.28307.1064
Windows Phone SDKs = not installed
Visual Studio Enterprise 2019 (selected)
Path = D:\vs2019
CLR Version = null
MSBuild Version = v16.5.29926.136
Windows Phone SDKs = not installed
Please tell how to changed to vs 2017 in Appcelerator studio for building Windows app
if above is not a problem, then please suggest how to fix the build error.
[~shishir.roy] Please see the Titanium CLI options document https://docs.appcelerator.com/platform/latest/#!/guide/Titanium_CLI_Options, you should be able to set the selected visual studio version using to
appc ti config windows.visualstudio.selectedVersion "Visual Studio Enterprise 2017"
Note that there is a
-V
command line flag/option to specify the Visual Studio Target if you want to select/target it on a per command basis rather than setting the config value to effectively change the default.