2023-09-23 10:15:24 +03:00
|
|
|
name: Enso Language Support for VSCode, IGV, NetBeans
|
2022-06-23 07:43:49 +03:00
|
|
|
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches: [develop]
|
|
|
|
pull_request:
|
|
|
|
branches: [develop]
|
|
|
|
paths:
|
2024-06-10 15:00:51 +03:00
|
|
|
- ".github/workflows/enso4igv.yml"
|
2022-06-23 07:43:49 +03:00
|
|
|
- "tools/enso4igv/**/*"
|
2024-06-14 17:01:37 +03:00
|
|
|
- "engine/**/*"
|
|
|
|
- "lib/java/**/*"
|
|
|
|
- "lib/scala/**/*"
|
|
|
|
- "build.sbt"
|
2022-06-23 07:43:49 +03:00
|
|
|
|
|
|
|
jobs:
|
2024-06-14 17:01:37 +03:00
|
|
|
build_linux_parser:
|
2022-06-23 07:43:49 +03:00
|
|
|
runs-on: ubuntu-20.04
|
|
|
|
|
|
|
|
steps:
|
2024-06-14 17:01:37 +03:00
|
|
|
- uses: actions/checkout@v4
|
|
|
|
|
|
|
|
- name: Install rustup
|
|
|
|
run: |
|
|
|
|
rustup target add x86_64-unknown-linux-musl
|
|
|
|
|
|
|
|
- name: Build Enso Parser
|
|
|
|
working-directory: .
|
|
|
|
env:
|
|
|
|
RUSTFLAGS: "-C target-feature=-crt-static"
|
|
|
|
run: |
|
2024-06-17 18:17:42 +03:00
|
|
|
cargo build --release -p enso-parser-jni -Z unstable-options --target x86_64-unknown-linux-musl --out-dir target/lib/
|
2024-06-14 17:01:37 +03:00
|
|
|
|
|
|
|
- name: Upload Artifacts
|
|
|
|
uses: actions/upload-artifact@v4
|
|
|
|
with:
|
|
|
|
name: parser_linux
|
|
|
|
path: |
|
|
|
|
target/lib/**
|
|
|
|
|
|
|
|
build_mac_intel_parser:
|
2024-10-17 16:13:32 +03:00
|
|
|
runs-on: macos-13
|
2024-06-14 17:01:37 +03:00
|
|
|
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v4
|
|
|
|
|
|
|
|
- name: Build Enso Parser
|
|
|
|
working-directory: .
|
|
|
|
env:
|
|
|
|
RUSTFLAGS: "-C target-feature=-crt-static"
|
|
|
|
run: |
|
2024-06-17 18:17:42 +03:00
|
|
|
cargo build --release -p enso-parser-jni -Z unstable-options --out-dir target/lib/x86_64
|
2024-06-14 17:01:37 +03:00
|
|
|
|
|
|
|
- name: Upload Artifacts
|
|
|
|
uses: actions/upload-artifact@v4
|
2022-06-23 07:43:49 +03:00
|
|
|
with:
|
2024-06-14 17:01:37 +03:00
|
|
|
name: parser_mac_intel
|
|
|
|
path: |
|
|
|
|
target/lib/**
|
|
|
|
|
|
|
|
build_mac_arm_parser:
|
|
|
|
runs-on: macos-14
|
|
|
|
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v4
|
|
|
|
|
|
|
|
- name: Build Enso Parser
|
|
|
|
working-directory: .
|
|
|
|
env:
|
|
|
|
RUSTFLAGS: "-C target-feature=-crt-static"
|
|
|
|
run: |
|
2024-06-17 18:17:42 +03:00
|
|
|
cargo build --release -p enso-parser-jni -Z unstable-options --out-dir target/lib/aarch64/
|
2024-06-14 17:01:37 +03:00
|
|
|
|
|
|
|
- name: Upload Artifacts
|
|
|
|
uses: actions/upload-artifact@v4
|
|
|
|
with:
|
|
|
|
name: parser_mac_arm
|
|
|
|
path: |
|
|
|
|
target/lib/**
|
|
|
|
|
|
|
|
build_windows_parser:
|
|
|
|
runs-on: windows-2019
|
|
|
|
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v4
|
|
|
|
|
|
|
|
- name: Build Enso Parser
|
|
|
|
working-directory: .
|
|
|
|
env:
|
|
|
|
RUSTFLAGS: "-C target-feature=-crt-static"
|
|
|
|
run: |
|
2024-06-17 18:17:42 +03:00
|
|
|
cargo build --release -p enso-parser-jni -Z unstable-options --out-dir target/lib/
|
2024-06-14 17:01:37 +03:00
|
|
|
|
|
|
|
- name: Upload Artifacts
|
|
|
|
uses: actions/upload-artifact@v4
|
|
|
|
with:
|
|
|
|
name: parser_windows
|
|
|
|
path: |
|
|
|
|
target/lib/**
|
|
|
|
|
|
|
|
build_java:
|
|
|
|
needs:
|
|
|
|
[
|
|
|
|
build_linux_parser,
|
|
|
|
build_mac_intel_parser,
|
|
|
|
build_mac_arm_parser,
|
|
|
|
build_windows_parser,
|
|
|
|
]
|
|
|
|
runs-on: ubuntu-20.04
|
|
|
|
steps:
|
|
|
|
- uses: actions/checkout@v4
|
|
|
|
|
|
|
|
- name: Download Libraries
|
|
|
|
uses: actions/download-artifact@v4
|
|
|
|
with:
|
|
|
|
path: enso_parser
|
|
|
|
merge-multiple: true
|
|
|
|
|
|
|
|
- name: List Binaries
|
|
|
|
run: |
|
2024-06-17 18:17:42 +03:00
|
|
|
find . | grep -i enso.parser | xargs ls -ld
|
2024-06-14 17:01:37 +03:00
|
|
|
|
|
|
|
- name: Set up Rustup
|
|
|
|
run: rustup show
|
2022-06-23 07:43:49 +03:00
|
|
|
|
2024-06-10 15:00:51 +03:00
|
|
|
- uses: graalvm/setup-graalvm@v1
|
|
|
|
with:
|
|
|
|
java-version: "21"
|
|
|
|
distribution: "graalvm-community"
|
|
|
|
|
2024-06-14 17:01:37 +03:00
|
|
|
- name: Publish Enso Libraries to Local Maven Repository
|
2024-06-10 15:00:51 +03:00
|
|
|
run: sbt publishM2
|
|
|
|
|
2024-01-18 18:57:45 +03:00
|
|
|
- name: Find out pom & micro versions
|
|
|
|
working-directory: tools/enso4igv
|
|
|
|
run: |
|
|
|
|
# Why do we subtract a number? Read versioning policy!
|
|
|
|
# https://github.com/enso-org/enso/pull/7861#discussion_r1333133490
|
|
|
|
echo "POM_VERSION=`mvn -q -DforceStdout help:evaluate -Dexpression=project.version | cut -f1 -d -`" >> "$GITHUB_ENV"
|
2024-05-31 15:47:12 +03:00
|
|
|
echo "MICRO_VERSION=`expr $GITHUB_RUN_NUMBER - 2930`" >> "$GITHUB_ENV"
|
2024-01-18 18:57:45 +03:00
|
|
|
|
2022-06-23 07:43:49 +03:00
|
|
|
- name: Update project version
|
|
|
|
working-directory: tools/enso4igv
|
|
|
|
run: |
|
2024-01-18 18:57:45 +03:00
|
|
|
echo "Setting version to $POM_VERSION.$MICRO_VERSION"
|
|
|
|
mvn versions:set -DnewVersion="$POM_VERSION.$MICRO_VERSION"
|
2022-06-23 07:43:49 +03:00
|
|
|
|
|
|
|
- name: Build with Maven
|
2024-06-14 17:01:37 +03:00
|
|
|
run: mvn -B -Pvsix package --file tools/enso4igv/pom.xml -Denso.parser.lib=`pwd`/enso_parser/
|
|
|
|
|
2022-06-23 07:43:49 +03:00
|
|
|
- name: Archive NBM file
|
2024-06-14 17:01:37 +03:00
|
|
|
uses: actions/upload-artifact@v4
|
2022-06-23 07:43:49 +03:00
|
|
|
with:
|
|
|
|
name: Enso IGV Plugin
|
|
|
|
path: tools/enso4igv/target/*.nbm
|
2023-02-28 16:43:26 +03:00
|
|
|
|
|
|
|
- name: Install Node.js modules
|
|
|
|
run: mvn -B -Pvsix npm:install --file tools/enso4igv/pom.xml
|
|
|
|
|
2023-09-23 10:15:24 +03:00
|
|
|
- name: Update package.json version
|
|
|
|
run: mvn -B -Pvsix npm:exec@version --file tools/enso4igv/pom.xml
|
|
|
|
|
2023-02-28 16:43:26 +03:00
|
|
|
- name: Build VSCode Extension
|
2024-06-14 17:01:37 +03:00
|
|
|
run: mvn -B -Pvsix npm:run@vsix --file tools/enso4igv/pom.xml -Denso.parser.lib=`pwd`/enso_parser/
|
2023-09-23 10:15:24 +03:00
|
|
|
|
|
|
|
- name: Archive VSCode extension
|
2024-06-14 17:01:37 +03:00
|
|
|
uses: actions/upload-artifact@v4
|
2023-09-23 10:15:24 +03:00
|
|
|
with:
|
|
|
|
name: VSCode Extension
|
|
|
|
path: tools/enso4igv/*.vsix
|