I am using typescript as a way of creating javascript for a webpage. My first attempt at using the tsc compiler produced error TS1005 about a missing ';'. This is apparently because Visual Studio Code is using an old version of tsc.
I find I have two versions on my system (discovered using where tsc in a command window):
C:\Program Files (x86)\Microsoft SDKs\TypeScript\1.0\tsc.exe
C:\Program Files (x86)\Microsoft SDKs\TypeScript\1.0\tsc.js
C:\Users\my_user_name\AppData\Roaming\npm\tsc
C:\Users\my_user_name\AppData\Roaming\npm\tsc.cmd
where the first location contains version 1.0.3.0 and the second version 2.7.2.
The only way I can get VS Code to use the latest version is to type the full path, ie
C:\Users\my_user_name\AppData\Roaming\npm\tsc main.ts
into the terminal window. When I do this there are no TS1005 errors.
I would be very grateful if someone could explain in easy terms for a VS Code novice how to set it up so it will automatically pick up the new version of tsc.
Grateful for advice.
I faced the same issue.
However, changing the folder name "C:\Program Files (x86)\Microsoft SDKs\TypeScript\1.0" to something else other than 1.0 (Example: 1.0.Original) worked for me.
Related
I am adding TFS to Visual Studio Code IDE(1.42.0) for that I have installed Azure Repos extension.
In VS code at File-->Preference-->Setting-->Tfvc:Location, when I am entering path C:\Program Files (x86)\Microsoft Visual Studio\2017\Professional\Common7\IDE\CommonExtensions\Microsoft\TeamFoundation\Team Explorer\tf.exe.
Getting error
(team) Unable to find the TF executable. Please ensure TF is installed
and the path specified contains the filename.
How can I solve this issue?
Edit 1: After installing Azure Repos extension, I am entering above path in tfvc:Location(for both tabs User and Workspace), but after entering path nothing happens. Check below screenshot
Edit2: Now I am getting this error at right below in VS code IDE
Since you have not got any help yet. I will take a shot. Any chance there is a issue with finding the executable and casing for the extension? My local TF is capitilized. \TF.exe
Also might want to checkout the Github and readme for TFVC.
Make sure you have installed VS on your computer. With a typical installation of Visual Studio, the Windows version of the TFVC command line client (tf.exe) is available under the Program Files (x86) folder. It will typically be placed in a location similar to C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\TF.exe. On the 2017 version of Visual Studio Community, it can be found in a location similar to C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\Common7\IDE\CommonExtensions\Microsoft\TeamFoundation\Team Explorer\TF.exe.
I found a .vscode folder in my project
delete it, close and reopen vscode solved the problem
[Windows 10] I have "Microsoft VS Code (User Setup)" installed in a custom directory and whenever I try to update it this shows up:
and then this
Log Info
Dec 23 11:42:40.673 INFO Starting: C:\Users\jeremy\AppData\Local\Programs\Microsoft VS Code\Code.exe, false
Dec 23 11:42:40.674 ERRO Bad arguments: Code path doesn't seem to exist: C:\Users\jeremy\AppData\Local\Programs\Microsoft VS Code\Code.exe
How do I change the path to point it to the right directory where "Code.exe" exists?
I had the same problem recently. I ended up reinstalling VS Code.
Do I lose my settings?
No. Note that I did not uninstall VS Code, I just downloaded the installer from the website and installed VSCode. This won't hurt, as it does not touch your settings and extensions.
What I tried
I first tried to visit the path mentioned in the error log, and I noticed that the folder _ within that directory contained the new VS Code version, downloaded by the updater.
So the path should have been C:\Users\myusername\AppData\Local\Programs\Microsoft VS Code\_\Code.exe instead, perhaps.
I tried to move all files from _ to their parent directory, and then, in VS Code, Help » Restart to update. This opened the new version of VS Code, but after closing it and starting it from the original install location (or through a shortcut I have always been using), the old version was still loaded. So apparently, this "trick" didn't work.
Then I tried to make a symbolic link to Code.exe within the _ directory, so the VS Code updater would find Code.exe. This caused roughly the same things to happen. So, this didn't work either.
At last, I decided to just download VS Code from their website, and simply install it. This seemed the most simple option to me.
Create a hard link for Code.exe using mklink, works for me.
Command should look like this (depends where your custom installation is, my in C:/Program Files/Microsoft VS Code/):
mklink /H "C:/Users/$username/AppData/Local/Programs/Microsoft VS Code/Code.exe" "C:/Program Files/Microsoft VS Code/Code.exe"
I´m trying to use Visual Studio Code, so I installed the current version (1.25.0). I open the project folder and VSC starts doing stuff with OmniSharp, producing the following error:
(Sorry, error is in german, saying that the file or assembly could not be found and that it can´t load the project file .csproj)
So, I checked the folder: the file is there and visual studio 2017 loads and builds the project as expected.
I´m new to VSC, so please tell me if I need to provide more information from some VSC logs or something.
I´d like to be able to open the project and work with VSC, so thank you in advance for your help.
From the comment
I am assuming you have installed this? C # Extenstion for VSCode and you are trying to open a dotnet core application and not a full framework project?
The best way to go about is uninstall C# extension and you will be fine to open the code in vs code again.
I have installed MatConvNet from VLFeat and I am trying to compile it. But as I am trying to run vl_compilenn it shows the following error:
vl_compilenn
Warning: CL.EXE not found in PATH. Trying to guess out of mex setup.
> In vl_compilenn>check_clpath (line 580)
In vl_compilenn (line 413)
'cl.exe' is not recognized as an internal or external command,
operable program or batch file.
Error using vl_compilenn>check_clpath (line 591)
Unable to find cl.exe
Error in vl_compilenn (line 413)
check_clpath(); % check whether cl.exe in path
install visual studio community edition ( it's the free edition ) (minwg compiler will not work)
go to C:\Program Files (x86)\Microsoft Visual Studio
search for cl.exe
take the one appropriate for your computer architecture and copy it to the folder containing the matconvnet installation
run mex -setup c++ and set it to visual studio
and you're good to go
I have added the directory with cl.exe to my system PATH variable (you need to restart Matlab after that operation) and the compilation succeeded. The check_clpath() function was unable to find proper location of cl.exe, because it was trying to find executable in directory which does not exsist:
cl_path =
'C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\bin\amd64'
after adding the cl.exe dir to PATH variable, in my case:
C:\Program Files (x86)\Microsoft Visual Studio\2017\Community\VC\Tools\MSVC\14.16.27023\bin\Hostx64\x64
the compilation succeeded.
Matlab accepts Professional Version of Visual Studio Compiler as I found out in one of the posts on MatLab forums.
The following is an easier solution,
addpath(fullfile('C:', 'Program Files (x86)', 'Microsoft Visual Studio', '2017', 'Professional', 'VC', 'Tools', 'MSVC', '14.16.27023', 'bin', 'Hostx64', 'x64'));
Matlab Post for reference:
https://se.mathworks.com/matlabcentral/answers/271382-mex-won-t-recognize-microsoft-visual-c-compilers
This worked for me
install community visual studio 2019 professional from
https://visualstudio.microsoft.com/es/downloads/
move to the directory where the installer placed visual studio. In my case
C:\Program Files (x86)\Microsoft Visual Studio\2019\Professional
locate the cl.exe appropriate to your host and target architecture (there are four combinations x86/x64). In my case x64/x64 resulted in
C:\Program Files (x86)\Microsoft Visual Studio\2019\Professional\VC\Tools\MSVC\14.27.29110\bin\Hostx64\x64
place the path in the environmental variable in your system
within matlab, move to CF2-master\external\matconvnet\matlab and execute vl_compilenn
Unfortunately MatConvNet does not support MinGW compiler in the current version. On Windows, you need to install Microsoft Visual Studio. Nowdays you can download the community edition for free, e.g. here.
One of the reasons why MatConvNet does not support MinGW is that on windows it uses the GDI+ library to speed up reading image files. You can try to compile it using:
vl_compilenn('EnableImreadJpeg', false)
cl.exe is a C++ compiler.
This message means that the program cannot find this file on your computer (either because it is actually not there, or because you did not indicate its location.)
If you actually have a C++ compiler and work with Windows, go to the properties of your PC -> advanced settings -> Environment Variables (Sorry if the names are not accurate, my computer is in French but should be something similar...).
Here you will have a field called PATH with most probably some paths already set. Modify it by adding the path of you C++ compiler (the folder containing cl.exe) and reboot your computer (your change is not taken into account otherwise).
I do not know how to do for other OS...
Otherwise, you need to download a C++ compiler. Visual Studio is free and has one.
As mentioned here I've tried to build the QGIS on Windows 7.
There are two methods one using Visual Studio Express Edition installer and the second one using MinGW.
I've found both of them broken and don't know what to do next
In building using Visual Studio
The link to visual studio actually installs the version 2010 but documentation assumes it version 2009. So "set VS90COMNTOOLS=%PROGRAMFILES%\Microsoft Visual Studio 9.0\Common7\Tools\" path is not found.
Also I'm confused about the context of this line:
If the path to bison and flex contains blanks, you need to use the
short name for the directory (i.e. C:\Program Files should be
rewritten to C:\Progra~n, where n is the number as shown in `dir /x
C:``).
In Building using MinGW 4.2.1. MSYS link is not found(404) but when I try to build step by step I find XDR 4.0 not found(404) in this page
So what's the way to build it?
All I want is to change the title and startup photo of QGIS Desktop software.
Using another application I'm now able to change the title of running QGIS but don't know where to change the photo which shows "Loading plugins...".
The build instructions for Windows 7 are a tad long in the tooth, but they work for the most part. I did not try MinGW.
I immediately changed the VS90COMNTOOLS path to point to the Visual Studio 2010 directory and it seemed to work for me:
set VS90COMNTOOLS=%PROGRAMFILES%\Microsoft Visual Studio 10.0\Common7\Tools\
Regarding bison and flex configuration, I used the latest version of CMake (3.3.1 as of now) and didn't encounter any warnings/errors pertaining to bison or flex. Are you encountering any right now? If not, you should be able to proceed.