Encountered an error while publishing the vscode extension - visual-studio-code

When publishing your own vscode extension, it prompts "This extension targets Visual Studio 2017 but was not built with an up-to-date VSSDK. Please make sure to update your references and try uploading again. Note: you'll also need to add Prerequisites to your extension.vsixmanifest. ”
I updated all the dependencies and generator-code, but still reported the same error

problem solved! Edited extensions are divided into Visual Studio Code, Visual Studio and Azure Devops. When publishing my extension, I chose to publish the extension of Visual Studio, but my custom extension works on Visual Studio Code!!!
So the solution to the problem is obvious: choose the corresponding editor type when publishing the extension. Here I publish Visual Studio Code and choose her to publish.

Related

Trying to build My UE5 C++ Project in Visual Studio Code - it doesn't build in Visual Studio Code but builds in Visual Studio 2019 and UE Live Code

The project I'm working on in Visual Studio Code builds fine when you use the Live Code from The Unreal Editor but if you try to build from Visual Studio you get this in the terminal...
'C:\Program' is not recognized as an internal or external command,
operable program or batch file.
I'm assuming it is choking on the space in C:\Program Files (however that is a standard space in that Windows created directory so I can't change it without breaking links for countless other files in that directory). As well when you build from Unreal it doesn't choke on that space - so I'm wondering if anyone knows how to "ignore" the spaces. And since Visual Studio 2019 has no issues building that project - it must have some setting that is also ignoring the spaces. Thanks in advance.
(it doesn't seem to fail - it just seems to soft lock? the "thinking spinner" just keeps spinning and it never seems to complete the build task).
I brought the same project into Visual Studio 2019 and it builds fine, however I can't get Unreal's Live Code to link with 2019 so I'm just trying to get this working in Visual Studio Code since Live Code works great with it.

Build installer projects from visual studio 2022 command line

Recently I upgraded a project to Visual Studio 2022. I am using command line to build the installer project (.vdproj) using the command something shown below
devenv.com <Solutionfile> /build <InstallerConfiguration>.
The command used to build file with VS 2019 but when trying to build the same with Visual Studio 2022 seems to be stuck. It seems that everything builds fine but the Visual Studio process does not exit after the project is built and causes the build pipeline to be stalled. I have disabled out of proc build to see if this was causing the issue but it does not help. Any one experience the same issue? I am using the most recent version of visual studio along with the Visual Studio installer project extension. Any other method of building the installer project? I have tried MSBuild command but it does not understand vdproj files.
This has been fixed with the latest release of VS 2022 17.3.6. Works fine for me now.

Ballerina with Visual Studio Code

I am struggling to get Ballerina working with Visual Studio Code (on Windows 10).
It is installed and works fine from Command Prompt, however it cannot complete build command in Visual Studio Code. It does not seem to be able to finish build command effected via Visual Studio Code. I have Ballerina extension for Visual Studio Code installed.
Does anybody had similar problems and know how to overcome it?
Bellow please find details of versions:
Ballerina 1.2.1
Language specification 2020R1
Ballerina tool 0.8.5
VSC:
1.44.2
Ballerina extension for Visual Studio Code
Windows:
10 Pro
Version 10.0.18362
#GregorSind, try quitting the VSCode instance and then reopen. This might be that the environment variables are not being visible to the VSCode instance. Also, check what's the integrated shell of VSCode

"No extensions found" when running Visual Studio Code from source

When I try to install any extension in Visual Studio Code (i.e., by pressing Ctrl+P and then running ext install RustyCode), I get a message that No extensions found.
However, this only happens when I run VS Code directly from source repository. I.e., after:
git clone https://github.com/Microsoft/vscode.git
cd vscode
git checkout 1.0.0
scripts/code.sh
But, if I run VS Code from official builds, then I'm able to install extensions.
So, how can I enable downloading and installing extensions from Visual Studio Marketplace when I run VS Code directly from source repository? (Is Visual Studio Marketplace integration bundled separately in official builds?)
I'm on Ubuntu/Linux.
This can be fixed by adding following to product.json:
"extensionsGallery": {
"serviceUrl": "https://marketplace.visualstudio.com/_apis/public/gallery",
"cacheUrl": "https://vscode.blob.core.windows.net/gallery/index",
"itemUrl": "https://marketplace.visualstudio.com/items"
}
(This is can also be fixed by copying product.json from an official build (in the .zip archvie, product.json is under resources/app) which contains above lines).
More information: https://github.com/Microsoft/vscode/issues/1557
You can use code-marketplace extension in AUR to add microsoft marketplace registery in code OSS. This extension will installs a pacman hook that patches the file on every package update.
If you want to do the same for archlinux, have a look here => https://wiki.archlinux.org/index.php/Visual_Studio_Code , you have various possible options to solve the problem.
For Arch linux you could access the product.json file under this path - /usr/lib/code/product.json.
Just edit on the file the extensionsGallery with the following-
"extensionsGallery": {
"serviceUrl": "https://marketplace.visualstudio.com/_apis/public/gallery",
"cacheUrl": "https://vscode.blob.core.windows.net/gallery/index",
"itemUrl": "https://marketplace.visualstudio.com/items"
}
like #Vikrant Chaudhary said.
Extending the answer from #Vikrant Chaudhary. If anyone wanted to do the same thing on Windows, the path to product.json is here:
Windows path for VSCodium: C:\Program Files\VSCodium\resources\app\product.json

Visual Studio TFS Plugin - How to register page?

I would like to develop a TFS plugin that displays a simple page in the Team Explorer. To do this, I loosely followed this project. I'm able to register a menu command, but when the command is invoked my page that I derive from TeamExplorerPageBase is unknown to the Team Explorer. The code to load the page is:
var teamExplorer = (ITeamExplorer)(this.ServiceProvider.GetService(typeof(ITeamExplorer)));
teamExplorer.NavigateToPage(new Guid(BiscomTfsLabelPage.Id), null);
the call to NavigateToPage returns an error:
So how do I register the page with Team Explorer??
UPDATE:
Looks like it's an issue with the debugger, because when I run the VSIX file that gets output by the build, then open a new instance of Visual Studio it works:
So now I'd really like to know if there's a way that I can debug the extension, since it doesn't seem to register the page if I use the debugger.
Since it works in a new instance of Visual Studio. You could try to debug it with a new opened Visual Studio.
Go to the properties of your project and look under the debug tab, find a Start Action. Select to "Start external program" and browse to where you have visual studio installed. C:\Program Files (x86)\Microsoft Visual Studio 14.0\Common7\IDE\devenv.exe