Skip to content
Draft
Show file tree
Hide file tree
Changes from all 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
5 changes: 4 additions & 1 deletion .github/workflows/build-cli-release.reusable.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,10 @@ jobs:
uses: ./.github/actions/setup-rust
with:
targets: ${{ matrix._.target }}
enable-cache: false
enable-cache: true
prefix-key: v2-rust-cli-${{ matrix._.target }}
cache-on-failure: true
workspace: engine

- name: Setup Go
uses: ./.github/actions/setup-go
Expand Down
19 changes: 19 additions & 0 deletions .github/workflows/build-python-release.reusable.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -95,6 +95,22 @@
- uses: actions/checkout@v4

# Setup Rust with caching for faster builds
- name: Setup Rust toolchain
uses: dtolnay/rust-toolchain@master

Check warning

Code scanning / CodeQL

Unpinned tag for a non-immutable Action in workflow Medium

Unpinned 3rd party Action 'BAML Release - Build Python' step
Uses Step
uses 'dtolnay/rust-toolchain' with ref 'master', not a pinned commit hash
with:
toolchain: "1.89.0"
targets: ${{ matrix._.target }}

- name: Setup Rust cache
uses: Swatinem/rust-cache@v2

Check warning

Code scanning / CodeQL

Unpinned tag for a non-immutable Action in workflow Medium

Unpinned 3rd party Action 'BAML Release - Build Python' step
Uses Step
uses 'Swatinem/rust-cache' with ref 'v2', not a pinned commit hash
with:
workspaces: engine
prefix-key: v1-python-${{ matrix._.target }}
cache-on-failure: true
# Cache the target directory for maturin builds
key: ${{ runner.os }}-rust-python-${{ matrix._.target }}-${{ hashFiles('**/Cargo.lock') }}

# Setup Python for non-ARM64 Windows targets and other OS
- name: Setup Python (default)
if: matrix._.target != 'aarch64-pc-windows-msvc'
Expand Down Expand Up @@ -152,6 +168,9 @@
- name: Install uv
uses: astral-sh/setup-uv@v6
with:
enable-cache: true
cache-dependency-glob: "**/pyproject.toml"

- name: Test LICENSE packaging
if: matrix._.license_test != 'skip'
Expand Down
3 changes: 2 additions & 1 deletion .github/workflows/build-typescript-release.reusable.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -107,8 +107,9 @@ jobs:
uses: ./.github/actions/setup-rust
with:
targets: ${{ matrix._.target }}
prefix-key: v5-rust-${{ matrix._.target }}
prefix-key: v6-rust-ts-${{ matrix._.target }}
cache-on-failure: true
workspace: engine

- name: Setup Go
uses: ./.github/actions/setup-go
Expand Down
8 changes: 4 additions & 4 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -58,11 +58,11 @@ jobs:
then
# Use sanitized tag name for version initially
VERSION=$(echo "$REF_NAME" | sed 's|/|-|g')
# Check if it's a release tag matching vX.Y.Z
if [[ "$REF_NAME" =~ ^[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
# Check if it's a release tag matching X.Y.Z or vX.Y.Z
if [[ "$REF_NAME" =~ ^v?[0-9]+\.[0-9]+\.[0-9]+$ ]]; then
IS_RELEASE="true"
# Use the exact tag name for releases
VERSION="$REF_NAME"
# Strip 'v' prefix if present for version string
VERSION="${REF_NAME#v}"
fi
fi

Expand Down
Loading