Skip to content

Latest commit

 

History

History
72 lines (44 loc) · 2.31 KB

CONTRIBUTING.md

File metadata and controls

72 lines (44 loc) · 2.31 KB

Contributing Guidelines

This document is a guide to help you through the process of contributing to the grafana-vs-code-extension.

Developing the extension

Create a fork

Fork, then clone the repository:

git clone [email protected]:{your_github_username}/grafana-vs-code-extension.git
cd grafana-vs-code-extension
git remote add upstream https://github.com/grafana/grafana-vs-code-extension.git
git fetch upstream

Install devbox

This repository relies on devbox to manage all the tools and dependencies needed for its development.

A shell including all the required tools is accessible via:

devbox shell

This shell can be exited like any other shell, with exit or CTRL+D.

One-off commands can be executed within the devbox shell as well:

devbox run node --version

Install dependencies

devbox run yarn install

Run the extension

Compile the extension, and keep watching for changes:

devbox run yarn watch

Open this repository in VS Code, then press F5 to start the extension locally.

Make changes

To make changes to this codebase, follow the instructions on running the extension. Then, in your original VS Code window, make changes to the code base.

Restart the extension with either CTRL + SHIFT + F5 (CMD + SHIFT + F5 on a Mac) or by clicking the green restart circle.

Debug logs and dev tools can be accessed with CTRL + SHIFT + I on the VS Code development host.

Releasing the extension

Releasing is a two step process:

  1. Prepare the release by updating the version number in package.json and describing what changed in the CHANGELOG.md file. See the release preparation commit for v0.0.19. Open a pull request for this commit, get it reviewed and merged.
  2. Trigger the release pipeline by creating and pushing a tag: git tag {version} && git push origin {version}

Note

The release pipeline creates and publishes a .vsix artifact to Open VSX, the Visual Studio Marketplace, as well as a GitHub release.