diff --git a/hosts/zedd/configuration.nix b/hosts/zedd/configuration.nix index c7f931c..e02b2ed 100644 --- a/hosts/zedd/configuration.nix +++ b/hosts/zedd/configuration.nix @@ -3,7 +3,8 @@ # Enable OpenGL # Load nvidia driver for Xorg and Wayland environment.pathsToLink = [ "/libexec" ]; - + users.users.mbeno.extraGroups = [ "adbusers" ]; + programs.adb.enable = true; # Bootloader. boot.loader.systemd-boot.enable = true; boot.loader.efi.canTouchEfiVariables = true; diff --git a/system/programs.nix b/system/programs.nix index 55865eb..c9a13fc 100644 --- a/system/programs.nix +++ b/system/programs.nix @@ -42,7 +42,10 @@ pass xdg-desktop-portal pkg-config + xclip + nvd xdg-desktop-portal-gtk + google-chrome zoom-us neovim git diff --git a/system/services.nix b/system/services.nix index 869e68d..6367dd8 100644 --- a/system/services.nix +++ b/system/services.nix @@ -5,6 +5,41 @@ networking.firewall.enable = false; security.polkit.enable = true; services = { + prometheus = { + scrapeConfigs = [ + { + job_name = "chrysalis"; + static_configs = [{ + targets = [ "127.0.0.1:${toString config.services.prometheus.exporters.node.port}" ]; + }]; + } + ]; + + exporters = { + node = { + enable = true; + enabledCollectors = [ "systemd" "processes" ]; + port = 9002; + }; + }; + + enable = true; + port = 9001; + }; + + grafana = { + enable = true; + settings = { + server = { + # Listening Address + http_addr = "127.0.0.1"; + # and Port + http_port = 3000; + # Grafana needs to know on which domain and URL it's running + serve_from_sub_path = true; + }; + }; + }; displayManager = { defaultSession = "none+i3"; @@ -15,8 +50,9 @@ logind.extraConfig = "IdleAction=ignore"; xserver = { enable = true; - xkb.layout = "us"; - xkb.variant = ""; + xkb.layout = "us,no"; + xkb.variant = "qwerty"; + xkb.options = "grp:win_space_toggle"; desktopManager = { xterm.enable = false; }; diff --git a/user/packages/default.nix b/user/packages/default.nix index 668ce1c..09bbd0f 100644 --- a/user/packages/default.nix +++ b/user/packages/default.nix @@ -4,7 +4,14 @@ inputs.nix-citizen.packages.${system}.star-citizen age discord + pdfpc + qpwgraph + mixxx + imagemagick + maim sidequest + opera + android-studio libpng p7zip lshw diff --git a/user/zsh/default.nix b/user/zsh/default.nix index d0ed5b7..d33c8c9 100644 --- a/user/zsh/default.nix +++ b/user/zsh/default.nix @@ -1,4 +1,4 @@ -{ user, pkgs, ... }: { +{ user, pkgs, config, ... }: { home.packages = with pkgs; [ fd ]; programs.zsh = { enable = true; @@ -7,7 +7,17 @@ enableCompletion = true; syntaxHighlighting.enable = true; shellAliases = { - nrebuild = "sudo nixos-rebuild switch --flake /home/${user}/git/nixos"; + nrebuild = "sudo nixos-rebuild switch --flake /home/${user}/git/nixos && nvd diff $(ls -d1v /nix/var/nix/profiles/system-*-link|tail -n 2) && source ~/.zshrc"; + nlog = '' + revpath="/nix/var/nix/profiles"; + lastrev=$(ls -d1v $revpath/system-*-link|cut -d "-" -f2 | tail -n1); + for revit in {$lastrev..0}; + do + ls -lt $revpath/system-$revit-link $revpath/system-$(( $revit - 1 ))-link | cut -d" " -f6,7,8 | awk '{key=$0; getline; print key " -> " $0;}' + nvd diff $revpath/system-$revit-link $revpath/system-$(( $revit - 1 ))-link; + read; + done + ''; dresden = "/home/mbeno/.ssh/dresden.sh"; d = "dresden"; }; @@ -15,6 +25,8 @@ initExtra = '' bindkey -v bindkey '^R' history-incremental-search-backward + bindkey '^[[A' history-substring-search-up + bindkey '^[[B' history-substring-search-down # Prompt stuff autoload -Uz promptinit @@ -25,9 +37,16 @@ zplug = { enable = true; plugins = [ - ({ name = "plugins/git"; tags = [ "from:oh-my-zsh" ]; }) - ({ name = "modules/prompt"; tags = [ "from:prezto" ]; }) + { name = "plugins/git"; tags = [ "from:oh-my-zsh" ]; } + { name = "modules/prompt"; tags = [ "from:prezto" ]; } + { name = "zsh-users/zsh-autosuggestions"; } + { + name = + "zsh-users/zsh-history-substring-search"; + } ]; }; + history.size = 1000000; + history.path = "${config.xdg.dataHome}/zsh/history"; }; }