Files
fish-shell/.github/actions/rust-toolchain/action.yml
Johannes Altmanninger daadd81ab6 More automation for updating dependencies
- Convert update checks in check.sh to mechanical updates.
  - Use https://www.updatecli.io/ for now, which is not as
    full-featured as renovatebot or dependabot, but I found it easier
    to plug arbitrary shell scripts into.
- Add updaters for
  - ubuntu-latest-lts (which is similar to GitHub Action's "ubuntu-latest").
  - FreeBSD image used in Cirrus (requires "gcloud auth login" for now,
    see https://github.com/cirruslabs/cirrus-ci-docs/issues/1315)
  - littlecheck and widecharwidth
- Update all dependencies except Cargo ones.
- As a reminder, our version policies are arbitrary and can be changed
  as needed.
- To-do:
  - Add updaters for GitHub Actions (such as "actions/checkout").
    Renovatebot could do that.
2025-11-01 12:55:01 +01:00

42 lines
1.1 KiB
YAML

name: Rust Toolchain
inputs:
toolchain_channel:
description: Either "stable" or "msrv"
required: true
targets:
description: Comma-separated list of target triples to install for this toolchain
required: false
components:
description: Comma-separated list of components to be additionally installed
required: false
permissions:
contents: read
runs:
using: "composite"
steps:
- name: Set toolchain
env:
toolchain_channel: ${{ inputs.toolchain_channel }}
shell: bash
run: |
set -x
toolchain=$(
case "$toolchain_channel" in
(stable) echo 1.91 ;; # updatecli.d/rust.yml
(msrv) echo 1.85 ;; # updatecli.d/rust.yml
(*)
printf >&2 "error: unsupported toolchain channel %s" "$toolchain_channel"
exit 1
;;
esac
)
printf 'TOOLCHAIN=%s\n' "$toolchain" >>"$GITHUB_ENV"
- uses: dtolnay/rust-toolchain@master
with:
toolchain: ${{ env.TOOLCHAIN }}
targets: ${{ inputs.targets }}
components: ${{ inputs.components }}