dotfiles/system/configuration.nix

64 lines
1.3 KiB
Nix
Raw Normal View History

2022-08-30 14:29:44 +00:00
{ lib, pkgs, config, modulesPath, ... }:
with lib;
let
nixos-wsl = import ./nixos-wsl;
in
{
imports = [
"${modulesPath}/profiles/minimal.nix"
2022-11-06 10:45:45 +00:00
./hardware-configuration.nix
2022-08-30 14:29:44 +00:00
nixos-wsl.nixosModules.wsl
];
2022-11-06 10:45:45 +00:00
networking.hostName = "nixos";
system.stateVersion = "22.05";
2022-08-30 14:29:44 +00:00
wsl = {
enable = true;
automountPath = "/mnt";
defaultUser = "nixos"; # if change defaultUser, make sure uid to be 1000 (first user)
startMenuLaunchers = true;
# Enable native Docker support
# docker-native.enable = true;
# Enable integration with Docker Desktop (needs to be installed)
docker-desktop.enable = true;
};
# users.users.<defaultUser>.uid = 1000;
# Enable nix flakes
nix.package = pkgs.nixFlakes;
nix.extraOptions = ''
experimental-features = nix-command flakes
'';
2022-11-06 10:45:45 +00:00
# Home manager
2022-08-30 14:29:44 +00:00
programs.neovim = {
enable = true;
defaultEditor = true;
};
programs.git = {
enable = true;
# more information should be configured under user level
};
2022-11-06 10:45:45 +00:00
programs.zsh = {
enable = true;
shellAliases = {
# list lists
ll = "ls -l";
update = "sudo nixos-rebuild switch";
};
history = {
size = 10000;
path = "${config.xdg.dataHome}/zsh/history";
};
};
2022-08-30 14:29:44 +00:00
environment.systemPackages = [
pkgs.gnumake
];
}