feat: decent shell configuration with starship and zsh

direnv and devenv integrated support
experimental nginx test configuration
sway and foot configuration updated
created initial sddm configuration for login manager
This commit is contained in:
Zhongheng Liu 2024-08-01 18:05:58 +08:00
commit 4fe4ebefc8
14 changed files with 529 additions and 4 deletions

View file

@ -10,7 +10,10 @@
{
imports = [
./variables.nix
./nvidia.nix
#./greetd-sway.nix
#./nvidia.nix
./fonts.nix
./services/nginx.service.nix
./hardware-configuration.nix
];
boot.loader = {
@ -31,6 +34,18 @@
'';
};
};
services.displayManager.sddm = {
enable = true;
wayland.enable = true;
};
systemd.user.services.kanshi = {
description = "kanshi daemon";
serviceConfig = {
Type = "simple";
ExecStart = ''${pkgs.kanshi}/bin/kanshi -c kanshi_config_file'';
};
};
security.polkit.enable = true;
services.gnome.gnome-keyring.enable = true;
programs.sway = {
@ -53,6 +68,7 @@
flake-registry = "";
nix-path = config.nix.nixPath;
};
channel.enable = false;
registry = lib.mapAttrs (_: flake: {inherit flake;}) flakeInputs;
nixPath = lib.mapAttrsToList (n: _: "${n}=flake:${n}") flakeInputs;
};
@ -79,6 +95,7 @@
PasswordAuthentication = false;
};
};
services.automatic-timezoned.enable = true;
# https://nixos.wiki/wiki/FAQ/When_do_I_update_stateVersion
system.stateVersion = "24.05";
}

29
nixos/fonts.nix Normal file
View file

@ -0,0 +1,29 @@
{pkgs, ...}: {
fonts.packages = with pkgs; [
#helvetica-neue-lt-std
aileron
#corefonts
#vistafonts
#vistafonts-chs
noto-fonts
#noto-fonts-cjk
noto-fonts-emoji
#liberation_ttf
#mplus-outline-fonts.githubRelease
#dina-font
#proggyfonts
#glasstty-ttf
(
nerdfonts.override {
fonts = [
"FiraCode"
"IBMPlexMono"
#"IntelOneMono"
#"CascadiaMono"
#"CommitMono"
#"JetBrainsMono"
];
}
)
];
}

10
nixos/greetd-sway.nix Normal file
View file

@ -0,0 +1,10 @@
{pkgs, config, lib, ...}: {
services.greetd = {
enable = true;
settings = {
default_session = {
command = "${pkgs.sway}/bin/sway";
};
};
};
}

View file

@ -14,6 +14,10 @@
};
};
};
hardware.opengl = {
enable = true;
};
services.xserver.videoDrivers = [ "nvidia" ];
hardware.nvidia = {
prime = {
offload.enable = false;

View file

@ -0,0 +1,6 @@
{...}:
{
services.nginx = {
enable = true;
};
}