[GH-ISSUE #533] Add more feature options to Homebrew formula #1241

Closed
opened 2026-03-14 14:04:30 +03:00 by kerem · 1 comment
Owner

Originally created by @juliusdelta on GitHub (Aug 6, 2024).
Original GitHub issue: https://github.com/aome510/spotify-player/issues/533

Is your feature already implemented in the latest master?
No

Is your feature request related to a problem? Please describe.
Using Homebrew install spotify-player on MacOS yields some limitations in some of the features the project has to offer, namely, the choice to use the daemon. I instead have to install with Cargo straight away instead of having an option available in the Homebrew Formula.

Describe the solution you'd like
I'd like to implement a --with-daemon flag to the Homebrew Formula which will of course need to build without media-control but build with daemon feature.

I personally don't mind opening a PR my self, I just wanted to know if there was a specific reason this hadn't been implemented yet. I'd also be willing to add some other flags as well like --with-fzf.

Describe alternatives you've considered
It's probably ok to require users to install via cargo in order to get this additional feature, however, it's less convenient that being able to just do it from brew install.

Additional context
According to the Homebrew documentation adding this would as easy as adding the following (untested code) to the Homebrew formula:

# ...
 option "with-daemon", "Daemon support. Media-control will be disabled as a result"
 option "with-fzf", "Fuzzy search support. FZF is required."

# ...
  def install
    # Ensure that the `openssl` crate picks up the intended library.
    ENV["OPENSSL_DIR"] = Formula["openssl@3"].opt_prefix
    ENV["OPENSSL_NO_VENDOR"] = "1"

    default_features = [
      "image",
      "lyric-finder",
      "notify",
    ]

    with_daemon_features = [
      *default_features,
      "daemon",
      "rodio-backend"
    ]

    cmd = ["cargo", "install"]

    features = build.with?("daemon") ? with_daemon_features : default_features 
    features << "fzf" if build_with? "fzf"


    cmd << "--no-default-features" if build.with? "daemon"
    cmd << features.join(",")
    cmd << *std_cargo_args(path: "spotify_player")

    system *cmd
    bin.install "target/release/spotify_player"
  end
Originally created by @juliusdelta on GitHub (Aug 6, 2024). Original GitHub issue: https://github.com/aome510/spotify-player/issues/533 **Is your feature already implemented in the latest `master`?** No **Is your feature request related to a problem? Please describe.** Using Homebrew install `spotify-player` on MacOS yields some limitations in some of the features the project has to offer, namely, the choice to use the daemon. I instead have to install with Cargo straight away instead of having an option available in the Homebrew Formula. **Describe the solution you'd like** I'd like to implement a `--with-daemon` flag to the Homebrew Formula which will of course need to build without `media-control` but build with `daemon` feature. I personally don't mind opening a PR my self, I just wanted to know if there was a specific reason this hadn't been implemented yet. I'd also be willing to add some other flags as well like `--with-fzf`. **Describe alternatives you've considered** It's probably _ok_ to require users to install via `cargo` in order to get this additional feature, however, it's less *convenient* that being able to just do it from `brew install`. **Additional context** [According to the Homebrew documentation](https://docs.brew.sh/Formula-Cookbook#adding-optional-steps) adding this would as easy as adding the following (untested code) to the [Homebrew formula](https://github.com/Homebrew/homebrew-core/blob/cb58a87ee9817be3d7b315c9a2b8e42c70790718/Formula/s/spotify_player.rb): ```ruby # ... option "with-daemon", "Daemon support. Media-control will be disabled as a result" option "with-fzf", "Fuzzy search support. FZF is required." # ... def install # Ensure that the `openssl` crate picks up the intended library. ENV["OPENSSL_DIR"] = Formula["openssl@3"].opt_prefix ENV["OPENSSL_NO_VENDOR"] = "1" default_features = [ "image", "lyric-finder", "notify", ] with_daemon_features = [ *default_features, "daemon", "rodio-backend" ] cmd = ["cargo", "install"] features = build.with?("daemon") ? with_daemon_features : default_features features << "fzf" if build_with? "fzf" cmd << "--no-default-features" if build.with? "daemon" cmd << features.join(",") cmd << *std_cargo_args(path: "spotify_player") system *cmd bin.install "target/release/spotify_player" end ```
kerem 2026-03-14 14:04:30 +03:00
Author
Owner

@aome510 commented on GitHub (Aug 6, 2024):

Please create an issue in the corresponding homebrew repo or email the maintainer of spotify_player brew formula. This repo is not responsible for any external packages.

<!-- gh-comment-id:2271745675 --> @aome510 commented on GitHub (Aug 6, 2024): Please create an issue in the corresponding homebrew repo or email the maintainer of `spotify_player` brew formula. This repo is not responsible for any external packages.
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#1241
No description provided.