Skip to content

Commit

Permalink
update package.yml
Browse files Browse the repository at this point in the history
add open VSX registry publishing
  • Loading branch information
AdamRaichu authored Oct 19, 2023
1 parent 77d3f77 commit 3b8f95f
Show file tree
Hide file tree
Showing 2 changed files with 33 additions and 57 deletions.
53 changes: 0 additions & 53 deletions .github/workflows/build.yml

This file was deleted.

37 changes: 33 additions & 4 deletions .github/workflows/package.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,27 +6,56 @@ on:
type: boolean
required: true
default: false
continueOnTagErr:
type: boolean
required: false
default: false
workflow_call:
secrets:
AZURE_PAT:
required: true
description: The PAT to use to publish the extension.
inputs:
preRelease:
type: boolean
required: true
default: false
continueOnTagErr:
type: boolean
required: false
default: false
permissions:
contents: write
jobs:
build:
runs-on: windows-latest
steps:
- uses: actions/checkout@v3
name: Checkout repository
- uses: jozsefsallai/node-package-version@v1
name: Get package version as env variable
- name: Create a tag
- name: Configure git
run: |
git config user.name = "Github Actions"
git config user.email = "[email protected]"
git pull
- uses: jozsefsallai/[email protected]
name: get package version as env variable
- name: Create a tag
continue-on-error: ${{ inputs.continueOnTagErr }}
run: |
git tag -a v${{ env.PACKAGE_VERSION }} -m "Version ${{ env.PACKAGE_VERSION }}"
git push origin v${{ env.PACKAGE_VERSION }}
- name: Generate Files
run: |
npm i
npm run build
- name: Publish to Open VSX Registry
uses: HaaLeo/publish-vscode-extension@v1
id: publishToOpenVSX
with:
pat: ${{ secrets.OPEN_VSX_TOKEN }}
- name: Publish to Visual Studio Marketplace
uses: HaaLeo/publish-vscode-extension@v1
with:
pat: ${{ secrets.AZURE_PAT }}
registryUrl: https://marketplace.visualstudio.com
preRelease: ${{ inputs.preRelease }}
extensionFile: ${{ steps.publishToOpenVSX.outputs.vsixPath }}

0 comments on commit 3b8f95f

Please sign in to comment.