Skip to content

Building the Extension

Robby Bennett edited this page Feb 19, 2024 · 12 revisions

Setup for Building

TLDR: Install npm

Install npm on Windows

winget install Node.js
echo Add "C:\Program Files\nodejs" to your path and restart your terminal program

Install npm on Ubuntu/Debian

sudo apt install nodejs

Building

Prepare for build

  1. Edit package.json by changing the version
  2. Edit CHANGELOG.md by adding an entry

Build the release

make

or

npm install
node node_modules/typescript/bin/tsc && node node_modules/@vscode/vsce/vsce package -o understand.vsix

Building results in a .vsix file which is basically JavaScript and a few other files archived, and the .zip file is renamed as .vsix.

Continuously build the debug version when source files change

make watch

or

npm run esbuild-watch