nixos/malte/home.nix
2021-11-03 14:36:44 +01:00

146 lines
3.1 KiB
Nix

{ pkgs, lib, config, ... }:
let
script = name: path: pkgs.writeScriptBin name (builtins.readFile path);
wrap = name: pkg: postBuild:
pkgs.symlinkJoin {
inherit name postBuild;
paths = [ pkg ];
buildInputs = [ pkgs.makeWrapper ];
};
fixGdk = name: pkg:
wrap name pkg ''
wrapProgram $out/bin/${name} --set GDK_BACKEND x11
'';
fixElectron = name: pkg:
wrap name pkg ''
wrapProgram $out/bin/${name} --add-flags "--enable-features=UseOzonePlatform --ozone-platform=wayland"
'';
in {
imports = [
./git.nix
./neovim.nix
./shell.nix
./kitty.nix
./sway.nix
./gpg.nix
./pass.nix
./zathura.nix
#./unison.nix
./taskwarrior.nix
./audio-fix.nix
./game-launchers.nix
./khal.nix
./cataclysm-dda.nix
#./desktop.nix
./restic-backups.nix
];
config = {
home = {
packages = with pkgs; [
element-desktop # FIXME: Once it works again? (fixElectron "element-desktop" element-desktop)
signal-desktop # FIXME: Once it works again? (fixElectron "signal-desktop" signal-desktop)
(fixGdk "Discord" discord)
(fixGdk "losslesscut" losslesscut-bin)
(fixGdk "skypeforlinux" skype)
(pkgs.callPackage ../pkgs/2i-emulator.nix { })
(script "hwp2021pizzazz" ../scripts/hwp2021pizzazz.py)
(fenix.latest.withComponents [
"cargo"
"clippy"
"rust-src"
"rustc"
"rustfmt"
])
cargo-readme
cargo-edit
cargo-udeps
feh
geekbench
gimp
gnome3.nautilus
gnome3.sushi
helvum
hledger
htop
inkscape
kbdlight
libnotify
libreoffice
logisim
mensa
mosh
mpv-with-scripts
nixfmt
patchelf
pavucontrol
pdftk
pkgs."2a-emulator"
ponymix
pulseaudio
pulseeffects-pw
python3
qt5ct
qucs
qucs-s
rtorrent
rust-analyzer-nightly
screenfetch
sshfs
tdesktop
unar
unison
vlc
xdg_utils
xournalpp
youtube-dl
wev
wl-clipboard
];
# Use default US, so that games don't get too confused. But let me
# switch to a more comfortable workman layout!
keyboard = {
layout = "us,us";
variant = ",workman";
options = [ "compose:rctrl" "grp:alt_space_toggle" "grp_led:caps" ];
};
# Use some german units and formats but with the english language!
language = {
base = "en_US.UTF-8";
address = "de_DE.UTF-8";
measurement = "de_DE.UTF-8";
monetary = "de_DE.UTF-8";
name = "de_DE.UTF-8";
paper = "de_DE.UTF-8";
telephone = "de_DE.UTF-8";
time = "de_DE.UTF-8";
};
};
programs.firefox.enable = true;
programs.obs-studio = {
enable = true;
plugins = [
pkgs.obs-studio-plugins.wlrobs
#pkgs.obs-studio-plugins.v4l2sink
];
};
fonts.fontconfig.enable = true;
services.mpris-proxy.enable = true;
};
}