fork/fish-shell

git clone https://git.julia.blue/fork/fish-shell

Johannes Altmanningerbuild_tools/update-dependencies.sha3b009dd4

master
1.1 KiB41 linesraw
1name: Rust Toolchain
2
3inputs:
4  toolchain_channel:
5    description: Either "stable" or "msrv"
6    required: true
7  targets:
8    description: Comma-separated list of target triples to install for this toolchain
9    required: false
10  components:
11    description: Comma-separated list of components to be additionally installed
12    required: false
13
14permissions:
15  contents: read
16
17runs:
18  using: "composite"
19  steps:
20    - name: Set toolchain
21      env:
22        toolchain_channel: ${{ inputs.toolchain_channel }}
23      shell: bash
24      run: |
25        set -x
26        toolchain=$(
27          case "$toolchain_channel" in
28            (stable) echo 1.96 ;; # updatecli.d/rust.yml
29            (msrv)   echo 1.85 ;; # updatecli.d/rust.yml
30            (*)
31              printf >&2 "error: unsupported toolchain channel %s" "$toolchain_channel"
32              exit 1
33              ;;
34          esac
35        )
36        printf 'TOOLCHAIN=%s\n' "$toolchain" >>"$GITHUB_ENV"
37    - uses: dtolnay/rust-toolchain@master
38      with:
39        toolchain: ${{ env.TOOLCHAIN }}
40        targets: ${{ inputs.targets }}
41        components: ${{ inputs.components }}