Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
40 changes: 0 additions & 40 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -310,43 +310,6 @@ Press F5 to launch the Visual Studio Experimental Instance with your extension l

Extensions are only deployed to the Experimental Instance when building inside Visual Studio. This prevents errors when building from the command line.

### 📋 Publish Manifest Generation

The SDK automatically generates a `publish.manifest.json` file for publishing to the VS Marketplace. All values are extracted from your VSIX manifest:

```json
{
"$schema": "http://json.schemastore.org/vsix-publish",
"categories": [
"your", "tags", "here"
],
"identity": {
"internalName": "MyExtension"
},
"overview": "README.md",
"publisher": "Your Name",
"qna": true,
"repo": "https://github.com/you/your-repo"
}
```

| JSON Field | Source |
|------------|--------|
| `publisher` | `Identity/@Publisher` in VSIX manifest |
| `categories` | `Tags` element in VSIX manifest |
| `repo` | `MoreInfo` element in VSIX manifest |
| `internalName` | Project name |
| `overview` | Configurable via `VsixPublishOverview` property (default: `README.md`) |
| `qna` | Configurable via `VsixPublishQnA` property (default: `true`) |

To disable publish manifest generation:

```xml
<PropertyGroup>
<GeneratePublishManifest>false</GeneratePublishManifest>
</PropertyGroup>
```

## ⚙️ Configuration

### Properties
Expand All @@ -360,9 +323,6 @@ To disable publish manifest generation:
| `EnableDefaultVsixItems` | `true` | Auto-include VSIX-related files |
| `EmitCompilerGeneratedFiles` | `true` | Write generated source files to disk |
| `CompilerGeneratedFilesOutputPath` | `Generated/` | Location for generated source files |
| `GeneratePublishManifest` | `true` | Generate `publish.manifest.json` for VS Marketplace |
| `VsixPublishOverview` | `README.md` | Path to README for marketplace overview |
| `VsixPublishQnA` | `true` | Enable Q&A on marketplace listing |

> \* Only when `Configuration=Debug` AND building inside Visual Studio

Expand Down
1 change: 0 additions & 1 deletion samples/SampleExtension/SampleExtension.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@

<ItemGroup>
<PackageReference Include="Microsoft.VisualStudio.SDK" Version="17.*" />
<PackageReference Include="Microsoft.VSSDK.BuildTools" Version="17.*" PrivateAssets="all" />
</ItemGroup>

</Project>
13 changes: 0 additions & 13 deletions samples/SampleExtension/publish.manifest.json

This file was deleted.

19 changes: 0 additions & 19 deletions src/CodingWithCalvin.VsixSdk/Sdk/Sdk.Vsix.props
Original file line number Diff line number Diff line change
Expand Up @@ -99,25 +99,6 @@
<VsixVersion Condition="'$(VsixVersion)' == ''">1.0.0</VsixVersion>
</PropertyGroup>

<!--
Publish Manifest Configuration (publish.manifest.json)
Used for publishing to VS Marketplace
Most values are extracted from the VSIX manifest automatically:
- publisher: from Identity/@Publisher
- categories: from Tags element
- repo: from MoreInfo element
-->
<PropertyGroup>
<!-- Enable/disable publish manifest generation -->
<GeneratePublishManifest Condition="'$(GeneratePublishManifest)' == ''">true</GeneratePublishManifest>

<!-- Path to README for marketplace overview (relative to manifest) -->
<VsixPublishOverview Condition="'$(VsixPublishOverview)' == ''">README.md</VsixPublishOverview>

<!-- Enable Q&A on marketplace listing -->
<VsixPublishQnA Condition="'$(VsixPublishQnA)' == ''">true</VsixPublishQnA>
</PropertyGroup>

<!--
Deploy extension to experimental instance during build (for development)
Only deploy when building inside Visual Studio (not with dotnet build)
Expand Down
69 changes: 0 additions & 69 deletions src/CodingWithCalvin.VsixSdk/Sdk/Sdk.Vsix.targets
Original file line number Diff line number Diff line change
Expand Up @@ -122,75 +122,6 @@
<Delete Files="$(_VsixVersionSentinel)" />
</Target>

<!--
Generate Publish Manifest (publish.manifest.json)
Creates a VS Marketplace publish manifest from project properties and VSIX manifest
-->
<Target Name="GeneratePublishManifest"
AfterTargets="Build"
Condition="'$(GeneratePublishManifest)' == 'true' and '$(_SourceVsixManifestPath)' != '' and Exists('$(_SourceVsixManifestPath)')">

<PropertyGroup>
<_VsixNsForPeek>&lt;Namespace Prefix='vsix' Uri='http://schemas.microsoft.com/developer/vsx-schema/2011'/&gt;</_VsixNsForPeek>
</PropertyGroup>

<!-- Read Publisher from VSIX manifest -->
<XmlPeek XmlInputPath="$(_SourceVsixManifestPath)"
Query="/vsix:PackageManifest/vsix:Metadata/vsix:Identity/@Publisher"
Namespaces="$(_VsixNsForPeek)">
<Output TaskParameter="Result" PropertyName="_VsixPublisher" />
</XmlPeek>

<!-- Read MoreInfo (repo URL) from VSIX manifest -->
<XmlPeek XmlInputPath="$(_SourceVsixManifestPath)"
Query="/vsix:PackageManifest/vsix:Metadata/vsix:MoreInfo/text()"
Namespaces="$(_VsixNsForPeek)">
<Output TaskParameter="Result" PropertyName="_VsixMoreInfo" />
</XmlPeek>

<!-- Read Tags (categories) from VSIX manifest -->
<XmlPeek XmlInputPath="$(_SourceVsixManifestPath)"
Query="/vsix:PackageManifest/vsix:Metadata/vsix:Tags/text()"
Namespaces="$(_VsixNsForPeek)">
<Output TaskParameter="Result" PropertyName="_VsixTags" />
</XmlPeek>

<!-- Convert comma-separated tags to JSON array format -->
<PropertyGroup>
<!-- First trim spaces after commas, then replace commas with JSON array separators -->
<_VsixTagsNormalized>$(_VsixTags.Replace(', ', ','))</_VsixTagsNormalized>
<_CategoriesJson>$(_VsixTagsNormalized.Replace(',', '", "'))</_CategoriesJson>
<_CategoriesJson>"$(_CategoriesJson)"</_CategoriesJson>
<_QnAValue Condition="'$(VsixPublishQnA)' == 'true'">true</_QnAValue>
<_QnAValue Condition="'$(VsixPublishQnA)' != 'true'">false</_QnAValue>
<_RepoLine Condition="'$(_VsixMoreInfo)' != ''">,
"repo": "$(_VsixMoreInfo)"</_RepoLine>
<_RepoLine Condition="'$(_VsixMoreInfo)' == ''"></_RepoLine>
</PropertyGroup>

<!-- Write the publish manifest JSON -->
<PropertyGroup>
<_PublishManifestContent><![CDATA[{
"$schema": "http://json.schemastore.org/vsix-publish",
"categories": [
$(_CategoriesJson)
],
"identity": {
"internalName": "$(MSBuildProjectName)"
},
"overview": "$(VsixPublishOverview)",
"publisher": "$(_VsixPublisher)",
"qna": $(_QnAValue)$(_RepoLine)
}]]></_PublishManifestContent>
</PropertyGroup>

<WriteLinesToFile File="$(MSBuildProjectDirectory)\publish.manifest.json"
Lines="$(_PublishManifestContent)"
Overwrite="true" />

<Message Importance="high" Text="Generated publish manifest: $(MSBuildProjectDirectory)\publish.manifest.json" />
</Target>

<!--
Target to validate VSIX project configuration
Runs early in the build to catch common mistakes
Expand Down