dots/users/sam/home.nix

36 lines
702 B
Nix
Raw Normal View History

{
pkgs,
lib,
config,
...
}:
2024-05-03 14:35:00 -05:00
let
nixGLWrap =
pkg:
pkgs.runCommand "${pkg.name}-nixgl-wrapper" { } ''
mkdir $out
ln -s ${pkg}/* $out
rm $out/bin
mkdir $out/bin
for bin in ${pkg}/bin/*; do
wrapped_bin=$out/bin/$(basename $bin)
echo "exec ${lib.getExe pkgs.nixgl.nixGLIntel} $bin \$@" > $wrapped_bin
chmod +x $wrapped_bin
done
'';
in
{
imports = [ ../price/home.nix ];
xdg.systemDirs.data = [
"${config.home.homeDirectory}/.nix-profile/share"
"/usr/share"
"/usr/local/share"
];
2024-05-03 14:35:00 -05:00
home = {
packages = with pkgs; [
(lib.hiPrio (nixGLWrap neovide))
(lib.hiPrio (nixGLWrap wezterm))
];
};
}