Skip to content

Merge pull request #1437 from tgodzik/add-21 #499

Merge pull request #1437 from tgodzik/add-21

Merge pull request #1437 from tgodzik/add-21 #499

Workflow file for this run

name: Pre-release
on:
push:
branches:
- main
jobs:
pre-release:
if: |
github.event.author.email != '[email protected]' &&
!contains(github.event.head_commit.message, 'scalameta/dependabot/') &&
!contains(github.event.head_commit.message, 'dependabot[bot]') &&
!contains(github.event.head_commit.message, '[skip pre]') &&
!contains(github.event.head_commit.message, '[skip-pre]')
runs-on: ubuntu-latest
steps:
- uses: actions/setup-node@v2
with:
node-version: "16"
- uses: actions/checkout@v2
- name: Setup git env
run: |
git config --global user.email "[email protected]"
git config --global user.name "Scalameta bot"
- run: |
cd packages/metals-vscode
yarn install
yarn version --no-git-tag-version --patch
- name: Commit changes
run: |
git add .
git commit -m "Increase patch version for pre-release"
# Pre release version requires vscode ^1.63
# but we don't want to force normal users to update, modify it
- name: Update required vs code version
run: |
cd packages/metals-languageclient
yarn install && yarn build
cd ../metals-vscode
node ./update-version.js
yarn install
- name: Publish pre-release version to Visual Studio Marketplace
uses: HaaLeo/publish-vscode-extension@v1
with:
pat: ${{ secrets.VS_MARKETPLACE_TOKEN }}
registryUrl: https://marketplace.visualstudio.com
preRelease: true
yarn: true
packagePath: "./packages/metals-vscode"
# Don't publish for VSX, it doesn't support pre-release versions
# Push changes - increased patch version
- name: Push changes
run: git push origin HEAD:main