Skip to content

Files

Latest commit

 

History

History
58 lines (36 loc) · 2.13 KB

development.md

File metadata and controls

58 lines (36 loc) · 2.13 KB

Development Instructions for the PowerShell Extension

Development Setup

You'll need to clone two repositories and set up your development environment to before you can proceed.

  1. Fork and clone the vscode-powershell repository

  2. Fork and clone the PowerShell Editor Services repository

  3. Follow the development instructions for PowerShell Editor Services. You will need to complete this step before proceeding.

  4. Install the latest Visual Studio Code Insiders release

    • You can also use the standard Visual Studio Code release. Both will work, but using VSCode Insiders means the extension can be developed ready for new features and changes in the next VSCode release.
  5. Install Node.js 8.x or higher.

Building the Code

From Visual Studio Code:

Press Ctrl+P and type task build

This will compile the TypeScript files in the project to JavaScript files.

From a PowerShell prompt:

Invoke-Build Build

Launching the extension

From Visual Studio Code:

To debug the extension, press F5. To run the extension without debugging, press Ctrl+F5 or Cmd+F5 on macOS.

From a command prompt:

code --extensionDevelopmentPath="c:\path\to\vscode-powershell" .

Building a "Preview" version

To build a preview version of the extension, that is to say, a version of the extension named "PowerShell Preview", You can simply change the name in the package.json to include -Preview at the end. When you build, this will:

  • Add a warning to the top of the README.md to warn users not to have the stable and preview version enabled at the same time
  • Adds "Preview" in a few places in the package.json

This mechanism is mostly used for releases.