Commit
This commit is contained in:
151
modules/profiles/workstation.nix
Normal file
151
modules/profiles/workstation.nix
Normal file
@@ -0,0 +1,151 @@
|
||||
{ lux, den, ... }:
|
||||
{
|
||||
lux.workstation = den.lib.parametric {
|
||||
includes = with lux; [
|
||||
region-nl
|
||||
|
||||
greeter
|
||||
niri
|
||||
xdg
|
||||
|
||||
# GUI Applications & Dev Tools
|
||||
bitwarden
|
||||
email
|
||||
dev
|
||||
noctalia
|
||||
pim
|
||||
mpv
|
||||
helium
|
||||
];
|
||||
|
||||
homeManager =
|
||||
{ pkgs, config, ... }:
|
||||
{
|
||||
home.packages = with pkgs; [
|
||||
brave
|
||||
localsend
|
||||
postman
|
||||
wl-clipboard
|
||||
spotify
|
||||
gemini-cli
|
||||
qbittorrent
|
||||
planify
|
||||
];
|
||||
|
||||
programs.ripgrep.enable = true;
|
||||
programs.uv.enable = true;
|
||||
|
||||
home.pointerCursor = {
|
||||
name = "phinger-cursors-light";
|
||||
package = pkgs.phinger-cursors;
|
||||
size = 32;
|
||||
gtk.enable = true;
|
||||
};
|
||||
|
||||
# Make electron use wayland
|
||||
home.sessionVariables = {
|
||||
NIXOS_OZONE_WL = "1";
|
||||
|
||||
BROWSER = "brave";
|
||||
EDITOR = "nvim";
|
||||
VISUAL = "nvim";
|
||||
|
||||
CARGO_HOME = "${config.xdg.dataHome}/cargo";
|
||||
STARSHIP_CACHE = "${config.xdg.cacheHome}/starship";
|
||||
|
||||
GEMINI_CONFIG_DIR = "${config.xdg.configHome}/gemini";
|
||||
|
||||
};
|
||||
|
||||
services.cliphist.enable = true;
|
||||
services.wl-clip-persist.enable = true;
|
||||
};
|
||||
|
||||
nixos =
|
||||
{
|
||||
config,
|
||||
pkgs,
|
||||
...
|
||||
}:
|
||||
{
|
||||
# More modern version of dbus
|
||||
services.dbus.implementation = "broker";
|
||||
|
||||
programs.nix-ld.enable = true;
|
||||
environment.localBinInPath = true;
|
||||
|
||||
# For localsend
|
||||
networking.firewall.allowedTCPPorts = [ 53317 ];
|
||||
|
||||
# Audio
|
||||
security.rtkit.enable = true;
|
||||
services.pipewire = {
|
||||
enable = true;
|
||||
alsa.enable = true;
|
||||
pulse.enable = true;
|
||||
jack.enable = true;
|
||||
wireplumber.enable = true;
|
||||
};
|
||||
|
||||
# Bluetooth
|
||||
hardware.bluetooth.enable = true;
|
||||
services.blueman.enable = true;
|
||||
|
||||
# Fonts
|
||||
fonts = {
|
||||
enableDefaultPackages = false;
|
||||
packages = with pkgs; [
|
||||
noto-fonts
|
||||
noto-fonts-cjk-sans
|
||||
noto-fonts-color-emoji
|
||||
iosevka
|
||||
jetbrains-mono
|
||||
fira-code
|
||||
];
|
||||
};
|
||||
|
||||
# Printing
|
||||
services.printing = {
|
||||
enable = true;
|
||||
drivers = with pkgs; [
|
||||
cups-filters
|
||||
cups-browsed
|
||||
cnijfilter2
|
||||
];
|
||||
};
|
||||
|
||||
# Bootloader
|
||||
boot = {
|
||||
loader = {
|
||||
efi.canTouchEfiVariables = true;
|
||||
systemd-boot = {
|
||||
enable = true;
|
||||
consoleMode = "auto";
|
||||
configurationLimit = 5;
|
||||
|
||||
# Convert boot entry to a more readable name
|
||||
extraInstallCommands = ''
|
||||
ENTRIES="${config.boot.loader.efi.efiSysMountPoint}/loader/entries"
|
||||
PROFILES="/nix/var/nix/profiles"
|
||||
|
||||
for file in "$ENTRIES"/nixos-generation-*.conf; do
|
||||
generation=$(${pkgs.coreutils}/bin/basename "$file" | ${pkgs.gnugrep}/bin/grep -o -E '[0-9]+')
|
||||
timestamp=$(${pkgs.coreutils}/bin/stat -c %y "$PROFILES/system-$generation-link" 2>/dev/null | ${pkgs.coreutils}/bin/cut -d. -f1)
|
||||
|
||||
if [ -z "$timestamp" ]; then
|
||||
timestamp="Unknown Date"
|
||||
fi
|
||||
|
||||
${pkgs.gnused}/bin/sed -i "s/^version .*/version Generation $generation - $timestamp/" "$file"
|
||||
done
|
||||
'';
|
||||
};
|
||||
};
|
||||
|
||||
tmp.cleanOnBoot = true;
|
||||
kernelPackages = pkgs.linuxPackages_latest;
|
||||
};
|
||||
|
||||
};
|
||||
};
|
||||
}
|
||||
Reference in New Issue
Block a user