1.1.4 #52
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
on: | |
push: | |
tags: | |
- "dryrun/[0-9]+.[0-9]+.[0-9]+" | |
- "release/[0-9]+.[0-9]+.[0-9]+" | |
name: Deploy Extension | |
jobs: | |
deploy: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Check for DryRun | |
id: releaseMode | |
# perform secret check & put boolean result as an output | |
shell: bash | |
run: | | |
if [[ "${{ github.ref }}" = "refs/tags/dryrun"* ]]; then | |
echo "dryRun=true" >> $GITHUB_OUTPUT; | |
else | |
echo "dryRun=false" >> $GITHUB_OUTPUT; | |
fi | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-node@v3 | |
- run: npm ci | |
- name: Publish to Open VSX Registry | |
if: success() || failure() | |
uses: HaaLeo/publish-vscode-extension@v1 | |
id: publishToOpenVSX | |
with: | |
dryRun: ${{ steps.releaseMode.outputs.dryRun }} | |
pat: ${{ secrets.OPEN_VSX_TOKEN }} | |
preRelease: false | |
skipDuplicate: true | |
- name: Publish to Visual Studio Marketplace | |
if: success() || failure() | |
uses: HaaLeo/publish-vscode-extension@v1 | |
with: | |
dryRun: ${{ steps.releaseMode.outputs.dryRun }} | |
extensionFile: ${{ steps.publishToOpenVSX.outputs.vsixPath }} | |
pat: ${{ secrets.VS_MARKETPLACE_TOKEN }} | |
preRelease: false | |
registryUrl: https://marketplace.visualstudio.com | |
skipDuplicate: true | |
- name: Github Release | |
uses: softprops/action-gh-release@v1 | |
if: ${{ ! steps.releaseMode.outputs.dryRun }} | |
with: | |
body: | | |
This release is also available on the [VSCode Marketplace](https://marketplace.visualstudio.com/items?itemName=SocketSecurity.vscode-socket-security) and [OpenVSX Registry](https://open-vsx.org/extension/SocketSecurity/vscode-socket-security). | |
files: ${{ steps.publishToOpenVSX.outputs.vsixPath }} | |
prerelease: ${{ steps.releaseMode.outputs.preRelease }} |