Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ci: Restore compilation check on PR #4963

Merged
merged 7 commits into from
Jul 23, 2024
Merged
Show file tree
Hide file tree
Changes from 6 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions .github/workflows/build-engines-react-native-template.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,10 @@ on:
description: 'Commit on the given branch to build'
type: string
required: false
uploadArtifacts:
description: If the job should upload artifacts after build finishes
type: boolean
default: true

jobs:
build-ios:
Expand Down Expand Up @@ -46,6 +50,7 @@ jobs:
ls -la .

- uses: actions/upload-artifact@v4
if: ${{ inputs.uploadArtifacts }}
with:
name: ios
path: |
Expand Down Expand Up @@ -90,6 +95,7 @@ jobs:
ls -la .

- uses: actions/upload-artifact@v4
if: ${{ inputs.uploadArtifacts }}
with:
name: android
path: |
Expand Down
44 changes: 31 additions & 13 deletions .github/workflows/test-compilation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,25 +16,43 @@ concurrency:

jobs:
test-crate-compilation:
name: "Check release compilation"
name: "${{ matrix.crate }} on ${{ matrix.os }}"
strategy:
fail-fast: false
runs-on: ubuntu-latest
matrix:
os:
- ubuntu-latest
- windows-latest
- macos-13
crate:
- schema-engine-cli
- prisma-fmt
- query-engine
- query-engine-node-api
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v4
- uses: actions-rust-lang/setup-rust-toolchain@v1
- uses: actions/cache@v4
with:
path: |
~/.cargo/registry
~/.cargo/git
target
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}

- run: "cargo clean && cargo build --release -p schema-engine-cli"
name: "Compile Migration Engine"

- run: "cargo clean && cargo build --release -p prisma-fmt"
name: "Compile prisma-fmt"

- run: "cargo clean && cargo build --release -p query-engine"
name: "Compile Query Engine Binary"

- run: "cargo clean && cargo build --release -p query-engine-node-api"
name: "Compile Query Engine Library"
- name: compile ${{ matrix.crate }}
shell: bash
env:
CRATE: ${{ matrix.crate }}
run: cargo build --release -p "$CRATE"

- name: "Check that Cargo.lock did not change"
run: "git diff --exit-code"

test-react-native-compilation:
name: React Native
uses: ./.github/workflows/build-engines-react-native-template.yml
with:
commit: ${{ github.sha }}
uploadArtifacts: false
Empty file added schema-engine/tmp
SevInf marked this conversation as resolved.
Show resolved Hide resolved
Empty file.
Loading