Skip to content

Add copilot-setup-steps.yml for GitHub Copilot Coding Agent #2

Add copilot-setup-steps.yml for GitHub Copilot Coding Agent

Add copilot-setup-steps.yml for GitHub Copilot Coding Agent #2

##############################
# THIS FILE IS AUTOGENERATED #
# DO NOT MANUALLY EDIT #
##############################
# Copyright (c) Microsoft Corporation.
# Licensed under the MIT License.
# GitHub Copilot setup steps for OpenVMM development environment
# Generated by flowey_hvlite - DO NOT EDIT MANUALLY
name: "Copilot Setup Steps"
# Automatically run the setup steps when they are changed to allow for easy validation, and
# allow manual testing through the repository's "Actions" tab
on:
workflow_dispatch:
push:
paths:
- .github/workflows/copilot-setup-steps.yaml
pull_request:
paths:
- .github/workflows/copilot-setup-steps.yaml
jobs:
# The job MUST be called `copilot-setup-steps` or it will not be picked up by Copilot.
copilot-setup-steps:
runs-on: ubuntu-latest
# Set the permissions to the lowest permissions possible needed for your steps.
# Copilot will be given its own token for its operations.
permissions:
# If you want to clone the repository as part of your setup steps, for example to install dependencies, you'll need the `contents: read` permission. If you don't clone the repository in your setup steps, Copilot will do this for you automatically after the steps complete.
contents: read
steps:
- name: Install Rust with required targets
run: |
# Install Rust using rustup (version managed by flowey)
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh -s -- -y --default-toolchain=1.88.0
source ~/.cargo/env
# Install targets for the host architecture
ARCH=$(uname -m)
if [ "$ARCH" = "x86_64" ]; then
rustup target add x86_64-unknown-linux-musl
elif [ "$ARCH" = "aarch64" ]; then
rustup target add aarch64-unknown-linux-musl
fi
- name: Install system dependencies
run: |
# Update package lists with retry logic (from CI pipelines)
set -x
i=0; while [ $i -lt 5 ] && ! sudo apt-get update; do let "i=i+1"; sleep 1; done;
# Install build dependencies required for OpenVMM
sudo apt-get -o DPkg::Lock::Timeout=60 install -y \
binutils \
build-essential \
gcc \
gcc-aarch64-linux-gnu \
libssl-dev \
pkg-config
- name: Checkout repository
uses: actions/checkout@v4
- name: Restore OpenVMM build dependencies
run: |
# Restore external dependencies required for building OpenVMM
# This includes protoc (Protocol Buffers compiler), mu_msvm UEFI firmware,
# test Linux kernels, and other build artifacts
cargo xflowey restore-packages
# Install cargo-nextest for running unit tests (version managed by flowey)
cargo install cargo-nextest --version 0.9.96 --locked