[GH-ISSUE #189] Homebrew support #99

Closed
opened 2026-03-02 23:44:30 +03:00 by kerem · 11 comments
Owner

Originally created by @flexwie on GitHub (May 5, 2023).
Original GitHub issue: https://github.com/aome510/spotify-player/issues/189

Is your feature request related to a problem? Please describe.
Using cargo to install the player is the easiest way for Mac users, but still requires to have the rust toolchain installed on the machine.

Describe the solution you'd like
Many if not most applications for Mac can be installed with Homebrew. It would be nice to have a formula to do so.

Describe alternatives you've considered
I guess a simple bash script that grabs the binaries from the releases would work as well, but its less elegant and won't support updating and uninstalling.

Originally created by @flexwie on GitHub (May 5, 2023). Original GitHub issue: https://github.com/aome510/spotify-player/issues/189 **Is your feature request related to a problem? Please describe.** Using cargo to install the player is the easiest way for Mac users, but still requires to have the rust toolchain installed on the machine. **Describe the solution you'd like** Many if not most applications for Mac can be installed with Homebrew. It would be nice to have a formula to do so. **Describe alternatives you've considered** I guess a simple bash script that grabs the binaries from the releases would work as well, but its less elegant and won't support updating and uninstalling.
kerem 2026-03-02 23:44:30 +03:00
Author
Owner

@aome510 commented on GitHub (May 5, 2023):

I don't have any experience dealing with homebrew before. Any help on this will be greatly appreciated.

<!-- gh-comment-id:1536378112 --> @aome510 commented on GitHub (May 5, 2023): I don't have any experience dealing with `homebrew` before. Any help on this will be greatly appreciated.
Author
Owner

@imNel commented on GitHub (May 7, 2023):

Basically you'll have to create a ruby file for spotify-player and then PR into homebrew-core. You can use the docs for adding a new formula or view the formula cookbook for more info :)

<!-- gh-comment-id:1537426696 --> @imNel commented on GitHub (May 7, 2023): Basically you'll have to create a ruby file for `spotify-player` and then PR into [homebrew-core](https://github.com/Homebrew/homebrew-core). You can use the docs for [adding a new formula](https://docs.brew.sh/Adding-Software-to-Homebrew) or view the [formula cookbook](https://docs.brew.sh/Formula-Cookbook) for more info :)
Author
Owner

@flexwie commented on GitHub (May 8, 2023):

I don't have any experience either so far, but I would be open to trying it out!

<!-- gh-comment-id:1537938283 --> @flexwie commented on GitHub (May 8, 2023): I don't have any experience either so far, but I would be open to trying it out!
Author
Owner

@tresni commented on GitHub (May 16, 2023):

I did this 3 weeks ago 😁 https://github.com/Homebrew/homebrew-core/pull/128997

Please test and 👍 that formula to try to get it bumped up for inclusion.

<!-- gh-comment-id:1548931101 --> @tresni commented on GitHub (May 16, 2023): I did this 3 weeks ago 😁 https://github.com/Homebrew/homebrew-core/pull/128997 Please test and :+1: that formula to try to get it bumped up for inclusion.
Author
Owner

@flexwie commented on GitHub (May 21, 2023):

Looks great! One thing I'd love to have is the ability to choose between the different features instead of installing them all. Maybe that could be done with options?

<!-- gh-comment-id:1556210533 --> @flexwie commented on GitHub (May 21, 2023): Looks great! One thing I'd love to have is the ability to choose between the different features instead of installing them all. Maybe that could be done with [options](https://docs.brew.sh/Formula-Cookbook#adding-optional-steps)?
Author
Owner

@tresni commented on GitHub (May 21, 2023):

That is possible. At one point I know it was being discouraged to have options in homebrew-core and instead to do that in a separate tap (similar to the ffmpeg example they give in the documentation.) I don't know if that's still the case, I'll do some grepping through the core formulas and see.

<!-- gh-comment-id:1556215018 --> @tresni commented on GitHub (May 21, 2023): That is possible. At one point I know it was being discouraged to have options in `homebrew-core` and instead to do that in a separate tap (similar to the ffmpeg example they give in the documentation.) I don't know if that's still the case, I'll do some grepping through the core formulas and see.
Author
Owner

@aome510 commented on GitHub (May 21, 2023):

https://github.com/Homebrew/homebrew-core/pull/128997/files#diff-9de770de980848d0bc612b5e6cb4910f1da3e81348b2dafbc877303fe477787dR21

IMO, it's better to install the application with default features. Not all non-default features work well without setting up or further configurations.

<!-- gh-comment-id:1556281277 --> @aome510 commented on GitHub (May 21, 2023): > https://github.com/Homebrew/homebrew-core/pull/128997/files#diff-9de770de980848d0bc612b5e6cb4910f1da3e81348b2dafbc877303fe477787dR21 IMO, it's better to install the application with default features. Not all non-default features work well without setting up or further configurations.
Author
Owner

@aome510 commented on GitHub (May 21, 2023):

Also thanks for the PR in the core repo, look forward to seeing it getting merged.

<!-- gh-comment-id:1556281413 --> @aome510 commented on GitHub (May 21, 2023): Also thanks for the PR in the core repo, look forward to seeing it getting merged.
Author
Owner

@tresni commented on GitHub (May 21, 2023):

Okay, confirming that you are not allowed to use options in homebrew/core:

  * 8: col 3: Formulae in homebrew/core should not use `option`.
  * 26: col 27: Formulae in homebrew/core should not use `build.with?`.
  * 27: col 27: Formulae in homebrew/core should not use `build.with?`.
  * 28: col 34: Formulae in homebrew/core should not use `build.with?`.
  * 29: col 29: Formulae in homebrew/core should not use `build.with?`.

Using the ffmpeg formula as a guide, it would appear that enabling some optional features would generally be the recommendation. I would suggest that we leave the formula as is unless I'm missing something and there are cases where enabling images,lyric-finder,notify could actually cause the application to not work. In my (all be it) limited testing, I didn't find any issues with having them enabled if the underlying system didn't support the feature (e.g. running in Terminal vs iTerm with images just lead to block display, I haven't found a way to make lyric-finder not work, etc)

<!-- gh-comment-id:1556300596 --> @tresni commented on GitHub (May 21, 2023): Okay, confirming that you are not allowed to use options in homebrew/core: ``` * 8: col 3: Formulae in homebrew/core should not use `option`. * 26: col 27: Formulae in homebrew/core should not use `build.with?`. * 27: col 27: Formulae in homebrew/core should not use `build.with?`. * 28: col 34: Formulae in homebrew/core should not use `build.with?`. * 29: col 29: Formulae in homebrew/core should not use `build.with?`. ``` Using the [ffmpeg formula](https://github.com/Homebrew/homebrew-core/blob/master/Formula/ffmpeg.rb) as a guide, it would appear that enabling some optional features would generally be the recommendation. I would suggest that we leave the formula as is unless I'm missing something and there are cases where enabling `images,lyric-finder,notify` could actually cause the application to not work. In my (all be it) limited testing, I didn't find any issues with having them enabled if the underlying system didn't support the feature (e.g. running in Terminal vs iTerm with `images` just lead to block display, I haven't found a way to make `lyric-finder` not work, etc)
Author
Owner

@aome510 commented on GitHub (May 22, 2023):

One case that lyric-finder doesn't work: https://github.com/aome510/spotify-player/issues/155. And image doesn't display a "nice-looking" image unless you use kitty or iTerm2. notify can be quite annoying if you don't really need one.

For me, I didn't find any problems with image and lyric-finder as my two additional features.

My point is that not all people need the features listed above and sometimes they may not work as expected. Using the default features provide a good and comfortable baseline. Users can always install the app with more features enabled if they want.

That said, the PR is still yours so feel free to leave as-is if that's what you think the best.

<!-- gh-comment-id:1556392538 --> @aome510 commented on GitHub (May 22, 2023): One case that `lyric-finder` doesn't work: https://github.com/aome510/spotify-player/issues/155. And `image` doesn't display a "nice-looking" image unless you use `kitty` or `iTerm2`. `notify` can be quite annoying if you don't really need one. For me, I didn't find any problems with `image` and `lyric-finder` as my two additional features. My point is that not all people need the features listed above and sometimes they may not work as expected. Using the default features provide a good and comfortable baseline. Users can always install the app with more features enabled if they want. That said, the PR is still yours so feel free to leave as-is if that's what you think the best.
Author
Owner

@aome510 commented on GitHub (Jun 10, 2023):

Close this as https://github.com/Homebrew/homebrew-core/pull/128997 has been merged.

<!-- gh-comment-id:1585844071 --> @aome510 commented on GitHub (Jun 10, 2023): Close this as https://github.com/Homebrew/homebrew-core/pull/128997 has been merged.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/spotify-player#99
No description provided.