Skip to content

Commit

Permalink
byah
Browse files Browse the repository at this point in the history
  • Loading branch information
rbalicki2 committed Jan 1, 2025
1 parent 63adc9b commit ca5219e
Show file tree
Hide file tree
Showing 2 changed files with 31 additions and 17 deletions.
21 changes: 4 additions & 17 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -72,25 +72,12 @@ jobs:
run: ./artifacts/linux-x64/isograph_cli --config ./demos/${{ matrix.target.folder }}/isograph.config.json
- name: 'Check working directory status'
run: './scripts/check-git-status.sh'

build-json-schema:
name: Build json schema
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Install Rust
uses: actions-rust-lang/setup-rust-toolchain@v1
with:
toolchain: stable
override: true
target: x86_64-unknown-linux-musl
- name: Build isograph_config with cargo
run: cargo build --bin isograph_config --target x86_64-unknown-linux-musl --release
- name: Make artifact executable
run: chmod +x ./target/x86_64-unknown-linux-musl/release/isograph_config
- name: Build json schema
run: ./target/x86_64-unknown-linux-musl/release/isograph_config
- name: Check working directory status
run: './scripts/check-git-status.sh'
uses: ./.github/workflows/run-cargo-bin-and-ensure-no-changes.yml
with:
binary: isograph_config

typecheck-demos:
name: Typecheck and Lint Demos
Expand Down
27 changes: 27 additions & 0 deletions .github/workflows/run-cargo-bin-and-ensure-no-changes.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
on:
workflow_call:
inputs:
binary:
required: true
type: string

jobs:
build-and-run-binary:
name: Build and run ${{ inputs.binary }} and ensure no files have been modified
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Install Rust
uses: actions-rust-lang/setup-rust-toolchain@v1
with:
toolchain: stable
override: true
target: x86_64-unknown-linux-musl
- name: Build ${{ inputs.binary }} with cargo
run: cargo build --bin ${{ inputs.binary }} --target x86_64-unknown-linux-musl --release
- name: Make artifact executable
run: chmod +x ./target/x86_64-unknown-linux-musl/release/${{ inputs.binary }}
- name: Run ${{ inputs.binary }}
run: ./target/x86_64-unknown-linux-musl/release/${{ inputs.binary }}
- name: Check working directory status
run: './scripts/check-git-status.sh'

0 comments on commit ca5219e

Please sign in to comment.