This repository has been archived by the owner on Nov 5, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 78
77 lines (65 loc) · 2.03 KB
/
release.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
name: Release
on:
push:
tags:
- "*"
jobs:
build:
uses: ./.github/workflows/full_build.yml
release:
runs-on: ubuntu-latest
needs: [build]
if: success() && startsWith(github.ref, 'refs/tags/')
permissions:
# Needed to work with releases
contents: write
steps:
- uses: actions/download-artifact@v3
with:
path: artifacts
- name: Remove Lapce files from artifacts
continue-on-error: true
run: rm -r lapce/
- name: Display structure of downloaded files
run: ls -R artifacts
- uses: ncipollo/release-action@v1
with:
token: ${{ secrets.GITHUB_TOKEN }}
artifacts: "artifacts/*/*"
allowUpdates: true
omitBodyDuringUpdate: true
omitDraftDuringUpdate: true
omitNameDuringUpdate: true
omitPrereleaseDuringUpdate: true
publish-vs-code:
runs-on: ubuntu-latest
needs: [build]
if: success() && startsWith(github.ref, 'refs/tags/')
steps:
- uses: actions/download-artifact@v3
- name: Deploy to VS Code Marketplace
env:
VSCE_PAT: ${{ secrets.VSCODE_MARKETPLACE_TOKEN }}
run: npx vsce publish --packagePath $(find . -type f -iname '*.vsix')
- name: Deploy to OpenVSX
env:
OVSX_PAT: ${{ secrets.OPENVSX_ACCESS_TOKEN }}
run: npx ovsx publish --packagePath $(find . -type f -iname '*.vsix')
publish-lapce:
runs-on: ubuntu-latest
needs: [build]
if: success() && startsWith(github.ref, 'refs/tags/')
# Since the editor/extensions are in beta and not well documented, allow
# this to fail
continue-on-error: true
steps:
- uses: actions/download-artifact@v3
- name: Install Volts
uses: baptiste0928/cargo-install@v2
with:
crate: volts
- name: Deploy to Lapce
working-directory: ./lapce
env:
LAPCE_TOKEN: ${{ secrets.LAPCE_PLUGINS_API_TOKEN }}
run: volts --token "$LAPCE_TOKEN" publish