Skip to content

Latest commit

 

History

History
54 lines (36 loc) · 1.6 KB

DEVELOP.md

File metadata and controls

54 lines (36 loc) · 1.6 KB

Developer Guide

Below is a series of steps for developing and releasing the extension.

Development

  1. Install the recommended VSCode extensions (inside extensions.json).
  2. Install npm itself.
  3. Run npm.
  4. In VSCode, hit F5.

When code is changed, you'll need to refresh with > Reload Window. Until then, any code changes are not reflected in the development window.

Try sample

  1. Prepare database.
cd $THIS_REPOSITORY_ROOT

# Prepare database.
docker-compose up -d
./sample/prepare.sh
  1. Open the sample workspace ($THIS_REPOSITORY_ROOT/sample/sample.code-workspace) on [Extension Development Host] window.

Test

cd $THIS_REPOSITORY_ROOT

# Prepare database.
docker-compose up -d
./sample/prepare.sh

# Install packages.
npm install

# Run test.
npm run test

Release

⚠️ Since libpg-query is a native node module, separate Linux and MacOS installations are required. In Windows, cannot build libpg-query, so it is excluded from the release target.

⚠️ The current strategy is to use a Mac when compiling a build for MacOS.

  1. Update the version number in package.json.
  2. Install with npm install.
  3. Execute npm run package:linux to produce vscode-plpgsql-lsp-#.#.#.vsix. (For MacOS, npm run package:mac.)
  4. Log into VSCode Marketplace (Unique Vision users only at this time).
  5. Under PL/pgSQL Language Server, select More Actions, then Update and upload the .vsix file.