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

feat: avoid updating default macOS Ruby dependencies #245

Merged
merged 3 commits into from
Aug 18, 2023

Conversation

JavierCane
Copy link
Member

@JavierCane JavierCane commented Aug 17, 2023

Why:

  • Right now dotly tries to update all the Ruby dependencies from the Ruby installation that comes with macOS by default, but it fails in a lot of cases due to errors because the newer dependencies versions require an updated version of Ruby. Example:

    ERROR: Error installing irb:
    There are no versions of irb (= 1.7.4) compatible with your Ruby & RubyGems
    irb requires Ruby version >= 2.7. The current ruby version is 2.6.10.210.

  • Because these errors, dotly is not able to update these dependencies so it will indefinitely try to do so on each up command execution. This permanently increases the command execution time and adds noise to the command output.
  • It is not recommended to update the default Ruby installation that comes with macOS because the 2.6 version is included for compatibility with legacy software.
  • Based on the previous point, updating the default dependencies that comes with that version of Ruby does not seems like a good option because it could break that legacy software compatibility, however, if we would want to go that route we would face other problems:
    • Requiring dotly users to install rbenv, ruby with brew, or something similar in order to replace the default Ruby installation with a newer one just because being able to update the dependencies seems to be adding unnecessary steps to the dotly installation, specially when these users may not even use Ruby
    • Adding an updated version of Ruby with dotly seems to be adding unnecessary dependencies to the default dotly installation
  • macOS is planning to remove that default Ruby installation

Conclusion: We would opt for avoiding to update the default Ruby installation. If you do not develop with Ruby but just have it because it comes by default with the macOS installation, you probably do not bother to maintain these dependencies updated. Even if it bothers you, updating these dependencies could break some legacy compatibility which is the primary reason why they are there.

@rgomezcasas rgomezcasas merged commit f9d08f8 into main Aug 18, 2023
4 checks passed
@rgomezcasas rgomezcasas deleted the no-update-default-ruby branch August 18, 2023 08:14
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