---
title: "2026-09-02 Infrastructure GitHub CLI PR attachments"
description: "Verified GitHub CLI media attachment support and the macOS upgrade path for mono PR 368."
image: "https://docs.virdx.dev/img/virdx-social-card.png"
---

> Documentation Index
> Fetch the complete documentation index at: https://docs.virdx.dev/llms.txt
> Use this file to discover all available pages before exploring further.

# 2026-09-02 Infrastructure GitHub CLI PR attachments

## Work Done

- Inspected the installed GitHub CLI at `/opt/homebrew/bin/gh`; Homebrew had installed version 2.97.0, which does not expose `--attach` on pull request commands.
- Verified from the GitHub CLI 2.99.0 release, official attachment documentation, upstream source, and the official macOS arm64 binary that 2.99.0 is the minimum release with `--attach`.
- Confirmed that an updated Homebrew formula and conda-forge both provide version 2.99.0 on this macOS system.
- Provided exact `gh pr edit 368 --repo virdx/mono --attach '<path>#<alt text>'` commands for appending PNG screenshots to the pull request description while preserving its body, plus the `gh pr comment` alternative.
- Documented supported media formats, image size and batch limits, alt-text behavior, host support, and the repository write-access requirement.
- Referenced [GitHub CLI 2.99.0](https://github.com/cli/cli/releases/tag/v2.99.0), [Attaching files with GitHub CLI](https://docs.github.com/en/github-cli/github-cli/attaching-files-with-github-cli), and [mono PR 368](https://github.com/virdx/mono/pull/368).

## Lessons Learned: Pitfalls

- Homebrew's formula metadata initially reported 2.98.0 until `brew update`; checking installed and available versions without refreshing can incorrectly suggest that the required release is unavailable.
- Installing the Pixi package alone would not change plain `gh` resolution on this machine because `/opt/homebrew/bin` precedes `~/.pixi/bin` in `PATH`.
- The feature name can imply arbitrary file upload, but version 2.99.0 only accepts supported images and videos.

## Lessons Learned: Improvements

- A short infrastructure note about GitHub CLI tool ownership and `PATH` order would make future CLI upgrade choices faster.
- PR screenshot guidance should state that `gh pr edit --attach` updates the description without replacing the existing body when no body flag is supplied.

Source: https://docs.virdx.dev/knowledge/inbox/2026-09-02-infrastructure-github-cli-pr-attachments/index.mdx
