| 1 |
@REM Copyright (c) 2019 Google Inc. |
| 2 |
@REM |
| 3 |
@REM Licensed under the Apache License, Version 2.0 (the "License"); |
| 4 |
@REM you may not use this file except in compliance with the License. |
| 5 |
@REM You may obtain a copy of the License at |
| 6 |
@REM |
| 7 |
@REM http://www.apache.org/licenses/LICENSE-2.0 |
| 8 |
@REM |
| 9 |
@REM Unless required by applicable law or agreed to in writing, software |
| 10 |
@REM distributed under the License is distributed on an "AS IS" BASIS, |
| 11 |
@REM WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 12 |
@REM See the License for the specific language governing permissions and |
| 13 |
@REM limitations under the License. |
| 14 |
|
| 15 |
@set EXT_PATH=%userprofile%\.vscode\extensions\google.spirvls-0.0.1 |
| 16 |
@set ROOT_PATH=%~dp0 |
| 17 |
|
| 18 |
go run %ROOT_PATH%\src\tools\gen-grammar.go --cache %ROOT_PATH%\cache --template %ROOT_PATH%\spirv.json.tmpl --out %ROOT_PATH%\spirv.json |
| 19 |
go run %ROOT_PATH%\src\tools\gen-grammar.go --cache %ROOT_PATH%\cache --template %ROOT_PATH%\src\schema\schema.go.tmpl --out %ROOT_PATH%\src\schema\schema.go |
| 20 |
|
| 21 |
if not exist %EXT_PATH% mkdir -p %EXT_PATH% |
| 22 |
copy %ROOT_PATH%\extension.js %EXT_PATH% |
| 23 |
copy %ROOT_PATH%\package.json %EXT_PATH% |
| 24 |
copy %ROOT_PATH%\spirv.json %EXT_PATH% |
| 25 |
|
| 26 |
go build -o %EXT_PATH%\langsvr %ROOT_PATH%\src\langsvr.go |
| 27 |
|
| 28 |
@pushd %EXT_PATH% |
| 29 |
call npm install |
| 30 |
@popd |