Releasing new versions

This document describes how to release a new version of Some Sass.

A new release typically involves two assets:

Conventional Commits

We use nx to version and tag the language service module based on conventional commits.

nx reads the commit messages to determine what the new version should be, and to generate changelogs. Which version is released depends on how you write the commit message.

Commit messageRelease type
docs: add guide for configuring sublimeNo new release.
fix: update css-languageservicePatch. Bugfix release, updates for runtime dependencies.
feat: add support for show keyword in fo÷rwardMinor. New feature release.
refactor: remove reduntant options for latest language version

BREAKING CHANGE: The scanImportedFiles option has been removed.
Major. Breaking release, like removing an option or changing engines version.
(Note that the BREAKING CHANGE: token must be in the footer of the commit)

Release process

To start a new release, run node .scripts/release.mjs. This script:

  1. Gets the latest main branch with git checkout main && git pull.
  2. Runs npm clean-install.
  3. Runs npm run release which updates versions, generates changelogs and Git tags.
  4. Pushes the changes and tags with git push && git push --tags.

GitHub Actions does the actual publishing when there are new tags.

The script continues to:

  1. Update the dependency on the server in vscode-extension/package.json.
  2. Bump the version number of the extension.
  3. Run npm install to update the lockfile.
  4. Commit the changes and run git tag some-sass@<version from package.json>.
  5. Run git push && git push --tags.

Again, GitHub Actions is does the actual publishing when there are new tags.

Manual release process

In case npm run release fails, or GitHub Actions can't publish, here's how you can release manually (provided you have access).

To prepare the repository:

git checkout main
git pull
npm clean-install
npm run build
npm run test:all

Then, in packages/language-server:

# run npm version first if nx failed
npm publish

In vscode-extension/:

vsce package

Then log in to and publish manually via Visual Studio Marketplace, Open VSX and GitHub Releases (attach the .vsix file to the release).

References: