100 lines
2.2 KiB
Nix
100 lines
2.2 KiB
Nix
{
|
|
pkgs,
|
|
hostname,
|
|
timezone,
|
|
touchpadSupport,
|
|
inputs,
|
|
logitech-hardware,
|
|
...
|
|
}: {
|
|
environment.systemPackages = with pkgs;
|
|
[
|
|
python3
|
|
python3Packages.pip
|
|
python3Packages.pygobject3
|
|
python3Packages.setuptools
|
|
python3Packages.wheel
|
|
|
|
gobject-introspection
|
|
gtk3
|
|
libxml2
|
|
|
|
cargo
|
|
gcc
|
|
rustc
|
|
nodejs
|
|
yarn
|
|
|
|
busybox
|
|
|
|
p7zip
|
|
|
|
btop
|
|
tldr
|
|
|
|
jq
|
|
]
|
|
++ [
|
|
inputs.matugen.packages.${pkgs.system}.default
|
|
]
|
|
++ lib.optionals (logitech-hardware.enable == true) [
|
|
logiops
|
|
];
|
|
boot.loader.systemd-boot.enable = true;
|
|
boot.loader.efi.canTouchEfiVariables = true;
|
|
|
|
hardware = {
|
|
logitech.wireless.enable = logitech-hardware.enable;
|
|
bluetooth = {
|
|
enable = true;
|
|
powerOnBoot = true;
|
|
};
|
|
};
|
|
|
|
i18n.defaultLocale = "en_US.UTF-8";
|
|
console = {
|
|
font = "Lat2-Terminus16";
|
|
useXkbConfig = true; # use xkb.options in tty.
|
|
};
|
|
|
|
networking.hostName = "${hostname}";
|
|
networking.networkmanager.enable = true; # Easiest to use and most distros use this by default.
|
|
|
|
time.timeZone = "${timezone}";
|
|
|
|
services = {
|
|
openssh.enable = true;
|
|
libinput.enable = touchpadSupport;
|
|
blueman.enable = true;
|
|
};
|
|
|
|
programs.bash = {
|
|
interactiveShellInit = ''
|
|
if [[ $(${pkgs.procps}/bin/ps --no-header --pid=$PPID --format=comm) != "fish" && -z ''${BASH_EXECUTION_STRING} ]]
|
|
then
|
|
shopt -q login_shell && LOGIN_OPTION='--login' || LOGIN_OPTION=""
|
|
exec ${pkgs.fish}/bin/fish $LOGIN_OPTION
|
|
fi
|
|
'';
|
|
};
|
|
|
|
programs = {
|
|
fish.enable = true;
|
|
zsh.enable = true;
|
|
};
|
|
|
|
# networking.firewall.allowedTCPPorts = [ ... ];
|
|
# networking.firewall.allowedUDPPorts = [ ... ];
|
|
# Or disable the firewall altogether.
|
|
# networking.firewall.enable = false;
|
|
|
|
# networking.proxy.default = "http://user:password@proxy:port/";
|
|
# networking.proxy.noProxy = "127.0.0.1,localhost,internal.domain";
|
|
|
|
# Copy the NixOS configuration file and link it from the resulting system
|
|
# (/run/current-system/configuration.nix). This is useful in case you
|
|
# accidentally delete configuration.nix.
|
|
# ONLY WORKS non-flake
|
|
# system.copySystemConfiguration = true;
|
|
}
|