This is an automated email from the ASF dual-hosted git repository.
kou pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/arrow-erlang.git
The following commit(s) were added to refs/heads/main by this push:
new 7c26382 chore: Use swatinem/rust-cache action for caching Rust (#102)
7c26382 is described below
commit 7c26382e93769ca4453cbeeec3d88604e4862aff
Author: Benjamin Philip <[email protected]>
AuthorDate: Thu Jul 9 06:25:59 2026 +0530
chore: Use swatinem/rust-cache action for caching Rust (#102)
## What's Changed
Uses swatinem/rust-cache for effectively caching Rust. Removes any
manual
caching. This will potentially lead to faster CIs since compiling Rust
is the
most time intensive common step.
---
.github/workflows/docs.yml | 19 +++++++------------
.github/workflows/erlang.yml | 31 +++++++++++++++++++------------
2 files changed, 26 insertions(+), 24 deletions(-)
diff --git a/.github/workflows/docs.yml b/.github/workflows/docs.yml
index 52c55b2..6eba671 100644
--- a/.github/workflows/docs.yml
+++ b/.github/workflows/docs.yml
@@ -36,23 +36,18 @@ jobs:
with:
persist-credentials: false
- - name: Cache Rust crates
- uses: actions/cache@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 # v6.1.0
- with:
- path: |
- ~/.cargo/bin/
- ~/.cargo/registry/index/
- ~/.cargo/registry/cache/
- ~/.cargo/git/db/
- key: test-native-${{ runner.os }}-${{ env.RUST_TOOLCHAIN_VERSION
}}-${{ hashFiles('native/**/Cargo.lock') }}
- restore-keys: |
- test-native-${{ runner.os }}-${{ env.RUST_TOOLCHAIN_VERSION }}
-
- name: Install Rust
uses: dtolnay/rust-toolchain@4be7066ada62dd38de10e7b70166bc74ed198c30
# stable
with:
toolchain: "${{ env.RUST_TOOLCHAIN_VERSION }}"
+ - name: Cache Rust packages
+ uses: swatinem/rust-cache@c19371144df3bb44fab255c43d04cbc2ab54d1c4 #
v2.9.1
+ with:
+ env-vars: "RUST_TOOLCHAIN_VERSION"
+ workspaces: |
+ native/arrow_format_nif
+
- name: Install Erlang/OTP
uses: erlef/setup-beam@54075bcc5e249e4758d363f27d099f55d843f124 #
v1.24.1
with:
diff --git a/.github/workflows/erlang.yml b/.github/workflows/erlang.yml
index f761999..06ff608 100644
--- a/.github/workflows/erlang.yml
+++ b/.github/workflows/erlang.yml
@@ -66,23 +66,18 @@ jobs:
with:
persist-credentials: false
- - name: Cache Rust crates
- uses: actions/cache@55cc8345863c7cc4c66a329aec7e433d2d1c52a9 # v6.1.0
- with:
- path: |
- ~/.cargo/bin/
- ~/.cargo/registry/index/
- ~/.cargo/registry/cache/
- ~/.cargo/git/db/
- key: test-native-${{ runner.os }}-${{ env.RUST_TOOLCHAIN_VERSION
}}-${{ hashFiles('native/**/Cargo.lock') }}
- restore-keys: |
- test-native-${{ runner.os }}-${{ env.RUST_TOOLCHAIN_VERSION }}
-
- name: Install Rust
uses: dtolnay/rust-toolchain@4be7066ada62dd38de10e7b70166bc74ed198c30
# stable
with:
toolchain: "${{ env.RUST_TOOLCHAIN_VERSION }}"
+ - name: Cache Rust packages
+ uses: swatinem/rust-cache@c19371144df3bb44fab255c43d04cbc2ab54d1c4 #
v2.9.1
+ with:
+ env-vars: "RUST_TOOLCHAIN_VERSION"
+ workspaces: |
+ native/arrow_format_nif
+
- name: Install Erlang/OTP
uses: erlef/setup-beam@54075bcc5e249e4758d363f27d099f55d843f124 #
v1.24.1
with:
@@ -112,6 +107,18 @@ jobs:
with:
persist-credentials: false
+ - name: Install Rust
+ uses: dtolnay/rust-toolchain@4be7066ada62dd38de10e7b70166bc74ed198c30
# stable
+ with:
+ toolchain: "${{ env.RUST_TOOLCHAIN_VERSION }}"
+
+ - name: Cache Rust packages
+ uses: swatinem/rust-cache@c19371144df3bb44fab255c43d04cbc2ab54d1c4 #
v2.9.1
+ with:
+ env-vars: "RUST_TOOLCHAIN_VERSION"
+ workspaces: |
+ native/arrow_format_nif
+
- name: Install Erlang/OTP
uses: erlef/setup-beam@54075bcc5e249e4758d363f27d099f55d843f124 #
v1.24.1
with: