VS Code Extension Manager https://github.com/microsoft/vscode-vsce
Find a file
2015-10-07 12:32:44 +02:00
resources first steps 2015-09-17 21:53:03 +02:00
src unpublish 2015-10-07 12:32:44 +02:00
test ignore dev dependencies 2015-09-29 17:34:53 +02:00
typings unpublish 2015-10-07 12:32:44 +02:00
.gitignore add .gitignore 2015-09-17 21:48:11 +02:00
.npmignore add npmignore 2015-10-07 11:37:44 +02:00
gulpfile.babel.js package command, help output 2015-09-17 22:54:04 +02:00
jsconfig.json first steps 2015-09-17 21:53:03 +02:00
package.json rename to vsce 2015-10-07 11:35:45 +02:00
README.md Update README.md 2015-10-07 12:00:22 +02:00
tsconfig.json first steps 2015-09-17 21:53:03 +02:00
tsd.json publish: first steps 2015-09-18 11:25:48 +02:00

VSCode Extension Manager

This tool assists in publishing Visual Studio Code extensions.

npm install -g vsce

Manifest files

Every Visual Studio Code extension needs a manifest file: package.json. Make sure it has at least the following fields:

  • name
  • version
  • publisher
  • engines.vscode

Example:

{
	"name": "uuid",
	"version": "0.0.1",
	"publisher": "joaomoreno",
	"engines": {
		"vscode": "*"
	}
}

Publishing

Before publishing it is good practice to list the files that will be included in your extension's package:

$ vsce ls
hello.js
package.json

If that looks good, you can now publish your extension:

$ vsce publish
Publishing uuid@0.0.1...
Successfully published uuid@0.0.1!

The extension should now appear in the gallery.

Configuration

.vsceignore

You can create a .vsceignore file to exclude some files from being included in your extension's package. This file is a collection of glob patterns, one per line. For example:

**/*.ts
**/tsconfig.json
!file.ts

Pre-publish step

It's possible to add a pre-publish step to your manifest file. The command will be called everytime the extension is packaged.

{
	"name": "uuid",
	"version": "0.0.1",
	"publisher": "joaomoreno",
	"engines": {
		"vscode": "*"
	},
	"scripts": {
		"vscode:prepublish": "tsc"
	}
}

This will always invoke the TypeScript compiler whenever the extension is packaged.