# NousResearch/hermes-agent · CLI --env flag drops all but last value

## Open now

- 2 issues, 5 PRs open on GitHub.
- #37501: Bug: \`hermes mcp add\` ignores all but the last \`--env\` flag
- #45672: bug(cli): \`hermes mcp add --env KEY=VAL --env K2=V2\` silently keeps only the last value
- PR #37531: fix(hermes_cli/mcp): hermes mcp add ignores all but last --env flag
- PR #37587: Fix/cli bugs batch 37501 37472
- PR #37592: fix(cli): collect all --env flags in hermes mcp add (Fixes #37501)
- PR #45703: fix(cli): make --env flag repeatable for mcp add
- PR #80518: fix(mcp): preserve repeated env flags

Multiple reports and fix attempts address a bug where passing repeated --env flags to \`hermes mcp add\` silently discards all but the last one. Members include the bug reports, proposed fixes, and related feature additions around env/preset support.

## TL;DR

- 10 member(s): 2 open issue(s), 0 closed issue(s), 5 open PR(s), 0 merged PR(s), 3 PR(s) closed without merging.
- No fix has been merged to main; one or more PRs were attempted (see below).
- **Recommended:** review the prior/competing PR(s) below. A fix was attempted but not merged; your case may extend or revive that work.

## Maintainer resolution verdict

- Internal-tracker verdict over this cluster's issue members: `unresolved`. This is distinct from the fix status above. Weigh it yourself.

## How this cluster was grouped

- Link evidence (`STRUCTURAL_SPANNING`): every member is connected by structural evidence: shared changed files, or a closing/superseded reference.
- Pairwise link density `0.23`: the share of member pairs that carry a link, counting a structural link in full and a relevance-only link at 0.36. `1.00` means every pair is linked.

## Open related issues

- #37501: Bug: \`hermes mcp add\` ignores all but the last \`--env\` flag
- #45672: bug(cli): \`hermes mcp add --env KEY=VAL --env K2=V2\` silently keeps only the last value

## Prior & competing PRs

- **#37504: fix(cli): accumulate multiple --env flags in hermes mcp add**. closed without merge · fix tier `suggested`
  - maintainer direction: category `superseded_by_pr`; implication `superseded`; refs `#45718`, `#45718`
  - _suggested-tier fix detail withheld; re-request with `?tier=all` to include it._
- **#37531: fix(hermes_cli/mcp): hermes mcp add ignores all but last --env flag**. open
  - maintainer direction: category `partial_fix`; implication `needs_llm`; refs `#37469`, `#11902`, `#37501`, `#37469`, `#11902`
  - files: `hermes_cli/main.py`, `hermes_cli/mcp_config.py`, `tests/hermes_cli/test_mcp_config.py`
- **#37587: Fix/cli bugs batch 37501 37472**. open
  - maintainer direction: category `superseded_by_pr`; implication `superseded`
  - files: `hermes_cli/kanban_db.py`, `hermes_cli/subcommands/mcp.py`, `plugins/kanban/dashboard/plugin_api.py`, `tests/hermes_cli/test_kanban_db.py`, `tests/hermes_cli/test_mcp_add_env_repeat.py`
- **#37592: fix(cli): collect all --env flags in hermes mcp add (Fixes #37501)**. open
  - maintainer direction: category `duplicate_of`; implication `duplicate`; refs `#37504`, `#37531`, `#37587`, `#37504`
  - files: `hermes_cli/main.py`, `tests/hermes_cli/test_mcp_config.py`
- **#40084: fix(mcp): preserve repeated env flags**. closed without merge
  - maintainer direction: category `duplicate_of`; implication `duplicate`; refs `#37504`, `#37501`, `#37592`, `#37531`, `#37587`, `#37504`
- **#45703: fix(cli): make --env flag repeatable for mcp add**. open
  - maintainer direction: category `duplicate_of`; implication `duplicate`; refs `#37504`, `#37501`, `#45672`, `#37504`, `#37592`
  - files: `hermes_cli/subcommands/mcp.py`, `tests/hermes_cli/test_mcp_config.py`
- **#45718: fix(cli): accumulate repeated --env flags in \`hermes mcp add\`**. closed without merge
  - maintainer direction: category `duplicate_of`; implication `duplicate`; refs `#45703`
- **#80518: fix(mcp): preserve repeated env flags**. open
  - maintainer direction: category `partial_fix`; implication `needs_llm`; refs `#45703`, `#45703`, `#40084`, `#37501`, `#45672`, `#45703`, `#80518`, `#37501`, `#45672`
  - files: `hermes_cli/mcp_config.py`, `hermes_cli/subcommands/mcp.py`, `tests/hermes_cli/test_mcp_add_env_parser.py`, `tests/hermes_cli/test_mcp_config.py`

## Fix status

- No merged fix on record.
- Subsystem: `hermes_cli`
