Files
nyaterm/.github/actions/setup-rust/action.yml
T
Kang 010f1e4215 feat(agents): add Windows RDP support and remove ActiveX helper
- Introduced `nyaterm-windows-rdp` for Windows Native RDP integration, detailing its architecture and isolation requirements.
- Removed the `nyaterm-activex-helper` crate, including all related files and dependencies, to streamline the project and focus on modern RDP implementations.
- Updated documentation in `AGENTS.md` to reflect these changes and clarify the new architecture.
- Adjusted `Cargo.toml` and `Cargo.lock` to remove references to the deleted ActiveX helper and include the new RDP crate.
- Enhanced CI workflows to configure MSVC for Windows builds, ensuring compatibility with the new RDP implementation.
2026-11-02 19:17:20 +08:00

59 lines
1.9 KiB
YAML

name: Set up Rust
description: Install the Rust toolchain and restore the shared Cargo cache
inputs:
components:
description: Comma or space separated rustup components, e.g. "rustfmt, clippy"
required: false
default: ''
targets:
description: Additional rustup targets to install
required: false
default: ''
cache-key:
description: Extra discriminator appended to the rust-cache key
required: false
default: ''
cache-on-failure:
description: Save the cache even when the job fails
required: false
default: 'false'
save-cache:
description: >-
"auto" saves only from the trunk branches, so pull requests read the cache
without each writing a multi-gigabyte copy. "always" saves unconditionally
and is what tag builds want. "never" disables saving.
required: false
default: auto
runs:
using: composite
steps:
- name: Install Windows ATL toolchains
if: runner.os == 'Windows'
shell: pwsh
run: ./scripts/ci/install-msvc-atl.ps1
- name: Configure MSVC
if: runner.os == 'Windows'
uses: ilammy/msvc-dev-cmd@v1
with:
arch: ${{ contains(inputs.targets, 'aarch64') && 'amd64_arm64' || 'amd64' }}
- name: Install Rust toolchain
uses: dtolnay/rust-toolchain@stable
with:
components: ${{ inputs.components }}
targets: ${{ inputs.targets }}
# The workspace pins a dozen git dependencies, so ~/.cargo/git matters as much
# as the registry here.
- name: Restore Cargo cache
uses: Swatinem/rust-cache@v2
with:
key: ${{ inputs.cache-key }}
cache-on-failure: ${{ inputs.cache-on-failure }}
save-if: >-
${{ inputs.save-cache == 'always'
|| (inputs.save-cache == 'auto'
&& (github.ref == 'refs/heads/main'
|| github.ref == 'refs/heads/migration/gpui')) }}