forked from vortex-data/vortex
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathaction.yml
More file actions
49 lines (45 loc) · 1.72 KB
/
action.yml
File metadata and controls
49 lines (45 loc) · 1.72 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
name: "Setup Prebuild"
description: "Prebuild AMIs — uses pre-installed tools, falls back to full setup-rust for forks"
inputs:
repo-token:
description: "GitHub token for accessing the repository (typically secrets.GITHUB_TOKEN)"
required: false
default: "${{ github.token }}"
toolchain:
description: "optional override for the toolchain version (e.g. nightly)"
required: false
components:
description: "optional override for the components to install for the step (e.g. clippy, rustfmt, miri)"
default: "clippy, rustfmt"
required: false
targets:
description: "optional targets override (e.g. wasm32-unknown-unknown)"
required: false
enable-sccache:
description: "Should sccache be enabled, true by default."
required: false
default: "true"
runs:
using: "composite"
steps:
# Prebuild path: tools already installed, just configure sccache
- name: Configure sccache timeout
if: github.repository == 'vortex-data/vortex' && inputs.enable-sccache == 'true'
shell: bash
run: |
mkdir -p ~/.config/sccache
echo 'server_startup_timeout_ms = 60000' > ~/.config/sccache/config
- name: Pre-start sccache server
if: github.repository == 'vortex-data/vortex' && inputs.enable-sccache == 'true'
shell: bash
run: sccache --start-server
# Fallback path: full setup for forks
- name: Full Rust setup
if: github.repository != 'vortex-data/vortex'
uses: ./.github/actions/setup-rust
with:
repo-token: ${{ inputs.repo-token }}
toolchain: ${{ inputs.toolchain }}
components: ${{ inputs.components }}
targets: ${{ inputs.targets }}
enable-sccache: ${{ inputs.enable-sccache }}