Skip to content

Commit 93e3d4d

Browse files
committed
preparing for release of pre-1.0.0
1 parent 4573dd8 commit 93e3d4d

File tree

5 files changed

+87
-13
lines changed

5 files changed

+87
-13
lines changed

.github/workflows/release.yml

Lines changed: 73 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,73 @@
1+
name: Create Github Release
2+
on:
3+
push:
4+
tags: [ "*" ]
5+
env:
6+
CARGO_TERM_COLOR: always
7+
jobs:
8+
empty-release:
9+
runs-on: ubuntu-20.04
10+
outputs:
11+
upload_url: ${{ steps.create_release.outputs.upload_url }}
12+
steps:
13+
- name: Get tag
14+
run: echo "VERSION=${GITHUB_REF/refs\/tags\//}" >> $GITHUB_ENV
15+
- name: Create Release
16+
id: create_release
17+
uses: actions/create-release@v1
18+
env:
19+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
20+
with:
21+
tag_name: $VERSION
22+
release_name: Release $VERSION
23+
draft: false
24+
prerelease: false
25+
release-server:
26+
runs-on: ${{ matrix.platforms.os }}
27+
defaults:
28+
run:
29+
working-directory: server
30+
needs: empty-release
31+
strategy:
32+
matrix:
33+
platforms:
34+
- os: ubuntu-20.04
35+
target: x86_64-unknown-linux-gnu
36+
- os: windows-latest
37+
target: x86_64-windows-msvc
38+
- os: macos-10.15
39+
target: x86_64-apple-darwin
40+
steps:
41+
- uses: actions/checkout@v2
42+
- name: Build server
43+
run: cargo build --release
44+
- name: Upload release file
45+
uses: actions/upload-release-asset@v1
46+
env:
47+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
48+
with:
49+
upload_url: ${{ steps.create_release.outputs.upload_url }}
50+
asset_path: target/release/mcshader-lsp
51+
asset_name: mcshader-lsp-${{ matrix.platforms.target }}
52+
asset_content_type: application/octet-stream
53+
release-vscode-extension:
54+
runs-on: ubuntu-20.04
55+
needs: empty-release
56+
steps:
57+
- uses: actions/checkout@v2
58+
- run: npm i
59+
- run: npm i -g rollup
60+
- uses: HaaLeo/publish-vscode-extension@v0
61+
id: vsce_release
62+
with:
63+
pat: ${{ secrets.VSCE_TOKEN }}
64+
registryUrl: https://marketplace.visualstudio.com
65+
- name: Upload VSIX file
66+
uses: actions/upload-release-asset@v1
67+
env:
68+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
69+
with:
70+
upload_url: ${{ needs.empty-release.outputs.upload_url }}
71+
asset_path: ${{ steps.vsce_release.outputs.vsixPath }}
72+
asset_name: vscode-mc-shader.vsix
73+
asset_content_type: application/vsix

.github/workflows/server.yml

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,23 +1,23 @@
1-
name: LSP Server
1+
name: Test Server
22
on:
33
push:
44
branches: [ rust-rewrite ]
55
pull_request:
66
branches: [ rust-rewrite ]
77
env:
88
CARGO_TERM_COLOR: always
9-
defaults:
10-
run:
11-
working-directory: server
129
jobs:
13-
build:
10+
build-and-test:
1411
runs-on: ${{ matrix.os }}
12+
defaults:
13+
run:
14+
working-directory: server
1515
strategy:
1616
matrix:
17-
os: [ubuntu-20.04, windows-latest, macos-10.15]
17+
os: [ ubuntu-20.04, windows-latest, macos-10.15 ]
1818
steps:
1919
- uses: actions/checkout@v2
20-
- name: Build
20+
- name: Build server
2121
run: cargo build
2222
- name: Run tests
2323
run: cargo test

.vscode/settings.json

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2,13 +2,14 @@
22
"files.exclude": {
33
"out": false
44
},
5-
"npm.enableScriptExplorer": true,
65
"npm.exclude": [
76
"**/client",
87
"**/server"
98
],
109
"search.exclude": {
1110
"out": true
1211
},
13-
"eslint.enable": true
12+
"yaml.schemas": {
13+
"https://json.schemastore.org/github-workflow": [".github/*"]
14+
}
1415
}

client/package.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,14 @@
44
"compile": "tsc -p ./"
55
},
66
"dependencies": {
7-
"@rollup/plugin-commonjs": "^17.1.0",
8-
"@rollup/plugin-node-resolve": "^11.1.1",
97
"adm-zip": "^0.4.14",
108
"node-fetch": "^2.6.0",
11-
"rollup": "^2.38.1",
129
"vscode-languageclient": "^6.1.3"
1310
},
1411
"devDependencies": {
12+
"rollup": "^2.38.1",
13+
"@rollup/plugin-commonjs": "^17.1.0",
14+
"@rollup/plugin-node-resolve": "^11.1.1",
1515
"@types/vscode": "^1.47.0",
1616
"@types/adm-zip": "^0.4.32",
1717
"@types/node-fetch": "^2.5.4"

client/src/extension.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ import { PersistentState } from './persistent_state'
99
import * as path from 'path'
1010

1111
const platforms: { [key: string]: string } = {
12-
'x64 win32': 'x86_64-pc-windows-gnu',
12+
'x64 win32': 'x86_64-pc-windows-msvc',
1313
'x64 linux': 'x86_64-unknown-linux-gnu',
1414
'x64 darwin': 'x86_64-apple-darwin',
1515
}

0 commit comments

Comments
 (0)