Problem
The generated Copilot agent job unconditionally runs:
- name: Install ripgrep
run: sudo apt-get update -qq && sudo apt-get install -y -qq ripgrep
Many custom/full runner images already include rg. Those jobs still update apt metadata, hit package infrastructure, and perform a privileged package-manager operation on every run.
This is emitted by gh-aw v0.85.4 before checkout for workflows using the Copilot engine; it is generated output, so consumers cannot cleanly optimize the step without patching lock files.
Suggested behavior
Probe first and install only when needed, for example:
if command -v rg >/dev/null 2>&1; then
rg --version
else
sudo apt-get update -qq
sudo apt-get install -y -qq ripgrep
fi
This preserves compatibility with minimal runner images while avoiding redundant network and package-manager work on pre-baked images.
Problem
The generated Copilot agent job unconditionally runs:
Many custom/full runner images already include
rg. Those jobs still update apt metadata, hit package infrastructure, and perform a privileged package-manager operation on every run.This is emitted by gh-aw v0.85.4 before checkout for workflows using the Copilot engine; it is generated output, so consumers cannot cleanly optimize the step without patching lock files.
Suggested behavior
Probe first and install only when needed, for example:
This preserves compatibility with minimal runner images while avoiding redundant network and package-manager work on pre-baked images.