about summary refs log tree commit diff
path: root/home/flac/default.nix
blob: eaf3856ab1e1d337a1258f49b56e38760c883113 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
{ config, lib, pkgs, ... }:
let cfg = config.my.home.flac;
in {
  options.my.home.flac = with lib; {
    enable = mkEnableOption "flac configuration";
  };

  config.home.packages = with pkgs;
    lib.mkIf cfg.enable ([
      flac
      abcde
      (pkgs.writers.writeDashBin "rip-flac" ''
        ${pkgs.abcde}/bin/abcde -Vx -G -a "cddb,read,encode,tag,move,clean" -o flac
      '')
    ]);
}