Skip to content

Use Core to get types and improve performance #236

Use Core to get types and improve performance

Use Core to get types and improve performance #236

Workflow file for this run

name: Install
on:
push:
branches:
- '*'
tags:
- '*'
pull_request:
branches:
- main
env:
IDRIS2_TESTS_CG: jvm
ACTIONS_ALLOW_UNSECURE_COMMANDS: true
PREVIOUS_VERSION: 0.7.0
jobs:
ubuntu-build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up JDK 8
uses: actions/setup-java@v2
with:
java-version: '8'
distribution: 'adopt'
cache: 'maven'
- name: Set IDRIS2_PREFIX
run: echo IDRIS2_PREFIX="$HOME/bin/idris2-$PREVIOUS_VERSION/env" >> "$GITHUB_ENV"
- name: Set PREFIX
run: echo PREFIX="$IDRIS2_PREFIX" >> "$GITHUB_ENV"
- name: Download previous version
run: |
mvn dependency:copy "-Dartifact=io.github.mmhelloworld:idris-jvm-compiler:$PREVIOUS_VERSION:zip" -DoutputDirectory=. -U
unzip idris-jvm-compiler-*.zip -d "$HOME/bin"
echo "$HOME/bin/idris2-$PREVIOUS_VERSION/exec" >> "$GITHUB_PATH"
- name: Build
run: mvn -B install -Dinteractive= -Didris.tests=only=jvm
- name: Copy new version
run: |
mkdir -p "$HOME/bin/idris2-current"
unzip idris-jvm-compiler/target/idris2-*.zip -d "$HOME/bin/idris2-current"
- name: Use new version
run: |
NEW_VERSION=$(mvn help:evaluate -Dexpression=project.version -q -DforceStdout)
echo "$HOME/bin/idris2-current/idris2-$NEW_VERSION/exec" >> "$GITHUB_PATH"
echo IDRIS2_PREFIX="$HOME/bin/idris2-current/idris2-$NEW_VERSION/env" >> "$GITHUB_ENV"
echo PREFIX="$IDRIS2_PREFIX" >> "$GITHUB_ENV"
- name: Self host
run: mvn -B clean install -Dinteractive= -Didris.tests=only=jvm
windows-build:
runs-on: windows-latest
defaults:
run:
shell: msys2 {0}
env:
MSYSTEM: MINGW64
MSYS2_PATH_TYPE: inherit
IDRIS_EXEC_EXT: .bat
CC: gcc
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up JDK 8
uses: actions/setup-java@v2
with:
java-version: '8'
distribution: 'adopt'
cache: 'maven'
- name: Setup msys2
uses: msys2/setup-msys2@v2
with:
update: true
install: unzip
- name: Set IDRIS2_PREFIX
run: echo IDRIS2_PREFIX="$HOME/bin/idris2-$PREVIOUS_VERSION/env" >> "$GITHUB_ENV"
- name: Set PREFIX
run: echo PREFIX="$IDRIS2_PREFIX" >> "$GITHUB_ENV"
- name: Download previous version
run: |
mvn dependency:copy "-Dartifact=io.github.mmhelloworld:idris-jvm-compiler:$PREVIOUS_VERSION:zip" -DoutputDirectory=. -U
unzip idris-jvm-compiler-*.zip -d "$HOME/bin"
echo "$HOME/bin/idris2-$PREVIOUS_VERSION/exec" >> $GITHUB_PATH
- name: Build
run: mvn -B install -Dinteractive= -Didris.tests=only=jvm
- name: Copy new version
run: |
mkdir -p "$HOME/bin/idris2-current"
cp -r build/exec "$HOME/bin/idris2-current/exec"
cp -r build/env "$HOME/bin/idris2-current/env"
- name: Use new version
run: |
echo "$HOME/bin/idris2-current/exec" >> $GITHUB_PATH
echo IDRIS2_PREFIX="$HOME/bin/idris2-current/env" >> "$GITHUB_ENV"
echo PREFIX="$IDRIS2_PREFIX" >> "$GITHUB_ENV"
- name: Self host
run: mvn -B clean install -Dinteractive= -Didris.tests=only=jvm