1

Compare commits

...

13 Commits

17 changed files with 632 additions and 174 deletions

View File

@ -0,0 +1,52 @@
{
lib,
stdenv,
stdenvNoCC,
}:
stdenv.mkDerivation {
pname = "TEMPLATE";
version = "";
src = ./.;
dontConfigure = true;
dontBuild = true;
doCheck = false;
installPhase = ''
runHook preInstall
mkdir -p $out
touch $out/TEMPLATE
runHook postInstall
'';
meta = with lib; {
description = "TEMPLATE";
homepage = "TEMPLATE";
license = licenses.mit;
};
}
# Or without cc:
# stdenvNoCC.mkDerivation {
# pname = "TEMPLATE";
# version = "";
#
# src = ./.;
#
# installPhase = ''
# runHook preInstall
#
# mkdir -p $out
# touch $out/TEMPLATE
#
# runHook postInstall
# '';
#
# meta = with lib; {
# description = "TEMPLATE";
# homepage = "TEMPLATE";
# license = licenses.mit;
# };
# }

View File

@ -4,4 +4,6 @@
... ...
}: { }: {
# Obsolete derivations are kept in "1_deprecated" for reference. # Obsolete derivations are kept in "1_deprecated" for reference.
monolisa = pkgs.callPackage ./monolisa {};
} }

Binary file not shown.

Binary file not shown.

View File

@ -0,0 +1,26 @@
{
lib,
stdenvNoCC,
}:
stdenvNoCC.mkDerivation {
pname = "monolisa";
version = "1.0";
src = ./.;
installPhase = ''
runHook preInstall
mkdir -p $out/share/fonts/truetype
mv MonoLisa-italic.ttf $out/share/fonts/truetype/
mv MonoLisa-normal.ttf $out/share/fonts/truetype/
runHook postInstall
'';
meta = with lib; {
description = "Programming Font with Ligatures and Cursives";
homepage = "https://www.monolisa.dev/";
license = licenses.mit;
};
}

37
flake.lock generated
View File

@ -1349,9 +1349,31 @@
"nixvim": "nixvim", "nixvim": "nixvim",
"nps": "nps", "nps": "nps",
"nur": "nur", "nur": "nur",
"spicetify-nix": "spicetify-nix",
"v4l2loopback-pinned": "v4l2loopback-pinned" "v4l2loopback-pinned": "v4l2loopback-pinned"
} }
}, },
"spicetify-nix": {
"inputs": {
"nixpkgs": [
"nixpkgs"
],
"systems": "systems_5"
},
"locked": {
"lastModified": 1751171964,
"narHash": "sha256-SeVvQm9ex+6BhDPIsRt9E1kSmMblQ6gTi53baphnX08=",
"owner": "Gerg-L",
"repo": "spicetify-nix",
"rev": "16adc163d966fc2bb5da47580df4602ae2c7a310",
"type": "github"
},
"original": {
"owner": "Gerg-L",
"repo": "spicetify-nix",
"type": "github"
}
},
"systems": { "systems": {
"locked": { "locked": {
"lastModified": 1689347949, "lastModified": 1689347949,
@ -1412,6 +1434,21 @@
"type": "github" "type": "github"
} }
}, },
"systems_5": {
"locked": {
"lastModified": 1681028828,
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
"owner": "nix-systems",
"repo": "default",
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
"type": "github"
},
"original": {
"owner": "nix-systems",
"repo": "default",
"type": "github"
}
},
"v4l2loopback-pinned": { "v4l2loopback-pinned": {
"locked": { "locked": {
"lastModified": 1748124733, "lastModified": 1748124733,

View File

@ -27,6 +27,10 @@
nur.url = "github:nix-community/NUR"; nur.url = "github:nix-community/NUR";
nur.inputs.nixpkgs.follows = "nixpkgs"; nur.inputs.nixpkgs.follows = "nixpkgs";
# Spicetify
spicetify-nix.url = "github:Gerg-L/spicetify-nix";
spicetify-nix.inputs.nixpkgs.follows = "nixpkgs";
# Ags for widgets (this was a terrible idea) # Ags for widgets (this was a terrible idea)
ags.url = "github:Aylur/ags"; ags.url = "github:Aylur/ags";
ags.inputs.nixpkgs.follows = "nixpkgs"; ags.inputs.nixpkgs.follows = "nixpkgs";

View File

@ -3,6 +3,7 @@
# The nixosConfig allows to access the toplevel system configuration from within home manager # The nixosConfig allows to access the toplevel system configuration from within home manager
# https://github.com/nix-community/home-manager/blob/586ac1fd58d2de10b926ce3d544b3179891e58cb/nixos/default.nix#L19 # https://github.com/nix-community/home-manager/blob/586ac1fd58d2de10b926ce3d544b3179891e58cb/nixos/default.nix#L19
{ {
inputs,
hostname, hostname,
username, username,
lib, lib,
@ -48,7 +49,8 @@ rec {
enable = true; # You can't disable this enable = true; # You can't disable this
lightScheme = "catppuccin-latte"; lightScheme = "catppuccin-latte";
darkScheme = "catppuccin-mocha"; darkScheme = "catppuccin-mocha";
font = "JetBrainsMono Nerd Font Mono"; # font = "JetBrainsMono Nerd Font Mono";
font = builtins.head nixosConfig.fonts.fontconfig.defaultFonts.monospace;
}; };
docs.enable = true; docs.enable = true;
@ -510,11 +512,12 @@ rec {
}; };
lyrics = { lyrics = {
auto = "yes";
synced = "yes"; # prefer synced lyrics if provided synced = "yes"; # prefer synced lyrics if provided
}; };
replaygain = { replaygain = {
auto = "yes"; # analyze on import automatically auto = "no"; # analyze on import automatically
backend = "ffmpeg"; backend = "ffmpeg";
overwrite = true; # re-analyze files with existing replaygain tags on import overwrite = true; # re-analyze files with existing replaygain tags on import
}; };
@ -523,6 +526,39 @@ rec {
btop.enable = true; btop.enable = true;
cava = {
enable = true;
settings = {
general = {
framerate = 60; # default 60
autosens = 1; # default 1
sensitivity = 100; # default 100
lower_cutoff_freq = 50; # not passed to cava if not provided
higher_cutoff_freq = 10000; # not passed to cava if not provided
};
smoothing = {
noise_reduction = 77; # default 77
monstercat = false; # default false
waves = false; # default false
};
color = {
# https://github.com/catppuccin/cava/blob/main/themes/latte-transparent.cava
gradient = 1;
gradient_color_1 = "'#179299'";
gradient_color_2 = "'#04a5e5'";
gradient_color_3 = "'#209fb5'";
gradient_color_4 = "'#1e66f5'";
gradient_color_5 = "'#8839ef'";
gradient_color_6 = "'#ea76cb'";
gradient_color_7 = "'#e64553'";
gradient_color_8 = "'#d20f39'";
};
};
};
direnv = { direnv = {
enable = true; enable = true;
nix-direnv.enable = true; nix-direnv.enable = true;
@ -685,8 +721,31 @@ rec {
nushell.enable = false; nushell.enable = false;
spicetify = let
spicePkgs = inputs.spicetify-nix.legacyPackages.${pkgs.system};
in {
enable = true;
# https://github.com/catppuccin/spicetify
theme = spicePkgs.themes.catppuccin;
colorScheme = "mocha";
wayland = true;
enabledExtensions = with spicePkgs.extensions; [
adblock
hidePodcasts
oneko # cat
];
# enabledCustomApps = with spicePkgs.apps; [];
enabledSnippets = with spicePkgs.snippets; [
rotatingCoverart
pointer
];
};
ssh = { ssh = {
enable = true; # NOTE: Do NOT generate .ssh/config using HM, as it will have invalid permissions! enable = true;
compression = true; compression = true;
matchBlocks = { matchBlocks = {
@ -924,6 +983,11 @@ rec {
run = "plugin smart-paste"; run = "plugin smart-paste";
desc = "Paste into hovered directory or CWD"; desc = "Paste into hovered directory or CWD";
} }
{
on = "d";
run = "remove --permanently";
desc = "Delete selection";
}
]; ];
}; };
}; };
@ -956,18 +1020,19 @@ rec {
# Don't start playback after startup # Don't start playback after startup
restore_paused "yes" restore_paused "yes"
# Use track tags on shuffle and album tags on album play # Use track tags on shuffle and album tags on album play (auto)
replaygain "auto" # Use album's tags (album)
# Use track's tags (track)
# replaygain "auto"
# PipeWire main output # PipeWire main output
audio_output { audio_output {
type "pipewire" type "pipewire"
name "PipeWire Sound Server" name "PipeWire Sound Server"
mixer_type "hardware"
# Use hardware mixer instead of software volume filter (replaygain_handler "software") # Use hardware mixer instead of software volume filter (replaygain_handler "software")
replay_gain_handler "mixer" # mixer_type "hardware"
# replay_gain_handler "mixer"
} }
# FiFo output for cava visualization # FiFo output for cava visualization
@ -1011,7 +1076,7 @@ rec {
packages = [ packages = [
"com.github.tchx84.Flatseal" "com.github.tchx84.Flatseal"
"com.spotify.Client" # "com.spotify.Client" # Don't need this when spicetify is enabled
# NOTE: Also change discord-ipc-0 below # NOTE: Also change discord-ipc-0 below
"com.discordapp.Discord" "com.discordapp.Discord"

View File

@ -23,5 +23,6 @@
inputs.nix-flatpak.homeManagerModules.nix-flatpak inputs.nix-flatpak.homeManagerModules.nix-flatpak
inputs.nixvim.homeManagerModules.nixvim inputs.nixvim.homeManagerModules.nixvim
inputs.ags.homeManagerModules.default inputs.ags.homeManagerModules.default
inputs.spicetify-nix.homeManagerModules.default
]; ];
} }

View File

@ -91,7 +91,7 @@ in {
"theme.bar.buttons.padding_x" = "10px"; "theme.bar.buttons.padding_x" = "10px";
"theme.bar.buttons.padding_y" = "2px"; "theme.bar.buttons.padding_y" = "2px";
"theme.bar.buttons.radius" = "6px"; "theme.bar.buttons.radius" = "6px";
"theme.bar.buttons.spacing" = "3px"; "theme.bar.buttons.spacing" = "2px"; # NOTE: Horizontal inter-button spacing
"theme.bar.buttons.style" = "default"; "theme.bar.buttons.style" = "default";
"theme.bar.buttons.text" = "#${color.hex.dark.base}"; "theme.bar.buttons.text" = "#${color.hex.dark.base}";
"theme.bar.buttons.y_margins" = "2px"; # NOTE: Top/Bottom bar padding "theme.bar.buttons.y_margins" = "2px"; # NOTE: Top/Bottom bar padding
@ -183,7 +183,7 @@ in {
# https://github.com/Jas-SinghFSU/HyprPanel/blob/master/src/configuration/modules/config/bar/cava/index.ts # https://github.com/Jas-SinghFSU/HyprPanel/blob/master/src/configuration/modules/config/bar/cava/index.ts
"bar.customModules.cava.showActiveOnly" = true; "bar.customModules.cava.showActiveOnly" = true;
"bar.customModules.cava.bars" = 10; "bar.customModules.cava.bars" = 10;
"bar.customModules.cava.leftClick" = "menu:media"; # "bar.customModules.cava.leftClick" = "menu:media";
# https://github.com/Jas-SinghFSU/HyprPanel/blob/master/src/configuration/modules/theme/bar/buttons/cava.ts # https://github.com/Jas-SinghFSU/HyprPanel/blob/master/src/configuration/modules/theme/bar/buttons/cava.ts
"theme.bar.buttons.modules.cava.background" = "#${color.hex.dark.red}"; "theme.bar.buttons.modules.cava.background" = "#${color.hex.dark.red}";

View File

@ -27,7 +27,10 @@ in {
"kitty_mod+l" = "next_layout"; "kitty_mod+l" = "next_layout";
}; };
settings = { settings = let
light = color.hex.light;
dark = color.hex.dark;
in {
editor = config.home.sessionVariables.EDITOR; editor = config.home.sessionVariables.EDITOR;
scrollback_lines = 10000; scrollback_lines = 10000;
window_padding_width = 10; # Looks stupid with editors if bg doesn't match window_padding_width = 10; # Looks stupid with editors if bg doesn't match
@ -48,74 +51,74 @@ in {
# #
# The basic colors # The basic colors
foreground = "#${color.hex.light.text}"; background = "#${light.base}";
background = "#${color.hex.light.base}"; foreground = "#${light.text}";
selection_foreground = "#${color.hex.light.base}"; selection_foreground = "#${light.base}";
selection_background = "#${color.hex.light.rosewater}"; selection_background = "#${light.rosewater}";
# Cursor colors # Cursor colors
cursor = "#${color.hex.light.rosewater}"; cursor = "#${light.rosewater}";
cursor_text_color = "#${color.hex.light.base}"; cursor_text_color = "#${light.base}";
# URL underline color when hovering with mouse # URL underline color when hovering with mouse
url_color = "#${color.hex.light.rosewater}"; url_color = "#${light.rosewater}";
# Kitty window border colors # Kitty window border colors
active_border_color = "#${color.hex.light.lavender}"; active_border_color = "#${light.lavender}";
inactive_border_color = "#${color.hex.light.overlay0}"; inactive_border_color = "#${light.overlay0}";
bell_border_color = "#${color.hex.light.yellow}"; bell_border_color = "#${light.yellow}";
# OS Window titlebar colors # OS Window titlebar colors
wayland_titlebar_color = "system"; wayland_titlebar_color = "system";
macos_titlebar_color = "system"; macos_titlebar_color = "system";
# Tab bar colors # Tab bar colors
active_tab_foreground = "#${color.hex.dark.base}"; active_tab_foreground = "#${dark.base}";
active_tab_background = "#${color.hex.dark.lavender}"; active_tab_background = "#${dark.lavender}";
inactive_tab_foreground = "#${color.hex.dark.text}"; inactive_tab_foreground = "#${dark.text}";
inactive_tab_background = "#${color.hex.dark.crust}"; inactive_tab_background = "#${dark.crust}";
tab_bar_background = "#${color.hex.light.base}"; tab_bar_background = "#${light.base}";
# Color for marks (marked text in the terminal) # Color for marks (marked text in the terminal)
mark1_foreground = "#${color.hex.light.base}"; mark1_foreground = "#${light.base}";
mark1_background = "#${color.hex.light.lavender}"; mark1_background = "#${light.lavender}";
mark2_foreground = "#${color.hex.light.base}"; mark2_foreground = "#${light.base}";
mark2_background = "#${color.hex.light.mauve}"; mark2_background = "#${light.mauve}";
mark3_foreground = "#${color.hex.light.base}"; mark3_foreground = "#${light.base}";
mark3_background = "#${color.hex.light.sapphire}"; mark3_background = "#${light.sapphire}";
# The 16 terminal colors # The 16 terminal colors
# black # black
color0 = "#${color.hex.light.subtext1}"; color0 = "#${light.subtext1}";
color8 = "#${color.hex.light.subtext0}"; color8 = "#${light.subtext0}";
# red # red
color1 = "#${color.hex.light.red}"; color1 = "#${light.red}";
color9 = "#${color.hex.light.red}"; color9 = "#${light.red}";
# green # green
color2 = "#${color.hex.light.green}"; color2 = "#${light.green}";
color10 = "#${color.hex.light.green}"; color10 = "#${light.green}";
# yellow # yellow
color3 = "#${color.hex.light.yellow}"; color3 = "#${light.yellow}";
color11 = "#${color.hex.light.yellow}"; color11 = "#${light.yellow}";
# blue # blue
color4 = "#${color.hex.light.blue}"; color4 = "#${light.blue}";
color12 = "#${color.hex.light.blue}"; color12 = "#${light.blue}";
# magenta # magenta
color5 = "#${color.hex.light.pink}"; color5 = "#${light.pink}";
color13 = "#${color.hex.light.pink}"; color13 = "#${light.pink}";
# cyan # cyan
color6 = "#${color.hex.light.teal}"; color6 = "#${light.teal}";
color14 = "#${color.hex.light.teal}"; color14 = "#${light.teal}";
# white # white
color7 = "#${color.hex.light.surface2}"; color7 = "#${light.surface2}";
color15 = "#${color.hex.light.surface1}"; color15 = "#${light.surface1}";
}; };
}; };
}; };

View File

@ -1643,6 +1643,7 @@ in {
cmd = ["ToggleTerm"]; cmd = ["ToggleTerm"];
keys = ["<C-/>"]; keys = ["<C-/>"];
config = mkDefaultConfig name; config = mkDefaultConfig name;
opts = { opts = {
open_mapping.__raw = "[[<C-/>]]"; open_mapping.__raw = "[[<C-/>]]";
autochdir = true; autochdir = true;
@ -1651,16 +1652,19 @@ in {
shading_factor = 30; # Default is -30 to darken the terminal shading_factor = 30; # Default is -30 to darken the terminal
start_in_insert = true; start_in_insert = true;
terminal_mappings = true; terminal_mappings = true;
persist_mode = true; size = 20;
persist_size = true;
persist_mode = false; # Don't persist the current mode (insert/normal)
insert_mappings = true; insert_mappings = true;
close_on_exit = true; close_on_exit = true;
shell = "fish"; shell = "fish";
direction = "horizontal"; # 'vertical' | 'horizontal' | 'window' | 'float' direction = "horizontal"; # 'vertical' | 'horizontal' | 'window' | 'float'
auto_scroll = true; auto_scroll = true;
float_opts = { float_opts = {
border = "curved"; # 'single' | 'double' | 'shadow' | 'curved' border = "curved"; # 'single' | 'double' | 'shadow' | 'curved'
width = 80; width = 80;
height = 45; height = 80;
winblend = 0; winblend = 0;
}; };
}; };

View File

@ -54,3 +54,12 @@ vim.api.nvim_create_user_command("ToggleAutoLint", function()
end, { end, {
desc = "Toggle autolint-on-save", desc = "Toggle autolint-on-save",
}) })
-- Toggle Rcmp
local Terminal = require("toggleterm.terminal").Terminal
local rmcp =
Terminal:new({ cmd = "rmpc", hidden = true, close_on_exit = true, auto_scroll = false, direction = "float" })
vim.g.toggle_rcmp = function()
rmcp:toggle()
end

View File

@ -18,7 +18,8 @@ if g.neovide then
-- g.neovide_theme = "light" -- g.neovide_theme = "light"
-- Neovide Fonts -- Neovide Fonts
o.guifont = "JetBrainsMono Nerd Font Mono:h12:Medium" -- o.guifont = "JetBrainsMono Nerd Font Mono:h12:Medium"
o.guifont = "MonoLisa:h12:Medium"
else else
-- require("notify").notify("Not running in NeoVide") -- require("notify").notify("Not running in NeoVide")
end end

View File

@ -324,10 +324,16 @@ _: let
} }
{ {
mode = "n"; mode = "n";
key = "<leader>r"; key = "<leader>R";
action = "<cmd>lua Snacks.picker.resume()<cr>"; action = "<cmd>lua Snacks.picker.resume()<cr>";
options.desc = "Last Picker"; options.desc = "Last Picker";
} }
{
mode = "n";
key = "<leader>r";
action = "<cmd>lua vim.g.toggle_rcmp()<cr>"; # Defined in extraConfigLua.lua
options.desc = "Show Rcmp";
}
{ {
mode = "n"; mode = "n";
key = "<leader>i"; key = "<leader>i";

View File

@ -6,7 +6,7 @@
pkgs, pkgs,
... ...
}: let }: let
inherit (config.modules) rmpc; inherit (config.modules) rmpc color;
in { in {
options.modules.rmpc = import ./options.nix {inherit lib mylib;}; options.modules.rmpc = import ./options.nix {inherit lib mylib;};
@ -20,7 +20,14 @@ in {
programs.rmpc.enable = true; programs.rmpc.enable = true;
home.file = { home.packages = with pkgs; [
cava
python313Packages.syncedlyrics
];
home.file = let
themeName = "chriphost";
in {
".config/rmpc/config.ron".text = '' ".config/rmpc/config.ron".text = ''
#![enable(implicit_some)] #![enable(implicit_some)]
#![enable(unwrap_newtypes)] #![enable(unwrap_newtypes)]
@ -28,9 +35,9 @@ in {
( (
address: "127.0.0.1:${builtins.toString config.services.mpd.network.port}", address: "127.0.0.1:${builtins.toString config.services.mpd.network.port}",
password: None, password: None,
theme: "chriphost", theme: "${themeName}",
cache_dir: None, cache_dir: None,
on_song_change: None, on_song_change: None, // TODO: notify-send song title or sth.
volume_step: 5, volume_step: 5,
max_fps: 30, max_fps: 30,
scrolloff: 0, scrolloff: 0,
@ -39,6 +46,7 @@ in {
enable_config_hot_reload: true, enable_config_hot_reload: true,
status_update_interval_ms: 1000, status_update_interval_ms: 1000,
rewind_to_start_sec: 30, rewind_to_start_sec: 30,
lyrics_dir: "${config.home.homeDirectory}/Music/.lyrics",
// Keep this on false, otherwise queue changes will be applied to the current playlist // Keep this on false, otherwise queue changes will be applied to the current playlist
reflect_changes_to_playlist: false, reflect_changes_to_playlist: false,
@ -53,25 +61,155 @@ in {
vertical_align: Center, vertical_align: Center,
horizontal_align: Center, horizontal_align: Center,
), ),
search: (
case_sensitive: false,
mode: Contains,
tags: [
(value: "any", label: "Any Tag"),
(value: "artist", label: "Artist"),
(value: "album", label: "Album"),
(value: "albumartist", label: "Album Artist"),
(value: "title", label: "Title"),
(value: "filename", label: "Filename"),
(value: "genre", label: "Genre"),
],
),
artists: (
album_display_mode: SplitByDate,
album_sort_by: Date,
),
tabs: [
(
name: "Queue",
pane: Split(
borders: "NONE",
direction: Horizontal,
panes: [
// Left Column (Queue + Cava)
(
size: "70%",
borders: "NONE",
pane: Split(
direction: Vertical,
panes: [
(
size: "75%",
borders: "ALL",
pane: Pane(Queue),
),
(
size: "25%",
borders: "ALL",
pane: Pane(Cava),
)
]
)
),
// Right Column (AlbumArt + Lyrics)
(
size: "30%",
borders: "NONE",
pane: Split(
direction: Vertical,
panes: [
(
size: "75%",
borders: "ALL",
pane: Pane(AlbumArt),
),
(
size: "25%",
borders: "ALL",
pane: Pane(Lyrics),
),
]
),
),
]
),
),
(
name: "Albums",
pane: Pane(Albums),
),
(
name: "Artists",
pane: Pane(Artists),
),
(
name: "Playlists",
pane: Pane(Playlists),
),
(
name: "Search",
pane: Pane(Search),
),
// (
// name: "Album Artists",
// pane: Pane(AlbumArtists),
// ),
// (
// name: "Directories",
// pane: Pane(Directories),
// ),
// (
// name: "Visualizer",
// pane: Pane(Cava),
// ),
],
cava: (
framerate: 60, // default 60
autosens: true, // default true
sensitivity: 100, // default 100
lower_cutoff_freq: 50, // not passed to cava if not provided
higher_cutoff_freq: 10000, // not passed to cava if not provided
input: (
method: Fifo,
source: "/tmp/mpd.fifo",
sample_rate: 44100,
channels: 2,
sample_bits: 16,
),
smoothing: (
noise_reduction: 77, // default 77
monstercat: false, // default false
waves: false, // default false
),
// this is a list of floating point numbers thats directly passed to cava
// they are passed in order that they are defined
eq: [],
),
keybinds: ( keybinds: (
global: { global: {
":": CommandMode, "q": Quit,
",": VolumeDown, "p": TogglePause,
"s": Stop, "s": Stop,
">": NextTrack,
"<": PreviousTrack,
",": VolumeDown,
".": VolumeUp, ".": VolumeUp,
":": CommandMode,
"<Tab>": NextTab, "<Tab>": NextTab,
"<S-Tab>": PreviousTab, "<S-Tab>": PreviousTab,
"1": SwitchToTab("Queue"), "1": SwitchToTab("Queue"),
"2": SwitchToTab("Directories"), "2": SwitchToTab("Albums"),
"3": SwitchToTab("Artists"), "3": SwitchToTab("Artists"),
"4": SwitchToTab("Album Artists"), "4": SwitchToTab("Playlists"),
"5": SwitchToTab("Albums"), "5": SwitchToTab("Search"),
"6": SwitchToTab("Playlists"), // " ": SwitchToTab("Visualizer"),
"7": SwitchToTab("Search"), // " ": SwitchToTab("Directories"),
"q": Quit, // " ": SwitchToTab("Album Artists"),
">": NextTrack,
"p": TogglePause,
"<": PreviousTrack,
"f": SeekForward, "f": SeekForward,
"z": ToggleRepeat, "z": ToggleRepeat,
"x": ToggleRandom, "x": ToggleRandom,
@ -95,28 +233,30 @@ in {
"<Down>": Down, "<Down>": Down,
"<Left>": Left, "<Left>": Left,
"<Right>": Right, "<Right>": Right,
"g": Top,
"G": Bottom,
"<C-u>": UpHalf,
"<C-d>": DownHalf,
"J": MoveDown,
"K": MoveUp,
"<C-k>": PaneUp, "<C-k>": PaneUp,
"<C-j>": PaneDown, "<C-j>": PaneDown,
"<C-h>": PaneLeft, "<C-h>": PaneLeft,
"<C-l>": PaneRight, "<C-l>": PaneRight,
"<C-u>": UpHalf,
"N": PreviousResult, "N": PreviousResult,
"a": Add, "a": Add,
"A": AddAll, "A": AddAll,
"r": Rename, "r": Rename,
"n": NextResult, "n": NextResult,
"g": Top,
"<Space>": Select, "<Space>": Select,
"<C-Space>": InvertSelection, "<C-Space>": InvertSelection,
"G": Bottom,
"<CR>": Confirm, "<CR>": Confirm,
"i": FocusInput, "i": FocusInput,
"J": MoveDown,
"<C-d>": DownHalf,
"/": EnterSearch, "/": EnterSearch,
"<C-c>": Close, "<C-c>": Close,
"<Esc>": Close, "<Esc>": Close,
"K": MoveUp,
"D": Delete, "D": Delete,
"B": ShowInfo, "B": ShowInfo,
}, },
@ -130,60 +270,19 @@ in {
"X": Shuffle, "X": Shuffle,
}, },
), ),
search: (
case_sensitive: false,
mode: Contains,
tags: [
(value: "any", label: "Any Tag"),
(value: "artist", label: "Artist"),
(value: "album", label: "Album"),
(value: "albumartist", label: "Album Artist"),
(value: "title", label: "Title"),
(value: "filename", label: "Filename"),
(value: "genre", label: "Genre"),
],
),
artists: (
album_display_mode: SplitByDate,
album_sort_by: Date,
),
tabs: [
(
name: "Queue",
pane: Split(
direction: Horizontal,
panes: [(size: "40%", pane: Pane(AlbumArt)), (size: "60%", pane: Pane(Queue))],
),
),
(
name: "Directories",
pane: Pane(Directories),
),
(
name: "Artists",
pane: Pane(Artists),
),
(
name: "Album Artists",
pane: Pane(AlbumArtists),
),
(
name: "Albums",
pane: Pane(Albums),
),
(
name: "Playlists",
pane: Pane(Playlists),
),
(
name: "Search",
pane: Pane(Search),
),
],
) )
''; '';
".config/rmpc/themes/chriphost.ron".text = '' ".config/rmpc/themes/${themeName}.ron".text = let
light = color.hex.light;
dark = color.hex.dark;
bg = light.base;
text = light.text;
accent = dark.mauve;
accentHL = dark.red;
surface = dark.base;
in ''
#![enable(implicit_some)] #![enable(implicit_some)]
#![enable(unwrap_newtypes)] #![enable(unwrap_newtypes)]
#![enable(unwrap_variant_newtypes)] #![enable(unwrap_variant_newtypes)]
@ -193,32 +292,39 @@ in {
draw_borders: true, draw_borders: true,
format_tag_separator: " | ", format_tag_separator: " | ",
browser_column_widths: [20, 38, 42], browser_column_widths: [20, 38, 42],
modal_backdrop: false,
// Don't set backgrounds so it doesn't look super shitty in dark terminals
background_color: None, background_color: None,
text_color: None,
header_background_color: None, header_background_color: None,
modal_background_color: None, modal_background_color: None,
modal_backdrop: false,
text_color: "#${text}",
preview_label_style: (fg: "yellow"), preview_label_style: (fg: "yellow"),
preview_metadata_group_style: (fg: "yellow", modifiers: "Bold"), preview_metadata_group_style: (fg: "yellow", modifiers: "Bold"),
tab_bar: ( tab_bar: (
enabled: true, enabled: true,
active_style: (fg: "black", bg: "blue", modifiers: "Bold"), active_style: (fg: "#${text}", bg: "#${accent}", modifiers: "Bold|Italic"),
inactive_style: (), inactive_style: (),
), ),
highlighted_item_style: (fg: "blue", modifiers: "Bold"),
current_item_style: (fg: "black", bg: "blue", modifiers: "Bold"), highlighted_item_style: (fg: "#${accentHL}", modifiers: "Bold|Italic"), // Currently playing
borders_style: (fg: "blue"), current_item_style: (fg: "#${text}", bg: "#${accentHL}", modifiers: "Bold"), // Tracks list cursor
highlight_border_style: (fg: "blue"), borders_style: (fg: "#${accent}", modifiers: "Bold"),
highlight_border_style: (fg: "#${accent}", modifiers: "Bold"),
symbols: ( symbols: (
song: "S", song: "󰝚",
dir: "D", dir: "",
playlist: "P", playlist: "󰲸",
marker: "M", marker: "+",
ellipsis: "...", ellipsis: "",
song_style: None, song_style: None,
dir_style: None, dir_style: None,
playlist_style: None, playlist_style: None,
), ),
level_styles: ( level_styles: (
info: (fg: "blue", bg: "black"), info: (fg: "blue", bg: "black"),
warn: (fg: "yellow", bg: "black"), warn: (fg: "yellow", bg: "black"),
@ -226,46 +332,60 @@ in {
debug: (fg: "light_green", bg: "black"), debug: (fg: "light_green", bg: "black"),
trace: (fg: "magenta", bg: "black"), trace: (fg: "magenta", bg: "black"),
), ),
progress_bar: ( progress_bar: (
symbols: ["[", "-", ">", " ", "]"], // symbols: ["[", "-", ">", " ", "]"],
track_style: (fg: "#1e2030"), symbols: ["", "", "", "", ""],
elapsed_style: (fg: "blue"), track_style: (fg: "#${surface}"),
thumb_style: (fg: "blue", bg: "#1e2030"), elapsed_style: (fg: "#${accent}"),
thumb_style: (fg: "#${accentHL}"), // "The draggable part"
), ),
scrollbar: ( scrollbar: (
symbols: ["", "", "", ""], symbols: ["", "", "", ""],
track_style: (), track_style: (fg: "#${surface}"),
ends_style: (), ends_style: (fg: "#${accentHL}"),
thumb_style: (fg: "blue"), thumb_style: (fg: "#${accentHL}"), // "The draggable part"
), ),
song_table_format: [ song_table_format: [
( (
prop: (kind: Property(Artist), prop: (
kind: Property(Artist),
style: (fg: "#${text}"),
default: (kind: Text("Unknown")) default: (kind: Text("Unknown"))
), ),
width: "20%", width: "20%",
), ),
( (
prop: (kind: Property(Title), prop: (
kind: Property(Title),
style: (fg: "#${text}"),
default: (kind: Text("Unknown")) default: (kind: Text("Unknown"))
), ),
width: "35%", width: "35%",
), ),
( (
prop: (kind: Property(Album), style: (fg: "white"), prop: (
kind: Property(Album),
style: (fg: "#${text}"),
default: (kind: Text("Unknown Album"), style: (fg: "white")) default: (kind: Text("Unknown Album"), style: (fg: "white"))
), ),
width: "30%", width: "30%",
), ),
( (
prop: (kind: Property(Duration), prop: (
kind: Property(Duration),
style: (fg: "#${text}"),
default: (kind: Text("-")) default: (kind: Text("-"))
), ),
width: "15%", width: "15%",
alignment: Right, alignment: Right,
), ),
], ],
components: {}, components: {},
layout: Split( layout: Split(
direction: Vertical, direction: Vertical,
panes: [ panes: [
@ -287,54 +407,117 @@ in {
), ),
], ],
), ),
header: ( header: (
rows: [ rows: [
// Top Row
( (
left: [ left: [
(kind: Text("["), style: (fg: "yellow", modifiers: "Bold")), (
(kind: Property(Status(StateV2(playing_label: "Playing", paused_label: "Paused", stopped_label: "Stopped"))), style: (fg: "yellow", modifiers: "Bold")), kind: Text("["),
(kind: Text("]"), style: (fg: "yellow", modifiers: "Bold")) style: (fg: "#${accentHL}", modifiers: "Bold")
], ),
center: [ (
(kind: Property(Song(Title)), style: (modifiers: "Bold"), kind: Property(Status(StateV2(
default: (kind: Text("No Song"), style: (modifiers: "Bold")) playing_label: "Playing",
paused_label: "Paused",
stopped_label: "Stopped"))
),
style: (fg: "#${accentHL}", modifiers: "Bold")
),
(
kind: Text("]"),
style: (fg: "#${accentHL}", modifiers: "Bold")
) )
], ],
center: [
(
kind: Property(Song(Title)),
style: (fg: "#${accentHL}", modifiers: "Bold"),
default: (
kind: Text("No Song"),
style: (fg: "#${text}", modifiers: "Bold")
)
)
],
right: [ right: [
(kind: Property(Widget(ScanStatus)), style: (fg: "blue")), (
(kind: Property(Widget(Volume)), style: (fg: "blue")) kind: Property(Widget(ScanStatus)),
] style: (fg: "#${accentHL}")
), ),
(
kind: Property(Widget(Volume)),
style: (fg: "#${accentHL}")
)
]
),
// Bottom Row
( (
left: [ left: [
(kind: Property(Status(Elapsed))), (
(kind: Text(" / ")), kind: Property(Status(Elapsed)),
(kind: Property(Status(Duration))), style: (fg: "#${text}")
(kind: Text(" (")), ),
(kind: Property(Status(Bitrate))), (
(kind: Text(" kbps)")) kind: Text(" / "),
style: (fg: "#${text}")
),
(
kind: Property(Status(Duration)),
style: (fg: "#${text}")
),
(
kind: Text(" ("),
style: (fg: "#${text}")
),
(
kind: Property(Status(Bitrate)),
style: (fg: "#${text}")
),
(
kind: Text(" kbps)"),
style: (fg: "#${text}")
)
], ],
center: [ center: [
(kind: Property(Song(Artist)), style: (fg: "yellow", modifiers: "Bold"), (
default: (kind: Text("Unknown"), style: (fg: "yellow", modifiers: "Bold")) kind: Property(Song(Artist)),
style: (fg: "#${text}", modifiers: "Bold"),
default: (
kind: Text("Unknown"),
style: (fg: "#${text}", modifiers: "Bold")
)
), ),
(kind: Text(" - ")), (
(kind: Property(Song(Album)), kind: Text(" - "),
default: (kind: Text("Unknown Album")) style: (fg: "#${text}")
),
(
kind: Property(Song(Album)),
style: (fg: "#${text}"),
default: (
kind: Text("Unknown Album"),
style: (fg: "#${text}")
)
) )
], ],
right: [ right: [
( (
kind: Property(Widget(States( kind: Property(Widget(States(
active_style: (fg: "white", modifiers: "Bold"), active_style: (fg: "#${accentHL}", modifiers: "Bold|Underlined"),
separator_style: (fg: "white"))) inactive_style: (fg: "#${text}"),
), separator_style: (fg: "#${text}")))
style: (fg: "dark_gray") )
// style: (fg: "dark_gray")
), ),
] ]
), ),
], ],
), ),
browser_song_format: [ browser_song_format: [
( (
kind: Group([ kind: Group([
@ -351,9 +534,59 @@ in {
default: (kind: Property(Filename)) default: (kind: Property(Filename))
), ),
], ],
lyrics: ( lyrics: (
timestamp: false timestamp: false
) ),
cava: (
// symbols that will be used to draw the bar in the visualiser, in ascending order of
// fill fraction
bar_symbols: ['', '', '', '', '', '', '', ''],
// similar to bar_symbols but these are used for the top-down rendering, meaning for orientation
// "Horizontal" and "Top"
inverted_bar_symbols: ['', '🮂', '🮃', '', '🮄', '🮅', '🮆', ''],
// bg_color: "black", // background color, defaults to rmpc's bg color if not provided
bar_width: 1, // width of a single bar in columns
bar_spacing: 1, // free space between bars in columns
// Possible values are "Top", "Bottom" and "Horizontal". Top makes the bars go from top to
// bottom, "Bottom" is from bottom up, and "Horizontal" is split in the middle with bars going
// both down and up from there.
// Using non-default symbols with "Top" and "Horizontal" may produce undesired output.
orientation: Bottom,
// Colors can be configured in three different ways: a single color, different colors
// per row and a gradient. You can use the same colors as everywhere else. Only specify
// one of these:
// Every bar symbol will be red
// bar_color: Single("red"),
// The first two rows(two lowest amplitudes) will be red, after that two green rows
// and the rest will be blue. You can have as many as you want here. The last value
// will be used if the height exceeds the length of this array.
// bar_color: Rows([
// "red",
// "red",
// "green",
// "green",
// "blue",
// ]),
// A simple color gradient. This is a map where keys are percent values of the height
// where the color starts. After that it is linearly interpolated towards the next value.
// In this example, the color will start at green for the lowest amplitudes, go towards
// blue at half amplitudes and finishing as red for the highest values. Keys must be between
// 0 and 100 and if the first or last key are not 0 and 100 respectively, the lowest and highest
// value will be used as 0 and 100. Only hex and RGB colors are supported here and your terminal
// must support them as well!
bar_color: Gradient({
0: "#${accent}",
100: "#${accentHL}",
}),
),
) )
''; '';
}; };

View File

@ -123,7 +123,14 @@ with mylib.networking; {
documentation = { documentation = {
enable = true; enable = true;
man.enable = true; man.enable = true;
man.generateCaches = false; # very slow
info.enable = true;
dev.enable = true; dev.enable = true;
doc.enable = false;
nixos = {
enable = true;
includeAllModules = true;
};
}; };
# Set your time zone. # Set your time zone.
@ -329,6 +336,8 @@ with mylib.networking; {
fonts = { fonts = {
enableDefaultPackages = true; # Some default fonts for unicode coverage enableDefaultPackages = true; # Some default fonts for unicode coverage
# https://wiki.nixos.org/wiki/Fonts#Flatpak_applications_can.27t_find_system_fonts
fontDir.enable = true; # Puts fonts to /run/current-system/sw/share/X11/fonts fontDir.enable = true; # Puts fonts to /run/current-system/sw/share/X11/fonts
# Font packages go here. # Font packages go here.
@ -337,6 +346,8 @@ with mylib.networking; {
packages = with pkgs; [ packages = with pkgs; [
# Monospace fonts # Monospace fonts
nerd-fonts.jetbrains-mono nerd-fonts.jetbrains-mono
nerd-fonts.victor-mono
monolisa
# Sans/Serif fonts # Sans/Serif fonts
noto-fonts noto-fonts
@ -351,10 +362,14 @@ with mylib.networking; {
hinting.enable = true; hinting.enable = true;
hinting.autohint = true; hinting.autohint = true;
cache32Bit = true; cache32Bit = true;
# https://wiki.nixos.org/wiki/Fonts#Noto_Color_Emoji_doesn.27t_render_on_Firefox
useEmbeddedBitmaps = true;
defaultFonts = { defaultFonts = {
serif = ["Noto Serif CJK SC"]; serif = ["Noto Serif CJK SC"];
sansSerif = ["Noto Sans CJK SC"]; sansSerif = ["Noto Sans CJK SC"];
monospace = ["JetBrainsMono Nerd Font Mono"]; monospace = ["MonoLisa" "JetBrainsMono Nerd Font Mono"]; # NOTE: Match with color.font
}; };
}; };
}; };