Skip to content

Merge pull request #13 from GaijinEntertainment/version-1.4.2 #59

Merge pull request #13 from GaijinEntertainment/version-1.4.2

Merge pull request #13 from GaijinEntertainment/version-1.4.2 #59

Workflow file for this run

name: Build
on: [push, pull_request]
jobs:
build:
strategy:
matrix:
include:
- os: windows-latest
command: package-windows-x64
- os: ubuntu-latest
command: package-linux-x64
- os: macos-latest
command: package-macos-x64
runs-on: ${{ matrix.os }}
steps:
- name: Checkout
uses: actions/checkout@v4
with:
submodules: 'true'
- name: Install Node.js
uses: actions/setup-node@v4
- name: Install dependencies for the client
run: npm ci
- name: Install dependencies for the language server
run: npm ci
working-directory: ./Dagor-Shader-Language-Server
- name: Generate condition ANTLR lexer
run: npx antlr4ts -o "../../src/_generated" "ConditionLexer.g4"
working-directory: ./Dagor-Shader-Language-Server/grammar/antlr
- name: Generate condition ANTLR parser
run: npx antlr4ts -o "../../src/_generated" -no-listener -visitor "ConditionParser.g4"
working-directory: ./Dagor-Shader-Language-Server/grammar/antlr
- name: Generate DSHL ANTLR lexer
run: npx antlr4ts -o "../../src/_generated" "DshlLexer.g4"
working-directory: ./Dagor-Shader-Language-Server/grammar/antlr
- name: Generate DSHL ANTLR parser
run: npx antlr4ts -o "../../src/_generated" -no-listener -visitor "DshlParser.g4"
working-directory: ./Dagor-Shader-Language-Server/grammar/antlr
- name: Build
run: npm run build
- name: Build the tests
run: npm run build-tests
- name: ESLint
run: npm run eslint
- name: Prettier lint
run: npm run prettier-lint
- name: Run tests
run: xvfb-run -a npm test
if: runner.os == 'Linux'
- name: Run tests
run: npm test
if: runner.os != 'Linux'
- name: Build in production mode
run: npm run build-production
- name: Create platform-specific package
run: npm run ${{ matrix.command }}
- name: Create Universal package
run: npm run package-universal