init

A setup command that creates a GitHub Actions workflow, an automated check run by GitHub when code changes.

In plain words
What is it for?
Generating a workflow that installs env-doctor and runs its CI environment check.
Why use it?
It saves you from writing the workflow file by hand and helps check the environment on pushes and pull requests.

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/init
Clone the repo
git clone --depth 1 https://github.com/mitulgarg/env-doctor
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 496 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 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.00496
Opus 5 $0.00000 $0.00248
Sonnet 5 $0.00000 $0.00099
Haiku 4.5 $0.00000 $0.00050

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

Security

Grade A, and why

init scanned grade A with 0 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 2d 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.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

docs/commands/init.md · 82 lines

What it actually says

init

Generate CI/CD integration files for your project.

Usage

env-doctor init --github-actions

What It Does

Creates a .github/workflows/env-doctor.yml file in your project that runs env-doctor check --ci on every push and pull request to main/master.

The generated workflow:

  • Checks out your code
  • Sets up Python
  • Installs env-doctor
  • Runs env-doctor check --ci with proper exit codes

Options

Flag Description
--github-actions Generate a GitHub Actions workflow file
--force Overwrite the file if it already exists

Example

$ env-doctor init --github-actions
Created .github/workflows/env-doctor.yml

Next steps:
  1. Review and edit .github/workflows/env-doctor.yml to fit your project
  2. Commit and push to activate the workflow

Common customizations:
  - Change Python version to match your project
  - Change runner to [self-hosted, gpu] for GPU validation
  - Add 'env-doctor cuda-info --json' for detailed CUDA reports

Generated Workflow

name: Validate ML Environment

on:
  push:
    branches: [main, master]
  pull_request:
    branches: [main, master]

jobs:
  validate-env:
    runs-on: ubuntu-latest

    steps:
      - name: Checkout code
        uses: actions/checkout@v4

      - name: Set up Python
        uses: actions/setup-python@v5
        with:
          python-version: '3.10'

      - name: Install env-doctor
        run: pip install env-doctor

      - name: Validate environment
        run: env-doctor check --ci

After generating, customize the file to fit your project — change the Python version, switch to a GPU runner, or add extra steps like env-doctor cuda-info --json.

See Also

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. 2d ago First seen · 82 lines · 0 tokens per session scan A 7c8d2cad8272

Subscribe to this mod's changes

init is a command published in the GitHub repository mitulgarg/env-doctor (172 stars, last pushed 3d ago), licensed MIT. It costs nothing until one of its globs matches a file; then it loads 496 tokens. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.