mirror of
https://github.com/roc-lang/roc.git
synced 2025-12-23 08:48:03 +00:00
Merge branch 'main' into basic-cli-5-release
Signed-off-by: Anton-4 <17049058+Anton-4@users.noreply.github.com>
This commit is contained in:
commit
e07a7496f6
289 changed files with 17405 additions and 9831 deletions
36
.github/workflows/basic_cli_test_arm64.yml
vendored
36
.github/workflows/basic_cli_test_arm64.yml
vendored
|
|
@ -15,8 +15,40 @@ jobs:
|
|||
with:
|
||||
repository: roc-lang/basic-cli
|
||||
ref: main
|
||||
|
||||
- name: get latest roc nightly
|
||||
run: |
|
||||
curl -fOL https://github.com/roc-lang/roc/releases/download/nightly/roc_nightly-linux_arm64-latest.tar.gz
|
||||
|
||||
- name: rename nightly tar
|
||||
run: mv $(ls | grep "roc_nightly.*tar\.gz") roc_nightly.tar.gz
|
||||
|
||||
- name: decompress the tar
|
||||
run: tar -xzf roc_nightly.tar.gz
|
||||
|
||||
- run: rm roc_nightly.tar.gz
|
||||
|
||||
- name: simplify nightly folder name
|
||||
run: mv roc_nightly* roc_nightly
|
||||
|
||||
- run: ./roc_nightly/roc version
|
||||
|
||||
- run: expect -v
|
||||
|
||||
# Run all tests
|
||||
- run: EXAMPLES_DIR=./examples/ ./ci/all_tests.sh
|
||||
|
||||
######
|
||||
# Now test the latest basic-cli release, not the main branch
|
||||
######
|
||||
|
||||
- name: Remove roc_nightly folder to keep things simple (we'll download it again later)
|
||||
run: rm -rf roc_nightly
|
||||
|
||||
- name: Run all tests with latest roc nightly + latest basic-cli release
|
||||
- name: Get the examples of the latest basic-cli release
|
||||
run: ./ci/get_latest_release_examples.sh
|
||||
|
||||
- name: Run all tests with latest roc nightly and latest basic-cli release
|
||||
run: |
|
||||
sed -i 's/x86_64/arm64/g' ./ci/test_latest_release.sh
|
||||
./ci/test_latest_release.sh
|
||||
EXAMPLES_DIR=./latest-release-examples/ ./ci/test_latest_release.sh
|
||||
|
|
|
|||
9
.github/workflows/macos_x86_64.yml
vendored
9
.github/workflows/macos_x86_64.yml
vendored
|
|
@ -19,6 +19,15 @@ jobs:
|
|||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
|
||||
- name: set LLVM_SYS_160_PREFIX
|
||||
run: echo "LLVM_SYS_160_PREFIX=$(brew --prefix llvm@16)" >> $GITHUB_ENV
|
||||
|
||||
- name: Update PATH to use zig 11
|
||||
run: |
|
||||
echo "PATH=/Users/username1/Downloads/zig-macos-x86_64-0.11.0:$PATH" >> $GITHUB_ENV
|
||||
|
||||
- run: zig version
|
||||
|
||||
- name: test_gen llvm tests
|
||||
run: cargo nextest-gen-llvm --release --no-fail-fast --locked -E "package(test_gen) - test(gen_str::str_append_scalar)"
|
||||
|
||||
|
|
|
|||
8
.github/workflows/nightly_linux_arm64.yml
vendored
8
.github/workflows/nightly_linux_arm64.yml
vendored
|
|
@ -1,4 +1,5 @@
|
|||
on:
|
||||
# pull_request:
|
||||
workflow_dispatch:
|
||||
schedule:
|
||||
- cron: '0 9 * * *'
|
||||
|
|
@ -10,9 +11,16 @@ jobs:
|
|||
name: build and package nightly release
|
||||
runs-on: [self-hosted, Linux, ARM64]
|
||||
timeout-minutes: 90
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
|
||||
- name: Update PATH to use zig 11
|
||||
run: |
|
||||
echo "PATH=/home/username/Downloads/zig-linux-aarch64-0.11.0:$PATH" >> $GITHUB_ENV
|
||||
|
||||
- run: zig version
|
||||
|
||||
- name: create version.txt
|
||||
run: ./ci/write_version.sh
|
||||
|
||||
|
|
|
|||
8
.github/workflows/nightly_linux_x86_64.yml
vendored
8
.github/workflows/nightly_linux_x86_64.yml
vendored
|
|
@ -1,4 +1,5 @@
|
|||
on:
|
||||
# pull_request:
|
||||
workflow_dispatch:
|
||||
schedule:
|
||||
- cron: '0 9 * * *'
|
||||
|
|
@ -10,9 +11,16 @@ jobs:
|
|||
name: build and package nightly release
|
||||
runs-on: [self-hosted, i7-6700K]
|
||||
timeout-minutes: 90
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
|
||||
- name: Update PATH to use zig 11
|
||||
run: |
|
||||
echo "PATH=/home/big-ci-user/Downloads/zig-linux-x86_64-0.11.0:$PATH" >> $GITHUB_ENV
|
||||
|
||||
- run: zig version
|
||||
|
||||
- name: create version.txt
|
||||
run: ./ci/write_version.sh
|
||||
|
||||
|
|
|
|||
|
|
@ -1,10 +1,15 @@
|
|||
on:
|
||||
# pull_request:
|
||||
workflow_dispatch:
|
||||
schedule:
|
||||
- cron: '0 9 * * *'
|
||||
|
||||
name: Nightly Release macOS Apple Silicon
|
||||
|
||||
env:
|
||||
RUST_BACKTRACE: 1
|
||||
LLVM_SYS_160_PREFIX: /opt/homebrew/opt/llvm@16
|
||||
|
||||
jobs:
|
||||
test-and-build:
|
||||
name: Rust tests, build and package nightly release
|
||||
|
|
@ -12,8 +17,9 @@ jobs:
|
|||
timeout-minutes: 90
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
- name: zig version
|
||||
run: zig version
|
||||
|
||||
- run: zig version
|
||||
|
||||
- name: llvm version
|
||||
run: llc --version | grep LLVM
|
||||
|
||||
|
|
|
|||
10
.github/workflows/nightly_macos_x86_64.yml
vendored
10
.github/workflows/nightly_macos_x86_64.yml
vendored
|
|
@ -1,10 +1,14 @@
|
|||
on:
|
||||
# pull_request:
|
||||
workflow_dispatch:
|
||||
schedule:
|
||||
- cron: '0 9 * * *' # 9=9am utc+0
|
||||
|
||||
name: Nightly Release macOS x86_64
|
||||
|
||||
env:
|
||||
LLVM_SYS_160_PREFIX: /usr/local/opt/llvm@16
|
||||
|
||||
jobs:
|
||||
test-build-upload:
|
||||
name: build, test, package and upload nightly release
|
||||
|
|
@ -12,6 +16,12 @@ jobs:
|
|||
timeout-minutes: 120
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
|
||||
- name: Update PATH to use zig 11
|
||||
run: |
|
||||
echo "PATH=/Users/username1/Downloads/zig-macos-x86_64-0.11.0:$PATH" >> $GITHUB_ENV
|
||||
|
||||
- run: zig version
|
||||
|
||||
- name: write version to file
|
||||
run: ./ci/write_version.sh
|
||||
|
|
|
|||
|
|
@ -1,4 +1,5 @@
|
|||
on:
|
||||
# pull_request:
|
||||
workflow_dispatch:
|
||||
schedule:
|
||||
- cron: '0 9 * * *'
|
||||
|
|
|
|||
|
|
@ -1,4 +1,5 @@
|
|||
on:
|
||||
# pull_request:
|
||||
workflow_dispatch:
|
||||
schedule:
|
||||
- cron: '0 9 * * *'
|
||||
|
|
|
|||
2
.github/workflows/nix_linux_x86_64.yml
vendored
2
.github/workflows/nix_linux_x86_64.yml
vendored
|
|
@ -13,7 +13,7 @@ env:
|
|||
jobs:
|
||||
nix-linux-x86:
|
||||
name: nix-linux-x86
|
||||
runs-on: [self-hosted, i7-6700K]
|
||||
runs-on: [self-hosted, i5-4690K]
|
||||
timeout-minutes: 90
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
|
|
|
|||
|
|
@ -18,6 +18,8 @@ jobs:
|
|||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
|
||||
- run: zig version
|
||||
|
||||
- name: check formatting with rustfmt
|
||||
run: nix develop -c cargo fmt --all -- --check
|
||||
|
||||
|
|
@ -40,7 +42,7 @@ jobs:
|
|||
run: cd examples/platform-switching/rust-platform && nix develop -c cargo test --release --locked
|
||||
|
||||
- name: test aarch64 dev backend
|
||||
run: nix develop -c cargo nextest-gen-dev --locked --release --no-fail-fast -E 'test(gen_num) + test(gen_records)'
|
||||
run: nix develop -c cargo nextest-gen-dev --locked --release --no-fail-fast
|
||||
|
||||
# we run the llvm wasm tests only on this machine because it is fast and wasm should be cross-target
|
||||
- name: execute llvm wasm tests with --release
|
||||
|
|
|
|||
3
.github/workflows/nix_macos_x86_64.yml
vendored
3
.github/workflows/nix_macos_x86_64.yml
vendored
|
|
@ -21,7 +21,8 @@ jobs:
|
|||
- uses: cachix/install-nix-action@v22
|
||||
|
||||
- name: execute cli_run tests only, the full tests take too long but are run nightly
|
||||
run: nix develop -c cargo test --locked --release -p roc_cli
|
||||
run: nix develop -c cargo test --locked --release -p roc_cli -- --skip hello_gui
|
||||
# see 5932 for hello_gui
|
||||
|
||||
- name: make a libapp.so for the next step
|
||||
run: nix develop -c cargo run -- gen-stub-lib examples/platform-switching/rocLovesRust.roc
|
||||
|
|
|
|||
2
.github/workflows/test_nightly_many_os.yml
vendored
2
.github/workflows/test_nightly_many_os.yml
vendored
|
|
@ -16,7 +16,7 @@ jobs:
|
|||
- uses: actions/checkout@v3
|
||||
- uses: goto-bus-stop/setup-zig@v2
|
||||
with:
|
||||
version: 0.9.1
|
||||
version: 0.11.0
|
||||
|
||||
- name: get the latest release archive for linux (x86_64)
|
||||
if: startsWith(matrix.os, 'ubuntu')
|
||||
|
|
|
|||
13
.github/workflows/ubuntu_x86_64.yml
vendored
13
.github/workflows/ubuntu_x86_64.yml
vendored
|
|
@ -13,16 +13,22 @@ env:
|
|||
jobs:
|
||||
test-zig-rust-wasm:
|
||||
name: test zig, rust, wasm...
|
||||
runs-on: [self-hosted, i5-4690K]
|
||||
runs-on: [self-hosted, i7-6700K]
|
||||
timeout-minutes: 90
|
||||
env:
|
||||
RUSTC_WRAPPER: /home/small-ci-user/.cargo/bin/sccache
|
||||
RUSTC_WRAPPER: /home/big-ci-user/.cargo/bin/sccache
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
|
||||
- name: Check for duplicate AUTHORS
|
||||
run: diff <(sort AUTHORS) <(sort AUTHORS | uniq) # The < operator treats a string as a file. diff 'succeeds' if no difference.
|
||||
|
||||
- name: Update PATH to use zig 11
|
||||
run: |
|
||||
echo "PATH=/home/big-ci-user/Downloads/zig-linux-x86_64-0.11.0:$PATH" >> $GITHUB_ENV
|
||||
|
||||
- run: zig version
|
||||
|
||||
- name: zig fmt check, zig tests
|
||||
run: cd crates/compiler/builtins/bitcode && ./run-tests.sh
|
||||
|
||||
|
|
@ -33,7 +39,8 @@ jobs:
|
|||
run: cd crates/compiler/builtins/bitcode && ./run-wasm-tests.sh
|
||||
|
||||
- name: regular rust tests
|
||||
run: cargo test --locked --release && sccache --show-stats
|
||||
# see #5904 for skipped test
|
||||
run: cargo test --locked --release -- --skip cli_run::expects_dev_and_test && sccache --show-stats
|
||||
|
||||
- name: check that the platform`s produced dylib is loadable
|
||||
run: cd examples/platform-switching/rust-platform && LD_LIBRARY_PATH=. cargo test --release --locked
|
||||
|
|
|
|||
18
.github/workflows/windows_release_build.yml
vendored
18
.github/workflows/windows_release_build.yml
vendored
|
|
@ -15,7 +15,7 @@ jobs:
|
|||
name: windows-release-build
|
||||
runs-on: windows-2022
|
||||
env:
|
||||
LLVM_SYS_130_PREFIX: C:\LLVM-13.0.1-win64
|
||||
LLVM_SYS_160_PREFIX: C:\LLVM-16.0.6-win64
|
||||
|
||||
timeout-minutes: 150
|
||||
steps:
|
||||
|
|
@ -25,10 +25,10 @@ jobs:
|
|||
|
||||
- name: download and install zig
|
||||
run: |
|
||||
curl.exe -f --output "C:\zig-windows-x86_64-0.9.1.zip" --url https://ziglang.org/download/0.9.1/zig-windows-x86_64-0.9.1.zip
|
||||
curl.exe -f --output "C:\zig-windows-x86_64-0.11.0.zip" --url https://ziglang.org/download/0.11.0/zig-windows-x86_64-0.11.0.zip
|
||||
cd C:\
|
||||
7z x zig-windows-x86_64-0.9.1.zip
|
||||
Add-Content $env:GITHUB_PATH "C:\zig-windows-x86_64-0.9.1\"
|
||||
7z x zig-windows-x86_64-0.11.0.zip
|
||||
Add-Content $env:GITHUB_PATH "C:\zig-windows-x86_64-0.11.0\"
|
||||
|
||||
- name: zig version
|
||||
run: zig version
|
||||
|
|
@ -36,10 +36,10 @@ jobs:
|
|||
- name: install rust nightly 1.71.0
|
||||
run: rustup install nightly-2023-05-28
|
||||
|
||||
- name: set up llvm 13
|
||||
- name: set up llvm 16
|
||||
run: |
|
||||
curl.exe -f -L -O -H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" https://github.com/roc-lang/llvm-package-windows/releases/download/v13.0.1/LLVM-13.0.1-win64.7z
|
||||
7z x LLVM-13.0.1-win64.7z -oC:\LLVM-13.0.1-win64
|
||||
curl.exe -f -L -O -H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" https://github.com/roc-lang/llvm-package-windows/releases/download/v16.0.6/LLVM-16.0.6-win64.7z
|
||||
7z x LLVM-16.0.6-win64.7z -oC:\LLVM-16.0.6-win64
|
||||
|
||||
- name: cargo build release. Twice for zig lld-link error.
|
||||
run: cargo build --locked --release || cargo build --locked --release
|
||||
- name: cargo build release.
|
||||
run: cargo build --locked --release
|
||||
|
|
|
|||
24
.github/workflows/windows_tests.yml
vendored
24
.github/workflows/windows_tests.yml
vendored
|
|
@ -1,5 +1,5 @@
|
|||
on:
|
||||
#pull_request:
|
||||
#pull_request:
|
||||
|
||||
name: windows - subset of tests
|
||||
|
||||
|
|
@ -15,7 +15,7 @@ jobs:
|
|||
name: windows-test-subset
|
||||
runs-on: windows-2022
|
||||
env:
|
||||
LLVM_SYS_130_PREFIX: C:\LLVM-13.0.1-win64
|
||||
LLVM_SYS_160_PREFIX: C:\LLVM-16.0.6-win64
|
||||
|
||||
timeout-minutes: 150
|
||||
steps:
|
||||
|
|
@ -29,10 +29,10 @@ jobs:
|
|||
|
||||
- name: download and install zig
|
||||
run: |
|
||||
curl.exe -f --output "C:\zig-windows-x86_64-0.9.1.zip" --url https://ziglang.org/download/0.9.1/zig-windows-x86_64-0.9.1.zip
|
||||
curl.exe -f --output "C:\zig-windows-x86_64-0.11.0.zip" --url https://ziglang.org/download/0.11.0/zig-windows-x86_64-0.11.0.zip
|
||||
cd C:\
|
||||
7z x zig-windows-x86_64-0.9.1.zip
|
||||
Add-Content $env:GITHUB_PATH "C:\zig-windows-x86_64-0.9.1\"
|
||||
7z x zig-windows-x86_64-0.11.0.zip
|
||||
Add-Content $env:GITHUB_PATH "C:\zig-windows-x86_64-0.11.0\"
|
||||
|
||||
- run: zig version
|
||||
|
||||
|
|
@ -44,17 +44,17 @@ jobs:
|
|||
- name: install rust nightly 1.71.0
|
||||
run: rustup install nightly-2023-05-28
|
||||
|
||||
- name: set up llvm 13
|
||||
- name: set up llvm 16
|
||||
run: |
|
||||
curl.exe -f -L -O -H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" https://github.com/roc-lang/llvm-package-windows/releases/download/v13.0.1/LLVM-13.0.1-win64.7z
|
||||
7z x LLVM-13.0.1-win64.7z -oC:\LLVM-13.0.1-win64
|
||||
curl.exe -f -L -O -H "Authorization: token ${{ secrets.GITHUB_TOKEN }}" https://github.com/roc-lang/llvm-package-windows/releases/download/v16.0.6/LLVM-16.0.6-win64.7z
|
||||
7z x LLVM-16.0.6-win64.7z -oC:\LLVM-16.0.6-win64
|
||||
|
||||
- name: Build tests --release without running. Twice for zig lld-link error.
|
||||
run: cargo test --locked --release --no-run || cargo test --locked --release --no-run
|
||||
- name: Build tests --release without running.
|
||||
run: cargo test --locked --release --no-run
|
||||
|
||||
# Why are these tests not build with previous command? => fingerprint error. Use `CARGO_LOG=cargo::core::compiler::fingerprint=info` to investigate
|
||||
- name: Build specific tests without running. Twice for zig lld-link error.
|
||||
run: cargo test --locked --release --no-run -p roc_ident -p roc_region -p roc_collections -p roc_can -p roc_types -p roc_solve -p roc_mono -p roc_gen_dev -p roc_gen_wasm -p roc_serialize -p roc_linker -p roc_cli -p test_gen || cargo test --locked --release --no-run -p roc_ident -p roc_region -p roc_collections -p roc_can -p roc_types -p roc_solve -p roc_mono -p roc_gen_dev -p roc_gen_wasm -p roc_serialize -p roc_linker -p roc_cli -p test_gen
|
||||
- name: Build specific tests without running.
|
||||
run: cargo test --locked --release --no-run -p roc_ident -p roc_region -p roc_collections -p roc_can -p roc_types -p roc_solve -p roc_mono -p roc_gen_dev -p roc_gen_wasm -p roc_serialize -p roc_linker -p roc_cli -p test_gen
|
||||
|
||||
- name: Test setjmp/longjmp logic
|
||||
run: cargo test-gen-dev --locked --release nat_alias && cargo test-gen-dev --locked --release a_crash
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue