From fb073fdbef647993dfb7c10f76c65daea45233b6 Mon Sep 17 00:00:00 2001 From: Venus Xeon-Blonde Date: Sun, 27 Oct 2024 05:47:01 -0400 Subject: [PATCH] First Attempt to fix CI --- .github/workflows/cargo-check.yml | 13 ++++++++++--- .github/workflows/cargo-test.yml | 13 ++++++++++--- wright/Cargo.toml | 5 ++++- wright/src/bin/wright.rs | 2 +- 4 files changed, 25 insertions(+), 8 deletions(-) diff --git a/.github/workflows/cargo-check.yml b/.github/workflows/cargo-check.yml index ae88b202..a9e6adbd 100644 --- a/.github/workflows/cargo-check.yml +++ b/.github/workflows/cargo-check.yml @@ -27,12 +27,19 @@ jobs: - parser - wright_library_defaults - wright_binary - + - default + targets: + - --lib + - --tests os: [ubuntu-24.04, windows-latest, macos-latest] shell: ["bash", "msys2 {0}"] include: - os: macos-latest llvm-install-dir: /opt/homebrew/opt/llvm + - features: wright_binary + targets: --bins + - features: default + targets: --bins exclude: - os: windows-latest shell: bash @@ -100,10 +107,10 @@ jobs: - name: Run cargo check (Mac Only) if: ${{ matrix.os == 'macos-latest' }} - run: cargo check --no-default-features -F ${{ matrix.features }} + run: cargo check --no-default-features -F ${{ matrix.features }} ${{ matrix.targets }} env: LLVM_SYS_180_PREFIX: ${{ matrix.llvm-install-dir }} - name: Run cargo check (Ubuntu & Windows) if: ${{ matrix.os != 'macos-latest' }} - run: cargo check --no-default-features -F ${{ matrix.features }} + run: cargo check --no-default-features -F ${{ matrix.features }} ${{ matrix.targets }} diff --git a/.github/workflows/cargo-test.yml b/.github/workflows/cargo-test.yml index 3c76e6e5..c384224b 100644 --- a/.github/workflows/cargo-test.yml +++ b/.github/workflows/cargo-test.yml @@ -27,12 +27,19 @@ jobs: - parser - wright_library_defaults - wright_binary - + - default + targets: + - --lib + - --tests os: [ubuntu-24.04, windows-latest, macos-latest] shell: ["bash", "msys2 {0}"] include: - os: macos-latest llvm-install-dir: /opt/homebrew/opt/llvm + - features: wright_binary + targets: --bins + - features: default + targets: --bins exclude: - os: windows-latest shell: bash @@ -100,10 +107,10 @@ jobs: - name: Run cargo test (Mac Only) if: ${{ matrix.os == 'macos-latest' }} - run: cargo test --no-default-features -F ${{ matrix.features }} + run: cargo test --no-default-features -F ${{ matrix.features }} ${{ matrix.targets }} env: LLVM_SYS_180_PREFIX: ${{ matrix.llvm-install-dir }} - name: Run cargo test (Ubuntu & Windows) if: ${{ matrix.os != 'macos-latest' }} - run: cargo test --no-default-features -F ${{ matrix.features }} + run: cargo test --no-default-features -F ${{ matrix.features }} ${{ matrix.targets }} diff --git a/wright/Cargo.toml b/wright/Cargo.toml index 34df1f59..7a178075 100644 --- a/wright/Cargo.toml +++ b/wright/Cargo.toml @@ -54,7 +54,8 @@ harness = false # Also include support for detecting unicode capabilities on the host terminal. default = [ "wright_binary", - "supports-unicode" + "supports-unicode", + "dep:llvm-sys" ] # Features and dependencies required for the wright binary (currently just the library defaults and `clap`). @@ -207,9 +208,11 @@ optional = true # Unsafe bindings to LLVM # See https://llvm.org/. +# Optional: Currently not required by anything yet. [dependencies.llvm-sys] version = "180" features = ["force-static"] +optional = true # TEST DEPENDENCIES [dev-dependencies] diff --git a/wright/src/bin/wright.rs b/wright/src/bin/wright.rs index 12d7d9be..fa49a3f6 100644 --- a/wright/src/bin/wright.rs +++ b/wright/src/bin/wright.rs @@ -1,4 +1,4 @@ -// //! Command line interface for wright. +//! Command line interface for wright. use anyhow::Result; use clap::{Parser, Subcommand};