mpd and xorg fixes

This commit is contained in:
Maddie H 2023-03-10 18:43:31 +00:00
parent 6e230b9543
commit b63282e3f8
No known key found for this signature in database
GPG Key ID: 64FAA9959751687D
2 changed files with 26 additions and 6 deletions

View File

@ -1,8 +1,25 @@
{ config, pkgs, username, ... }: { config, pkgs, username, ... }:
{ {
services.mpd.enable = true; services.mpd = {
services.mpd.musicDirectory = "/home/${username}/Music"; enable = true;
musicDirectory = "${config.home.homeDirectory}/Music";
extraConfig = ''
auto_update "yes"
audio_output {
type "pipewire"
name "PipeWire Sound Server"
}
audio_output {
type "fifo"
name "Visualizer feed"
path "/tmp/mpd.fifo"
format "44100:16:2"
}
'';
};
home.packages = with pkgs; [ home.packages = with pkgs; [
mpc_cli mpc_cli

View File

@ -36,8 +36,14 @@
programs.feh.enable = true; programs.feh.enable = true;
home.file.".xinitrc".text = '' home.file.".xinitrc".text = ''
# Monitor configuration # Monitor configuration
${pkgs.xorg.xrandr}/bin/xrandr --output DP-0 --primary --mode 2560x1440 --pos 0x560
${pkgs.xorg.xrandr}/bin/xrandr --output HDMI-0 --noprimary --mode 2560x1440 --pos 2560x0 --rotate right ${pkgs.xorg.xrandr}/bin/xrandr --output HDMI-0 --noprimary --mode 2560x1440 --pos 2560x0 --rotate right
${pkgs.xorg.xrandr}/bin/xrandr --output DP-0 --primary --mode 2560x1440 --pos 0x560
# Apply wallpaper
${pkgs.feh}/bin/feh --no-fehbg --bg-fill "$HOME/Pictures/Wallpapers/The Walking Dead/shane_1.jpg" --bg-fill "$HOME/Pictures/Wallpapers/The Walking Dead/shane_3.jpg"
# Refresh xresources
${pkgs.xorg.xrdb}/bin/xrdb "$HOME/.Xresources"
# Speed up repeated keypresses # Speed up repeated keypresses
${pkgs.xorg.xset}/bin/xset r rate 300 50 ${pkgs.xorg.xset}/bin/xset r rate 300 50
@ -45,9 +51,6 @@
# Set keyboard map and remap caps to escape # Set keyboard map and remap caps to escape
${pkgs.xorg.setxkbmap}/bin/setxkbmap -layout gb --option caps:escape ${pkgs.xorg.setxkbmap}/bin/setxkbmap -layout gb --option caps:escape
# Apply wallpaper
${pkgs.feh}/bin/feh --no-fehbg --bg-fill "$HOME/Pictures/Wallpapers/The Walking Dead/shane_1.jpg" --bg-fill "$HOME/Pictures/Wallpapers/The Walking Dead/shane_3.jpg"
# Start the window manager # Start the window manager
${pkgs.openssh}/bin/ssh-agent ${pkgs.dbus}/bin/dbus-run-session ${pkgs.dwm}/bin/dwm ${pkgs.openssh}/bin/ssh-agent ${pkgs.dbus}/bin/dbus-run-session ${pkgs.dwm}/bin/dwm
''; '';