Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

download miniforge instead of mambaforge #60

Merged
merged 1 commit into from
Nov 3, 2024
Merged

download miniforge instead of mambaforge #60

merged 1 commit into from
Nov 3, 2024

Conversation

bgruening
Copy link
Member

I hope this will get us going. Ideally we would need to change all occurrences of MAMBAFORGE with MINIFORGE. But this is a larger surgery in multiple repos I think.

Copy link

coderabbitai bot commented Nov 2, 2024

Walkthrough

The install-and-set-up-conda.sh script has been modified to transition from using Mambaforge to Miniforge for installation. The variable previously named MAMBAFORGE_URL has been changed to MINIFORGE_URL, which now points to the Miniforge installation script. The script's echo and curl commands have been updated accordingly to ensure the correct script is downloaded.

The script maintains its existing logic for verifying the presence of required files and variables, with distinct handling for macOS and Linux installations. For macOS, the script includes commands to remove any existing installations and adjust permissions, while the Linux section focuses on creating the necessary directory structure.

The conditional installation of bioconda-utils is still dependent on the BIOCONDA_DISABLE_BUILD_PREP variable, which is evaluated before the installation of dependencies and the creation of the conda environment. The script continues to establish a local channel for conda packages and concludes by displaying the configuration and environment list. Overall, the primary changes involve the renaming of the installation URL and related variables, while the fundamental structure and functionality of the script remain unchanged.


Thank you for using CodeRabbit. We offer it for free to the OSS community and would appreciate your support in helping us grow. If you find it useful, would you consider giving us a shout-out on your favorite social media?

❤️ Share
🪧 Tips

Chat

There are 3 ways to chat with CodeRabbit:

  • Review comments: Directly reply to a review comment made by CodeRabbit. Example:
    • I pushed a fix in commit <commit_id>, please review it.
    • Generate unit testing code for this file.
    • Open a follow-up GitHub issue for this discussion.
  • Files and specific lines of code (under the "Files changed" tab): Tag @coderabbitai in a new review comment at the desired location with your query. Examples:
    • @coderabbitai generate unit testing code for this file.
    • @coderabbitai modularize this function.
  • PR comments: Tag @coderabbitai in a new PR comment to ask questions about the PR branch. For the best results, please provide a very specific query, as very limited context is provided in this mode. Examples:
    • @coderabbitai gather interesting stats about this repository and render them as a table. Additionally, render a pie chart showing the language distribution in the codebase.
    • @coderabbitai read src/utils.ts and generate unit testing code.
    • @coderabbitai read the files in the src/scheduler package and generate a class diagram using mermaid and a README in the markdown format.
    • @coderabbitai help me debug CodeRabbit configuration file.

Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments.

CodeRabbit Commands (Invoked using PR comments)

  • @coderabbitai pause to pause the reviews on a PR.
  • @coderabbitai resume to resume the paused reviews.
  • @coderabbitai review to trigger an incremental review. This is useful when automatic reviews are disabled for the repository.
  • @coderabbitai full review to do a full review from scratch and review all the files again.
  • @coderabbitai summary to regenerate the summary of the PR.
  • @coderabbitai resolve resolve all the CodeRabbit review comments.
  • @coderabbitai configuration to show the current CodeRabbit configuration for the repository.
  • @coderabbitai help to get help.

Other keywords and placeholders

  • Add @coderabbitai ignore anywhere in the PR description to prevent this PR from being reviewed.
  • Add @coderabbitai summary to generate the high-level summary at a specific location in the PR description.
  • Add @coderabbitai anywhere in the PR title to generate the title automatically.

CodeRabbit Configuration File (.coderabbit.yaml)

  • You can programmatically configure CodeRabbit by adding a .coderabbit.yaml file to the root of your repository.
  • Please see the configuration documentation for more information.
  • If your editor has YAML language server enabled, you can add the path at the top of this file to enable auto-completion and validation: # yaml-language-server: $schema=https://coderabbit.ai/integrations/schema.v2.json

Documentation and Community

  • Visit our Documentation for detailed information on how to use CodeRabbit.
  • Join our Discord Community to get help, request features, and share feedback.
  • Follow us on X/Twitter for updates and announcements.

Copy link

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

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

Actionable comments posted: 0

🧹 Outside diff range and nitpick comments (4)
install-and-set-up-conda.sh (4)

Line range hint 3-7: Update script documentation to reflect Miniforge usage

The comments still reference "mambaforge" but should be updated to "miniforge" for consistency with the changes being made.

-# - Installs mambaforge to ${HOME}/mambaforge. Version is determined by common.sh,
+# - Installs miniforge to ${HOME}/miniforge. Version is determined by common.sh,

53-58: Update local filename for consistency

While the URL has been updated to use Miniforge, the local filename is still "mambaforge.sh". This should be updated for consistency.

 MINIFORGE_URL="https://github.com/conda-forge/miniforge/releases/download/${MAMBAFORGE_VER}/Miniforge3-${MAMBAFORGE_VER}-${OS}-${ARCH}.sh"
 
-echo Download ${MINIFORGE_URL}
-curl -L ${MINIFORGE_URL} > mambaforge.sh
-head mambaforge.sh
-bash mambaforge.sh -b -p "${MAMBAFORGE_INSTALLATION_DIR}"
+echo "Download ${MINIFORGE_URL}"
+curl -L ${MINIFORGE_URL} > miniforge.sh
+head miniforge.sh
+bash miniforge.sh -b -p "${MAMBAFORGE_INSTALLATION_DIR}"

Line range hint 82-93: Complete the transition by updating installation paths

The script still uses MAMBAFORGE_INSTALLATION_DIR for various operations. For a complete transition, consider updating:

  1. Installation directory variable and references
  2. Directory creation commands
  3. Environment setup paths

This should be coordinated with changes in common.sh and other dependent repositories. Consider:

  1. Creating a migration plan
  2. Testing the changes in a staging environment
  3. Updating all dependent scripts and documentation

Would you like assistance in creating a comprehensive migration plan?


Variables need to be updated to reflect Miniforge transition

The review comment is correct. Based on the file contents, there's a clear inconsistency where the code uses Miniforge URL and installation but still refers to variables with "mambaforge" naming. Specifically:

  • In common.sh: Variables MAMBAFORGE_VER and MAMBAFORGE_INSTALLATION_DIR need to be renamed
  • In configure-conda.sh: References to MAMBAFORGE_INSTALLATION_DIR
  • In install-and-set-up-conda.sh: References to both variables and comments mentioning mambaforge

The changes needed:

  • Rename MAMBAFORGE_VER to MINIFORGE_VER
  • Rename MAMBAFORGE_INSTALLATION_DIR to MINIFORGE_INSTALLATION_DIR
  • Update all references in the three affected files
  • Update comments to reflect Miniforge instead of Mambaforge
🔗 Analysis chain

Line range hint 19-26: Broader changes needed for complete transition

The script still relies on variables like MAMBAFORGE_VER and MAMBAFORGE_INSTALLATION_DIR from common.sh. These should be renamed to maintain consistency with the Miniforge transition.

Let's verify other potential dependencies:


Let me check the actual content of these files to understand the full context of the variable usage.

🏁 Scripts executed

The following scripts were executed for the analysis:

Script:

#!/bin/bash
# Search for any remaining mambaforge references in the repository
rg -i "mambaforge" --type-add 'script:*.{sh,bash}' --type script

Length of output: 343


Script:

#!/bin/bash
# Check content of relevant files
echo "=== common.sh ==="
cat common.sh
echo -e "\n=== configure-conda.sh ==="
cat configure-conda.sh
echo -e "\n=== install-and-set-up-conda.sh ==="
cat install-and-set-up-conda.sh

Length of output: 5743

📜 Review details

Configuration used: CodeRabbit UI
Review profile: CHILL

📥 Commits

Reviewing files that changed from the base of the PR and between 392641a and eaf8ebe.

📒 Files selected for processing (1)
  • install-and-set-up-conda.sh (1 hunks)
🔇 Additional comments (1)
install-and-set-up-conda.sh (1)

Line range hint 1-99: Overall transition strategy needed

While this PR initiates the transition from Mambaforge to Miniforge, several areas still need attention:

  1. Script documentation
  2. Variable names in common.sh
  3. Installation directory references
  4. Local file naming
  5. Dependencies in other repositories

Consider creating a comprehensive migration plan to coordinate these changes across all affected repositories.

Let's check for potential impacts:

#!/bin/bash
# Search for files that might need updates
echo "Files containing installation dir references:"
rg -l "MAMBAFORGE_INSTALLATION_DIR"

echo -e "\nFiles containing version references:"
rg -l "MAMBAFORGE_VER"

@bgruening bgruening merged commit ec7ec31 into master Nov 3, 2024
3 checks passed
@bgruening bgruening deleted the miniforge branch November 3, 2024 09:30
@bgruening
Copy link
Member Author

Thanks!

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