Sdkman-cli: Feature: homewbrew formula

Created on 19 Sep 2020  路  6Comments  路  Source: sdkman/sdkman-cli

Hi!

It would be very nice to have a homebrew formula, current way with shell script installation is very inconvenient for automatic provisioning.

enhancement

Most helpful comment

But I can install for example the Google Chrome browser as cask. It also updates itself and does all kinds of things. I don't think the self-update feature is a blocker for implementing sdkman for brew cask.

All 6 comments

Hi @pshirshov!

Using brew for installing SDKMAN! sounds like a good idea in theory but seems to pose a few problems in practice:

  • brew discourages tools that update itself (like SDKMAN! does)
  • brew by design never modifies files outside HOMEBREW_PREFIX, so you would have to manually modify your .bash_profile to source SDKMAN's init script

The main problem I see is that people will do a brew install sdkman but (somehow understandably) skip the second step.

asdf, another popular version manager, describes the problem here.

brew discourages tools that update itself (like SDKMAN! does)

Though many packages do that.

brew by design never modifies files outside HOMEBREW_PREFIX, so you would have to manually modify your .bash_profile to source SDKMAN's init script

It's possible to add a post-install message to a homebrew package. E.g. try to install JDK on Catalina - and brew will tell you what steps you must take in order to get it working.

The main problem here is what @helpermethod stated above. SDKMAN updates itself, we would first have to do some development to disable this behaviour for brew installations. Also, sdkman has all it's files in user space (home folder), so it will probably be a problem for brew to manage these.

But I can install for example the Google Chrome browser as cask. It also updates itself and does all kinds of things. I don't think the self-update feature is a blocker for implementing sdkman for brew cask.

Was this page helpful?
0 / 5 - 0 ratings