Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 23 additions & 0 deletions RELEASING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
## Pre-release

Pre-release builds are created automatically for each push to `main`. The builds have the same `major.minor.patch` version as the latest release, but with an additional pre-release identifier `-N`, where `N` is the number of pre-releases since the latest release. For example, if the latest release is `0.0.0` and there have been 5 pre-releases since then, the next pre-release build will be versioned `0.0.0-5`.

## Stable release

Stable releases are created by triggering the release pipeline: https://monacotools.visualstudio.com/Monaco/_build?definitionId=631
To create a stable release, you'll need to specify one of the following release types in the "Release Version" parameter:
- `prerelease`: for creating a pre-release build
- `patch`: for backward-compatible bug fixes
- `minor`: for backward-compatible new features
- `major`: for changes that break backward compatibility

Most of the time, you'll want to use `patch` or `minor`. For any of the above release types, the version number will be incremented automatically based on the latest stable release.

To create a stable release at a specific version, you can use `X.X.X` format (e.g., `1.2.3`). In this case, the version number will be set exactly as specified, regardless of the previous latest stable release.

## Releasing from other branches

To release from a branch other than `main`, you can choose the branch from the "Select pipeline version by branch/tag" dropdown when you run the pipeline.
Then, specify the desired release type as described above.

Releasing from other branches is useful for creating recovery releases and pre-releases for testing.
25 changes: 18 additions & 7 deletions build/pipeline.yml
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
name: $(Date:yyyyMMdd)$(Rev:.r)

trigger:
branches:
include:
Expand All @@ -15,10 +13,12 @@ resources:
endpoint: Monaco

parameters:
- name: publishPackage
displayName: 🚀 Publish codicons
type: boolean
default: false
- name: nextVersion
displayName: '🚀 Release Version (eg: none, major, minor, patch, prerelease, or X.X.X)'
type: string
default: 'none'

name: "$(Date:yyyyMMdd).$(Rev:r)${{ replace(format(' (🚀 {0})', parameters.nextVersion), ' (🚀 none)', '') }}"

extends:
template: azure-pipelines/npm-package/pipeline.yml@templates
Expand All @@ -33,4 +33,15 @@ extends:
- script: npm run build
displayName: Build npm package

publishPackage: ${{ parameters.publishPackage }}
${{ if or(eq(parameters.nextVersion, 'prerelease'), and(in(variables['Build.Reason'], 'IndividualCI', 'BatchedCI'), eq(variables['Build.SourceBranch'], 'refs/heads/main'))) }}:
publishPackage: true
publishRequiresApproval: false
nextVersion: prerelease
tag: next
${{ elseif eq(parameters.nextVersion, 'none') }}:
publishPackage: false
${{ else }}:
publishPackage: true
nextVersion: ${{ parameters.nextVersion }}
ghCreateRelease: true
ghReleaseAddChangeLog: true
4 changes: 2 additions & 2 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@vscode/codicons",
"version": "0.0.43",
"version": "0.0.0",
"fontVersion": "1.15",
"description": "The icon font for Visual Studio Code",
"license": "CC-BY-4.0",
Expand Down
Loading