mirror of
https://github.com/0xrsydn/idx-cli.git
synced 2026-11-07 01:35:36 +00:00
From the Codex re-gate of the 0.3.3 fixes: NUL-separated discovery fields need jq 1.7 (--raw-output0) and bash 4.4 (mapfile -d); check both up front with a clear message instead of failing midway on older tools. ci.yml actions are pinned to commit SHAs like the release workflows. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01V3syn2fN2LNo5pvTSqc6eh
53 lines
1.7 KiB
YAML
53 lines
1.7 KiB
YAML
name: CI
|
|
|
|
on:
|
|
push:
|
|
branches: [main]
|
|
pull_request:
|
|
|
|
permissions:
|
|
contents: read
|
|
|
|
concurrency:
|
|
group: ci-${{ github.workflow }}-${{ github.ref }}
|
|
cancel-in-progress: ${{ github.event_name == 'pull_request' }}
|
|
|
|
jobs:
|
|
# The same complete offline gate is used locally and in CI.
|
|
nix:
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262 # v4
|
|
|
|
- name: Install Nix
|
|
uses: cachix/install-nix-action@448cde739abec1eaf0646249e3d25bb8d9bc7702 # v31
|
|
|
|
- name: Restore and save Nix store
|
|
uses: nix-community/cache-nix-action@7df957e333c1e5da7721f60227dbba6d06080569 # v7
|
|
with:
|
|
primary-key: nix-v2-${{ runner.os }}-${{ runner.arch }}-${{ hashFiles('flake.nix', 'flake.lock', 'Cargo.lock', 'Cargo.toml') }}-${{ hashFiles('crates/**', 'scripts/**', 'install.sh', 'README.md', 'LICENSE') }}
|
|
restore-prefixes-first-match: |
|
|
nix-v2-${{ runner.os }}-${{ runner.arch }}-${{ hashFiles('flake.nix', 'flake.lock', 'Cargo.lock', 'Cargo.toml') }}-
|
|
nix-v2-${{ runner.os }}-${{ runner.arch }}-
|
|
gc-max-store-size-linux: 8G
|
|
|
|
- name: Flake check
|
|
run: nix flake check -L
|
|
|
|
# Keep native BSD/macOS tools in the installer portability check; the Linux
|
|
# sh/dash scenarios and ShellCheck are covered by the flake.
|
|
install-script:
|
|
runs-on: ${{ matrix.os }}
|
|
strategy:
|
|
fail-fast: false
|
|
matrix:
|
|
os: [macos-14]
|
|
|
|
steps:
|
|
- name: Checkout
|
|
uses: actions/checkout@11d5960a326750d5838078e36cf38b85af677262 # v4
|
|
|
|
- name: Test install.sh with sh
|
|
run: scripts/install-sh-test.sh
|