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

librespot: init module #6229

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

librespot: init module #6229

wants to merge 1 commit into from

Conversation

9ary
Copy link
Contributor

@9ary 9ary commented Dec 23, 2024

Description

Librespot is a Spotify client. While there is already a module for spotifyd, which uses Librespot as a library, this adds one for the upstream frontend.

Checklist

  • Change is backwards compatible.

  • Code formatted with ./format.

  • Code tested through nix-shell --pure tests -A run.all or nix develop --ignore-environment .#all using Flakes.

  • Test cases updated/added. See example.

  • Commit messages are formatted like

    {component}: {description}
    
    {long description}
    

    See CONTRIBUTING for more information and recent commit messages for examples.

  • If this PR adds a new module

    • Added myself as module maintainer. See example.

Maintainer CC

@9ary
Copy link
Contributor Author

9ary commented Dec 23, 2024

This is the config I'm running:

services.librespot = {
  enable = true;
  settings = {
    disable-audio-cache = true;
    disable-discovery = true;
    enable-oauth = true;
    name = "${nixosConfig.networking.hostName}";
    backend = "pulseaudio";

    # Hands off
    initial-volume = 100;
    volume-ctrl = "fixed";

    bitrate = 320;
    enable-volume-normalisation = true;
    normalisation-method = "basic";
  };
};

As far as integration goes, I only bothered to set the default storage paths. Not sure what else there is to do really. Discovery requires firewall configuration at the NixOS level, we can't touch that. Setting the default backend to pulseaudio based on system configuration is a possibility but none of the other similar modules do this.

@9ary 9ary force-pushed the librespot branch 5 times, most recently from a6fd295 to fc573aa Compare December 29, 2024 13:30
Librespot is a Spotify client. While there is already a module for
spotifyd, which uses Librespot as a library, this adds one for the
upstream frontend.
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.

1 participant