refactor(ncspot): nixify configuration
check / lint (push) Successful in 15s

This commit is contained in:
2026-09-28 21:03:34 +02:00
parent d35575326b
commit 178a51d75e
2 changed files with 53 additions and 48 deletions
-45
View File
@@ -1,45 +0,0 @@
default_keybindings = false
flip_status_indicators = true
library_tabs = ["tracks", "albums", "artists", "playlists", "browse"] # remove podcasts tab
[keybindings]
"Enter" = "play"
" " = "playpause"
"S" = "stop"
"<" = "seek -10000"
">" = "seek +10000"
"H" = "previous"
"L" = "next"
"r" = "repeat"
"z" = "shuffle"
"d" = "delete"
"s" = "save"
"O" = "open current"
"o" = "open selected"
"Backspace" = "back"
"A" = "goto artist"
"a" = "goto album"
"q" = "queue"
"J" = "shift down 1"
"K" = "shift up 1"
"c" = "clear"
"=" = "volup 1"
"-" = "voldown 1"
"1" = "focus queue"
"2" = "focus search"
"3" = "focus library"
"4" = "focus cover"
"h" = "move left 1"
"j" = "move down 1"
"k" = "move up 1"
"l" = "move right 1"
"g" = "move top"
"G" = "move bottom"
"t" = "sort added d"
"T" = "sort title a"
"y" = "share current"
"Y" = "share selected"
"U" = "update"
backend="pipe"
notify="false"
+53 -3
View File
@@ -2,7 +2,7 @@
config, config,
lib, lib,
pkgs, pkgs,
dotsPath, osConfig ? null,
... ...
}: }:
@@ -23,10 +23,60 @@ in
config = lib.mkIf cfg.enable { config = lib.mkIf cfg.enable {
home.packages = [ spotifyWithWayland ]; home.packages = [ spotifyWithWayland ];
programs.ncspot = { programs.ncspot = {
enable = true; enable = true;
settings = fromTOML (builtins.readFile (dotsPath + "/.config/ncspot/config.toml")); settings = {
backend = lib.mkIf (osConfig.audio.enable or false) (lib.mkDefault "pulseaudio");
default_keybindings = false;
flip_status_indicators = true;
library_tabs = [
"tracks"
"albums"
"artists"
"playlists"
"browse"
]; # remove podcasts tab
keybindings = {
"Enter" = "play";
" " = "playpause";
"S" = "stop";
"<" = "seek -10000";
">" = "seek +10000";
"H" = "previous";
"L" = "next";
"r" = "repeat";
"z" = "shuffle";
"d" = "delete";
"s" = "save";
"O" = "open current";
"o" = "open selected";
"Backspace" = "back";
"A" = "goto artist";
"a" = "goto album";
"q" = "queue";
"J" = "shift down 1";
"K" = "shift up 1";
"c" = "clear";
"=" = "volup 1";
"-" = "voldown 1";
"1" = "focus queue";
"2" = "focus search";
"3" = "focus library";
"4" = "focus cover";
"h" = "move left 1";
"j" = "move down 1";
"k" = "move up 1";
"l" = "move right 1";
"g" = "move top";
"G" = "move bottom";
"t" = "sort added d";
"T" = "sort title a";
"y" = "share current";
"Y" = "share selected";
"U" = "update";
notify = "false";
};
};
}; };
}; };
} }