How to resolve VSIX packages of type 'Microsoft.VisualStudio.ProjectTemplate' cannot include .pkgdef files

27 Views Asked by At

I'm hoping someone can shed some light on this for I cannot find any documentation. I created a new VSIX using the empty VSIX community Toolkit template, it includes the project template I created. When I attempt to upload it to the marketplace , I get the following error;

VSIX packages of type 'Microsoft.VisualStudio.ProjectTemplate' cannot include .pkgdef files.

That .pkgdef file only contains the following;

[$RootKey$\RuntimeConfiguration\dependentAssembly\codeBase\{B3E7534D-F917-2ED9-388E-0CD39BA4B7E7}]
"name"="Community.VisualStudio.Toolkit"
"publicKeyToken"="79441d341a79572c"
"culture"="neutral"
"version"="17.0.430.0"
"codeBase"="$PackageFolder$\Community.VisualStudio.Toolkit.dll"

How do I resolve this in a way that the marketplace will let me upload my project template? I know what this is pointing to but don't understand how to resolve this so that the .pkgdef file is not generated and the reference to the nuget package is known/accepted.

2

There are 2 best solutions below

1
Ashok K On BEST ANSWER

I encountered a comparable error when uploading a *visx file to the Visual Studio Marketplace as a new visual studio extension. Following Alex's recommendation, I modified the false setting in the .csproj file, and this resolved the issue.

0
Alex Pearlstein On

The answer is it's in the .csproj file <GeneratePkgDefFile>false</GeneratePkgDefFile>