You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
docs: refresh README with emojis and reorganized sections
- Add emojis to all section headers for visual appeal
- Reorganize 'Migrating from Legacy Projects' before 'Manual Setup'
- Add bullet emojis for feature highlights
- Improve overall readability
An MSBuild SDK that brings modern SDK-style `.csproj` files to Visual Studio extension development. No more XML soup!
6
+
An MSBuild SDK that brings modern SDK-style `.csproj` files to Visual Studio extension development. No more XML soup! 🎉
7
7
8
-
## Why This Exists
8
+
## 💡 Why This Exists
9
9
10
10
Visual Studio extension projects are stuck in the past. They still use the old, verbose project format while the rest of .NET has moved on to clean SDK-style projects.
11
11
12
12
**This SDK fixes that.**
13
13
14
-
Write clean `.csproj` files. Get source generators for compile-time constants. Ship fully functional VSIX packages.
14
+
✨ Write clean `.csproj` files
15
+
✨ Get source generators for compile-time constants
16
+
✨ Ship fully functional VSIX packages
15
17
16
-
## Getting Started
18
+
## 🚀 Getting Started
17
19
18
-
### Using the Template (Recommended)
20
+
### 📦 Using the Template (Recommended)
19
21
20
22
The easiest way to create a new VSIX project is with the dotnet template:
21
23
@@ -57,7 +59,117 @@ dotnet new vsix -n MyExtension \
57
59
--tags "productivity, tools, editor"
58
60
```
59
61
60
-
### Manual Setup
62
+
### 🔄 Migrating from Legacy Projects
63
+
64
+
Have an existing non-SDK style VSIX project? Here's how to modernize it:
65
+
66
+
#### Step 1: Back Up Your Project
67
+
68
+
Before making changes, ensure your project is committed to source control or backed up.
69
+
70
+
#### Step 2: Replace the .csproj Content
71
+
72
+
Replace your entire `.csproj` file with the SDK-style format:
If you have `.vsct` files, they're automatically included. Remove any explicit `<VSCTCompile>` items unless you need custom metadata.
149
+
150
+
#### Step 7: Build and Test
151
+
152
+
```bash
153
+
dotnet build
154
+
```
155
+
156
+
Fix any errors that arise. Common issues:
157
+
- ❌ **Missing types**: Add the appropriate `PackageReference`
158
+
- ❌ **Duplicate files**: Remove explicit includes that conflict with auto-inclusion
159
+
- ❌ **Resource files**: Ensure `VSPackage.resx` files are in the project
160
+
161
+
#### ✅ Migration Checklist
162
+
163
+
-[ ] Replaced `.csproj` with SDK-style format
164
+
-[ ] Added `<ProductArchitecture>amd64</ProductArchitecture>` to manifest
165
+
-[ ] Converted `packages.config` to `PackageReference`
166
+
-[ ] Removed `Properties/AssemblyInfo.cs`
167
+
-[ ] Removed explicit file includes (now auto-included)
168
+
-[ ] Updated version range to `[17.0, 19.0)` for VS 2022+
169
+
-[ ] Build succeeds with `dotnet build`
170
+
-[ ] F5 debugging works in Visual Studio
171
+
172
+
### 🛠️ Manual Setup
61
173
62
174
If you prefer to set up manually, create a `.csproj` file:
63
175
@@ -104,9 +216,9 @@ Then create `source.extension.vsixmanifest`:
104
216
</PackageManifest>
105
217
```
106
218
107
-
## Features
219
+
## ✨ Features
108
220
109
-
### Source Generators
221
+
### 🔮 Source Generators
110
222
111
223
The SDK includes source generators that create compile-time constants from your manifest files.
112
224
@@ -159,11 +271,11 @@ public static class MyCommandsVsct
159
271
}
160
272
```
161
273
162
-
#### Generated Files Location
274
+
#### 📁 Generated Files Location
163
275
164
276
Generated source files are written to the `Generated/` folder in your project and are visible in Solution Explorer. They're marked as auto-generated so you know not to edit them directly.
165
277
166
-
### Version Override
278
+
### 🏷️ Version Override
167
279
168
280
Update the VSIX version at build time without manually editing the manifest:
This updates the `source.extension.vsixmanifest` file with the new version, rebuilds with the correct version in all outputs (including the generated `VsixInfo.Version` constant), and produces the VSIX with the specified version.
- `source.extension.vsixmanifest`as an `AdditionalFile` for source generators
300
+
- 📄 `*.vsct` files as `VSCTCompile` items
301
+
- 📄 `VSPackage.resx` files with proper metadata
302
+
- 📄 `source.extension.vsixmanifest` as an `AdditionalFile` for source generators
191
303
192
-
### F5 Debugging
304
+
### 🐛 F5 Debugging
193
305
194
306
Press F5 to launch the Visual Studio Experimental Instance with your extension loaded. This works automatically when:
195
307
- Building in Debug configuration
196
308
- Building inside Visual Studio (not `dotnet build`)
197
309
198
-
### Smart Deployment
310
+
### 🚀 Smart Deployment
199
311
200
312
Extensions are only deployed to the Experimental Instance when building inside Visual Studio. This prevents errors when building from the command line.
201
313
202
-
### Publish Manifest Generation
314
+
### 📋 Publish Manifest Generation
203
315
204
316
The SDK automatically generates a `publish.manifest.json` file for publishing to the VS Marketplace. All values are extracted from your VSIX manifest:
205
317
@@ -236,7 +348,7 @@ To disable publish manifest generation:
236
348
</PropertyGroup>
237
349
```
238
350
239
-
## Configuration
351
+
## ⚙️ Configuration
240
352
241
353
### Properties
242
354
@@ -282,122 +394,12 @@ Or disable specific categories:
282
394
</PropertyGroup>
283
395
```
284
396
285
-
## Migrating from Legacy Projects
286
-
287
-
If you have an existing non-SDK style VSIX project, follow these steps to convert it.
288
-
289
-
### Step 1: Back Up Your Project
290
-
291
-
Before making changes, ensure your project is committed to source control or backed up.
292
-
293
-
### Step 2: Replace the .csproj Content
294
-
295
-
Replace your entire `.csproj` file with the SDK-style format:
0 commit comments