cuda-install

cuda-install is a command for coding agents from mitulgarg/env-doctor. It costs 0 tokens per session (3,342 once invoked), scanned B, original, MIT.

An installation assistant for the CUDA Toolkit, software used to run many computing and machine-learning workloads on NVIDIA GPUs.

In plain words
What is it for?
Use it to detect a suitable CUDA version, preview or run installation commands, configure environment variables, verify the setup, or install a specified version.
Why use it?
It adapts installation instructions to your operating system, architecture, WSL2 setup, and NVIDIA driver instead of leaving you to match versions manually.

Command

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add commands/mitulgarg/env-doctor/cuda-install
Clone the repo
git clone --depth 1 https://github.com/mitulgarg/env-doctor

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for cuda-install

README.md
[![agentmods](https://agentmods.dev/badge/commands/mitulgarg/env-doctor/cuda-install.svg)](https://agentmods.dev/commands/mitulgarg/env-doctor/cuda-install)
Your own site
<a href="https://agentmods.dev/commands/mitulgarg/env-doctor/cuda-install"><img src="https://agentmods.dev/badge/commands/mitulgarg/env-doctor/cuda-install.svg" alt="Measured on agentmods" height="20"></a>
Per session 0 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 3,342 The whole file, excluding the scripts and references it only reads on demand.
Security scan B 2 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.00000 $0.03342
Opus 5 $0.00000 $0.01671
Sonnet 5 $0.00000 $0.00668
Haiku 4.5 $0.00000 $0.00334

Measured 5d ago against content hash 692041b5adda, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade B, and why

cuda-install scanned grade B with 2 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 5d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Asks for rootmediumPrivilege escalation

A mod that escalates privileges can change anything on the machine, not only the project.

2. sudo dpkg -i cuda-keyring_1.1-1_all.deb

Makes network callslowCapability

Not a fault in itself. Listed so you know the mod talks to something, and to what.

1. wget https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2204/x86_64/cuda-keyring_1.1-1_all.deb
docs/commands/cuda-install.md · 489 lines

How it starts

The opening of the file, as written. The whole thing — 489 lines — stays where its author put it; the contents beside it link to each section on GitHub.

cuda-install

Get step-by-step CUDA Toolkit installation instructions tailored to your platform.

Overview

The cuda-install command automatically:

  1. Detects your platform (OS, distribution, version, architecture, WSL2)
  2. Analyzes your GPU driver to determine the best CUDA version
  3. Provides copy-paste installation commands specific to your system
  4. Includes post-installation setup (environment variables, verification)
  5. Shows official download links for manual installation if needed

Usage

Auto-detect from GPU driver (recommended)

env-doctor cuda-install

This will:

  • Check your NVIDIA driver version
  • Recommend the best CUDA Toolkit version
  • Show platform-specific installation steps

Install specific CUDA version

env-doctor cuda-install 12.8
env-doctor cuda-install 12.4
env-doctor cuda-install 12.1
env-doctor cuda-install 11.8

Execute the installation

# Preview what would run (no changes made)
env-doctor cuda-install --dry-run

# Interactive install (asks [y/N] before running)
env-doctor cuda-install --run

# Headless install — skip confirmation (for CI/scripts)
env-doctor cuda-install --run --yes

# Specific version, headless
env-doctor cuda-install 12.6 --run --yes

Get JSON output (for automation/CI)

env-doctor cuda-install --json
env-doctor cuda-install 12.6 --json

# JSON output from a real install run
env-doctor cuda-install --run --yes --json

Returns structured JSON with platform info, recommended version, and install steps for machine processing.

Example Output

Linux (Ubuntu)

$ env-doctor cuda-install
============================================================
CUDA TOOLKIT INSTALLATION GUIDE
============================================================

Detected Platform:
    Linux (ubuntu 22.04, x86_64)

Driver: 535.146.02 (supports up to CUDA 12.2)
Recommended CUDA Toolkit: 12.1

============================================================
Ubuntu 22.04 (x86_64) - Network Install
============================================================

Installation Steps:
------------------------------------------------------------
    1. wget https://developer.download.nvidia.com/compute/cuda/repos/ubuntu2204/x86_64/cuda-keyring_1.1-1_all.deb
    2. sudo dpkg -i cuda-keyring_1.1-1_all.deb
    3. sudo apt-get update
    4. sudo apt-get -y install cuda-toolkit-12-1

Post-Installation Setup:
------------------------------------------------------------
    export PATH=/usr/local/cuda-12.1/bin${PATH:+:${PATH}}
    export LD_LIBRARY_PATH=/usr/local/cuda-12.1/lib64${LD_LIBRARY_PATH:+:${LD_LIBRARY_PATH}}

    TIP: Add the above exports to ~/.bashrc or ~/.zshrc

Verify Installation:
------------------------------------------------------------
    nvcc --version

Official Download Page:
    https://developer.nvidia.com/cuda-12-1-0-download-archive

============================================================
After installation, run 'env-doctor check' to verify.
============================================================

Read the full file on GitHub · 489 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 5d ago First seen · 489 lines · 0 tokens per session scan B 692041b5adda

Subscribe to this mod's changes

cuda-install is a command published in the GitHub repository mitulgarg/env-doctor (173 stars, last pushed 4d ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 3,342 tokens. A static security scan graded it B with 2 findings (asks for root, makes network calls). No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.