Skip to content

bump version to 0.1.30 #40

bump version to 0.1.30

bump version to 0.1.30 #40

Workflow file for this run

name: Release Visual Studio Code packages
on:
push:
tags:
- v*
jobs:
test:
strategy:
fail-fast: false
matrix:
os: [ubuntu-latest, windows-latest, macos-latest]
uses: ./.github/workflows/test.yaml
with:
os: ${{ matrix.os }}
secrets: inherit
build:
runs-on: ${{ matrix.os }}
needs: test
strategy:
matrix:
# https://code.visualstudio.com/api/working-with-extensions/publishing-extension#platformspecific-extensions
# https://nodejs.org/api/process.html#processarch
# https://doc.rust-lang.org/nightly/rustc/platform-support.html
include:
- os: windows-latest
target: x86_64-pc-windows-msvc
vsce-target: win32-x64
npm-config-arch: x64
- os: windows-latest
target: aarch64-pc-windows-msvc
vsce-target: win32-arm64
npm-config-arch: arm64
- os: ubuntu-20.04
target: x86_64-unknown-linux-gnu
vsce-target: linux-x64
npm-config-arch: x64
- os: ubuntu-20.04
target: aarch64-unknown-linux-gnu
vsce-target: linux-arm64
npm-config-arch: arm64
- os: macos-11
target: x86_64-apple-darwin
vsce-target: darwin-x64
npm-config-arch: x64
- os: macos-11
target: aarch64-apple-darwin
vsce-target: darwin-arm64
npm-config-arch: arm64
steps:
- name: Checkout repo
uses: actions/checkout@v4
- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: 18
cache: yarn
- name: Install dependencies
env:
npm_config_arch: ${{ matrix.npm-config-arch }}
run: yarn install --frozen-lockfile
# Auto-downloads the platform specific language server
# (see https://github.com/ink-analyzer/ink-vscode/blob/master/setup.js).
- name: Build packages
env:
npm_config_arch: ${{ matrix.npm-config-arch }}
INK_ANALYZER_ARCH: ${{ matrix.npm-config-arch }}
INK_ANALYZER_SKIP_VERIFY: true
# Used by the setup script,
# otherwise we sometimes get hit by rate limits when determining the latest release from the GitHub API.
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: npx vsce package --yarn -o ink-analyzer-${{ matrix.vsce-target }}.vsix --target ${{ matrix.vsce-target }}
- name: Upload packages
uses: actions/upload-artifact@v4
with:
name: ink-analyzer-${{ matrix.vsce-target }}.vsix
path: ink-analyzer-${{ matrix.vsce-target }}.vsix
release:
runs-on: ubuntu-latest
needs: [test, build]
steps:
- name: Checkout repo
uses: actions/checkout@v4
- name: Setup Node
uses: actions/setup-node@v4
with:
node-version: 18
cache: yarn
- name: Install dependencies
env:
npm_config_arch: ${{ matrix.npm-config-arch }}
run: yarn install --frozen-lockfile
# Download Windows packages.
- uses: actions/download-artifact@v4
with:
name: ink-analyzer-win32-x64.vsix
path: dist
- uses: actions/download-artifact@v4
with:
name: ink-analyzer-win32-arm64.vsix
path: dist
# Download Linux packages.
- uses: actions/download-artifact@v4
with:
name: ink-analyzer-linux-x64.vsix
path: dist
- uses: actions/download-artifact@v4
with:
name: ink-analyzer-linux-arm64.vsix
path: dist
# Download macOS packages.
- uses: actions/download-artifact@v4
with:
name: ink-analyzer-darwin-x64.vsix
path: dist
- uses: actions/download-artifact@v4
with:
name: ink-analyzer-darwin-arm64.vsix
path: dist
# Prepare the release.
- name: List all downloaded packages
run: ls -la dist
- name: Extract release notes from the changelog
id: extract-release-notes
uses: ffurrer2/extract-release-notes@v2
with:
changelog_file: CHANGELOG.md
- name: Create a GitHub Release and upload all packages
env:
npm_config_arch: ${{ matrix.npm-config-arch }}
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: gh release create ${{ github.ref_name }} --title ${{ github.ref_name }} --notes '${{ steps.extract-release-notes.outputs.release_notes }}' dist/*
# Publish packages.
- name: Publish all packages to Visual Studio Code Marketplace
env:
VSCE_PAT: ${{ secrets.VSCE_PAT }}
INK_ANALYZER_SKIP_SETUP: true
run: npx vsce publish --yarn --packagePath $(find ./dist -iname ink-analyzer-*.vsix)