Haxe-Formatter #1865
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
name: Haxe-Formatter | |
on: | |
push: | |
branches: | |
- master | |
pull_request: | |
branches: | |
- master | |
schedule: | |
- cron: '15 23 * * *' | |
jobs: | |
build: | |
strategy: | |
matrix: | |
haxe-version: ['4.3.6', 'nightly'] | |
platform: [ubuntu-latest, windows-latest] | |
runs-on: ${{ matrix.platform }} | |
steps: | |
- name: Set Git Auto CRLF to false on Windows | |
if: matrix.platform == 'windows-latest' | |
run: git config --global core.autocrlf false | |
- name: Checkout Formatter sources | |
uses: actions/checkout@v1 | |
- name: Use Node.js 16 | |
uses: actions/setup-node@v1 | |
with: | |
node-version: 16 | |
- name: Run npm install | |
run: npm ci | |
- name: Install Haxe version ${{ matrix.haxe-version }} | |
run: | | |
npx lix download haxe ${{ matrix.haxe-version }} | |
npx lix use haxe ${{ matrix.haxe-version }} | |
- name: Run lix download | |
run: npx lix download | |
- name: Print versions | |
run: | | |
npx haxe -version | |
npx neko -version | |
npx haxelib list | |
- name: Build NodeJs version | |
run: npx haxe buildJsNode.hxml | |
- name: Build browser JS version | |
run: npx haxe buildJsBrowser.hxml | |
- name: Build Neko version | |
run: npx haxe buildNeko.hxml | |
- name: Build Java version | |
run: npx haxe buildJava.hxml | |
- name: Build JSON schema | |
run: npx haxe buildSchema.hxml | |
- name: Run eval tests (without coverage) | |
run: npx haxe test.hxml | |
- name: Run eval tests (with coverage) | |
run: npx haxe testCoverage.hxml | |
- name: Run Java tests | |
run: npx haxe testJava.hxml | |
- name: Run Node version with --check | |
run: node run.js -s . --check | |
- name: Run Java version with --check | |
run: java -jar out/Cli.jar -s . --check | |
- name: Run Neko (with node) with --check | |
run: | | |
npx neko run.n -s . --check | |
- name: Run Neko (without node) with --check | |
run: | | |
rm run.js | |
npx neko run.n -s . --check | |
# - name: publish artifacts | |
# if: (matrix.haxe-version == '4.1.5' && matrix.platform == 'ubuntu-latest') | |
# uses: actions/upload-artifact@v2 | |
# with: | |
# name: formatter.js | |
# path: bin/formatter.js | |
- name: Upload results to codecov | |
if: success() && matrix.platform == 'ubuntu-latest' && (matrix.haxe-version != 'nightly') | |
run: bash <(curl -s https://codecov.io/bash) || echo "Codecov did not collect coverage reports" |