Skip to content

Install miniforge in macOS using Homebrew - #54

Merged
gcbeltramini merged 2 commits into
mainfrom
gb/miniforge-macos
Sep 8, 2026
Merged

Install miniforge in macOS using Homebrew#54
gcbeltramini merged 2 commits into
mainfrom
gb/miniforge-macos

Conversation

@gcbeltramini

Copy link
Copy Markdown
Owner

No description provided.

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

The Homebrew install branch hard-codes a Homebrew prefix-specific conda path, which can break on common macOS setups (e.g., Intel /usr/local or custom prefixes).

Once you've addressed the issues Copilot identified, you can request another Copilot review.

Pull request overview

This PR updates the Python setup command to prefer installing Miniforge on macOS via Homebrew (when available), and then uses a conda_bin variable so subsequent conda commands don’t assume a single install location.

Changes:

  • Add a macOS+Homebrew path that installs Miniforge using brew and sets conda_bin accordingly.
  • Keep the existing download-and-run-installer flow for non-brew installs (Linux and macOS without Homebrew).
  • Replace hard-coded ${HOME}/miniforge3/.../conda calls with "$conda_bin".
File summaries
File Description
commands/python/setup.sh Adds a Homebrew-based Miniforge install path on macOS and centralizes conda invocation via conda_bin.
Review details
  • Files reviewed: 1/1 changed files
  • Comments generated: 1
  • Review effort level: Lite

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread commands/python/setup.sh Outdated

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🔵 Needs a closer look

There are small but concrete robustness/documentation issues to address (help text no longer matches behavior on macOS with Homebrew, and an unquoted conditional can become a syntax error for empty input).

Review details

Suppressed comments (2)

Previously missed (2) — in code that hasn't changed since the last review.

commands/python/setup.sh:46

  • [[ $miniforge_version == "latest" ]] can become a syntax error if --miniforge-version= is provided (empty string), since it expands to [[ == "latest" ]]. Quoting the variable makes the test robust and avoids an early abort under set -e.
    commands/python/setup.sh:27
  • The help text for --miniforge-version says it controls the installed version, but on macOS with Homebrew available this option is intentionally ignored (only latest is installed). Updating the option description keeps --help accurate and avoids confusing users.
  • Files reviewed: 1/1 changed files
  • Comments generated: 0 new
  • Review effort level: Lite

@gcbeltramini
gcbeltramini merged commit 03cb2be into main Sep 8, 2026
2 checks passed
@gcbeltramini
gcbeltramini deleted the gb/miniforge-macos branch September 8, 2026 22:31
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants