From 091400ba7d60f7a8029ae1af8888c6fd343b9f7b Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Mon, 25 Dec 2023 21:49:09 -0500 Subject: [PATCH 01/77] feat: init thinkcentre --- flake.nix | 18 +++ machines/thinkcentre/configuration.nix | 129 ++++++++++++++++++ .../thinkcentre/hardware-configuration.nix | 37 +++++ 3 files changed, 184 insertions(+) create mode 100644 machines/thinkcentre/configuration.nix create mode 100644 machines/thinkcentre/hardware-configuration.nix diff --git a/flake.nix b/flake.nix index 659c618..37460da 100644 --- a/flake.nix +++ b/flake.nix @@ -98,6 +98,24 @@ specialArgs = {inherit inputs;}; }; + thinkcentre = nixpkgs.lib.nixosSystem { + system = utils.lib.system.x86_64-linux; + modules = [ + self.overlaysModule + home-manager.nixosModules.home-manager + # ./modules/common.nix + # ./modules/containers.nix + { + home-manager.useGlobalPkgs = true; + home-manager.useUserPackages = true; + home-manager.users.michael = import ./user/environments/nixos/home.nix; + } + + ./machines/thinkcentre/configuration.nix + ]; + specialArgs = {inherit inputs;}; + }; + # WSL environment work = inputs.nixpkgs.lib.nixosSystem { system = utils.lib.system.x86_64-linux; diff --git a/machines/thinkcentre/configuration.nix b/machines/thinkcentre/configuration.nix new file mode 100644 index 0000000..1e7f9e0 --- /dev/null +++ b/machines/thinkcentre/configuration.nix @@ -0,0 +1,129 @@ +# Edit this configuration file to define what should be installed on +# your system. Help is available in the configuration.nix(5) man page +# and in the NixOS manual (accessible by running ‘nixos-help’). + +{ config, pkgs, ... }: + +{ + imports = + [ # Include the results of the hardware scan. + ./hardware-configuration.nix + ]; + + # Bootloader. + boot.loader.systemd-boot.enable = true; + boot.loader.efi.canTouchEfiVariables = true; + + networking.hostName = "nixos"; # Define your hostname. + # networking.wireless.enable = true; # Enables wireless support via wpa_supplicant. + + # Configure network proxy if necessary + # networking.proxy.default = "http://user:password@proxy:port/"; + # networking.proxy.noProxy = "127.0.0.1,localhost,internal.domain"; + + # Enable networking + networking.networkmanager.enable = true; + + # Set your time zone. + time.timeZone = "America/New_York"; + + # Select internationalisation properties. + i18n.defaultLocale = "en_US.UTF-8"; + + i18n.extraLocaleSettings = { + LC_ADDRESS = "en_US.UTF-8"; + LC_IDENTIFICATION = "en_US.UTF-8"; + LC_MEASUREMENT = "en_US.UTF-8"; + LC_MONETARY = "en_US.UTF-8"; + LC_NAME = "en_US.UTF-8"; + LC_NUMERIC = "en_US.UTF-8"; + LC_PAPER = "en_US.UTF-8"; + LC_TELEPHONE = "en_US.UTF-8"; + LC_TIME = "en_US.UTF-8"; + }; + + # Enable the X11 windowing system. + services.xserver.enable = true; + + # Enable the GNOME Desktop Environment. + services.xserver.displayManager.gdm.enable = true; + services.xserver.desktopManager.gnome.enable = true; + + # Configure keymap in X11 + services.xserver = { + layout = "us"; + xkbVariant = ""; + }; + + # Enable CUPS to print documents. + services.printing.enable = true; + + # Enable sound with pipewire. + sound.enable = true; + hardware.pulseaudio.enable = false; + security.rtkit.enable = true; + services.pipewire = { + enable = true; + alsa.enable = true; + alsa.support32Bit = true; + pulse.enable = true; + # If you want to use JACK applications, uncomment this + #jack.enable = true; + + # use the example session manager (no others are packaged yet so this is enabled by default, + # no need to redefine it in your config for now) + #media-session.enable = true; + }; + + # Enable touchpad support (enabled default in most desktopManager). + # services.xserver.libinput.enable = true; + + # Define a user account. Don't forget to set a password with ‘passwd’. + users.users.michael = { + isNormalUser = true; + description = "Michael Thomas"; + extraGroups = [ "networkmanager" "wheel" ]; + packages = with pkgs; [ + firefox + # thunderbird + ]; + }; + + # Allow unfree packages + nixpkgs.config.allowUnfree = true; + + # List packages installed in system profile. To search, run: + # $ nix search wget + environment.systemPackages = with pkgs; [ + # vim # Do not forget to add an editor to edit configuration.nix! The Nano editor is also installed by default. + # wget + ]; + + # Some programs need SUID wrappers, can be configured further or are + # started in user sessions. + # programs.mtr.enable = true; + # programs.gnupg.agent = { + # enable = true; + # enableSSHSupport = true; + # }; + + # List services that you want to enable: + + # Enable the OpenSSH daemon. + # services.openssh.enable = true; + + # Open ports in the firewall. + # networking.firewall.allowedTCPPorts = [ ... ]; + # networking.firewall.allowedUDPPorts = [ ... ]; + # Or disable the firewall altogether. + # networking.firewall.enable = false; + + # This value determines the NixOS release from which the default + # settings for stateful data, like file locations and database versions + # on your system were taken. It‘s perfectly fine and recommended to leave + # this value at the release version of the first install of this system. + # Before changing this value read the documentation for this option + # (e.g. man configuration.nix or on https://nixos.org/nixos/options.html). + system.stateVersion = "23.11"; # Did you read the comment? + +} diff --git a/machines/thinkcentre/hardware-configuration.nix b/machines/thinkcentre/hardware-configuration.nix new file mode 100644 index 0000000..3a46158 --- /dev/null +++ b/machines/thinkcentre/hardware-configuration.nix @@ -0,0 +1,37 @@ +# Do not modify this file! It was generated by ‘nixos-generate-config’ +# and may be overwritten by future invocations. Please make changes +# to /etc/nixos/configuration.nix instead. +{ config, lib, pkgs, modulesPath, ... }: + +{ + imports = + [ (modulesPath + "/installer/scan/not-detected.nix") + ]; + + boot.initrd.availableKernelModules = [ "xhci_pci" "ahci" "nvme" "usbhid" "usb_storage" "sd_mod" ]; + boot.initrd.kernelModules = [ ]; + boot.kernelModules = [ ]; + boot.extraModulePackages = [ ]; + + fileSystems."/" = + { device = "/dev/disk/by-uuid/2b1793d6-feff-48df-9180-03e8c2bef7bf"; + fsType = "ext4"; + }; + + fileSystems."/boot" = + { device = "/dev/disk/by-uuid/2082-08EF"; + fsType = "vfat"; + }; + + swapDevices = [ ]; + + # Enables DHCP on each ethernet and wireless interface. In case of scripted networking + # (the default) this is the recommended approach. When using systemd-networkd it's + # still possible to use this option, but it's recommended to use it in conjunction + # with explicit per-interface declarations with `networking.interfaces..useDHCP`. + networking.useDHCP = lib.mkDefault true; + # networking.interfaces.enp0s31f6.useDHCP = lib.mkDefault true; + + nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; + hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware; +} From 42c3a5f41303d299fced089d01608ea0969af8f0 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Fri, 29 Dec 2023 21:42:12 -0500 Subject: [PATCH 02/77] chore: update lockfile --- flake.lock | 54 +++++++++++++++++++++++++++--------------------------- 1 file changed, 27 insertions(+), 27 deletions(-) diff --git a/flake.lock b/flake.lock index 62171fe..8d629d1 100644 --- a/flake.lock +++ b/flake.lock @@ -7,11 +7,11 @@ ] }, "locked": { - "lastModified": 1700795494, - "narHash": "sha256-gzGLZSiOhf155FW7262kdHo2YDeugp3VuIFb4/GGng0=", + "lastModified": 1703887437, + "narHash": "sha256-awkp9jyXf8aV9eDWhLdKUqUdg9HfZKe0NdQebSiC0VA=", "owner": "lnl7", "repo": "nix-darwin", - "rev": "4b9b83d5a92e8c1fbfd8eb27eda375908c11ec4d", + "rev": "0a3afdc60042d8e1c2deb63bdfa017acc424a397", "type": "github" }, "original": { @@ -76,11 +76,11 @@ "systems": "systems_2" }, "locked": { - "lastModified": 1694529238, - "narHash": "sha256-zsNZZGTGnMOf9YpHKJqMSsa0dXbfmxeoJ7xHlrt+xmY=", + "lastModified": 1701680307, + "narHash": "sha256-kAuep2h5ajznlPMD9rnQyffWG8EM/C73lejGofXvdM8=", "owner": "numtide", "repo": "flake-utils", - "rev": "ff7b65b44d01cf9ba6a71320833626af21126384", + "rev": "4022d587cbbfd70fe950c1e2083a02621806a725", "type": "github" }, "original": { @@ -132,11 +132,11 @@ ] }, "locked": { - "lastModified": 1700814205, - "narHash": "sha256-lWqDPKHRbQfi+zNIivf031BUeyciVOtwCwTjyrhDB5g=", + "lastModified": 1703367386, + "narHash": "sha256-FMbm48UGrBfOWGt8+opuS+uLBLQlRfhiYXhHNcYMS5k=", "owner": "rycee", "repo": "home-manager", - "rev": "aeb2232d7a32530d3448318790534d196bf9427a", + "rev": "d5824a76bc6bb93d1dce9ebbbcb09a9b6abcc224", "type": "github" }, "original": { @@ -153,11 +153,11 @@ "nixpkgs": "nixpkgs" }, "locked": { - "lastModified": 1701998434, - "narHash": "sha256-AHJchP91Lfc6LyxGoiP9zdxUVsVLWeioE+LmJbOUZMM=", + "lastModified": 1703898959, + "narHash": "sha256-vBevlls+e3lS1hUlTVyp1SDIo0HBfYQljywP6qpHCpo=", "owner": "nix-community", "repo": "nix-vscode-extensions", - "rev": "4d7b6fe4e29c0529d0a5f836ba41b93baa84f9e3", + "rev": "b67907fb7e477aceb16f87058df6daa53db1449c", "type": "github" }, "original": { @@ -175,11 +175,11 @@ ] }, "locked": { - "lastModified": 1701722881, - "narHash": "sha256-Wim+dqT6W6nTdifu/jmToIzD7eCQaCEhDqDp5kexyfM=", + "lastModified": 1703646364, + "narHash": "sha256-uCj41nq4hnw5aItXJg4DUNpqLSCNRM3xHZbGo8dwoXs=", "owner": "nix-community", "repo": "NixOS-WSL", - "rev": "5ee4fa3515de7b5609e6d161b800d91328a7a143", + "rev": "d72abaf29c40d8f6f9f527815c6dd24f76a50bd4", "type": "github" }, "original": { @@ -206,11 +206,11 @@ }, "nixpkgs_2": { "locked": { - "lastModified": 1701952659, - "narHash": "sha256-TJv2srXt6fYPUjxgLAL0cy4nuf1OZD4KuA1TrCiQqg0=", + "lastModified": 1703467016, + "narHash": "sha256-/5A/dNPhbQx/Oa2d+Get174eNI3LERQ7u6WTWOlR1eQ=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "b4372c4924d9182034066c823df76d6eaf1f4ec4", + "rev": "d02d818f22c777aa4e854efc3242ec451e5d462a", "type": "github" }, "original": { @@ -237,11 +237,11 @@ }, "nur": { "locked": { - "lastModified": 1702050342, - "narHash": "sha256-dZzPltI6K4gL9QGUdWmX3j3e2iClZb+C3wG02ksBvcM=", + "lastModified": 1703900121, + "narHash": "sha256-YB7BXnPnwcOm7Uqa09/5yyGxliJm6vfd0KAId5InTzk=", "owner": "nix-community", "repo": "NUR", - "rev": "1a57d132af8e014fb4c2f30588ab61b3655d665e", + "rev": "0c482ca4bf19209dc57596182b0a67104e61e4a8", "type": "github" }, "original": { @@ -270,11 +270,11 @@ "nixpkgs": "nixpkgs_3" }, "locked": { - "lastModified": 1702001829, - "narHash": "sha256-6gEVidNVqzTb06zIy2Gxhz9m6/jXyAgViRxfgEpZkQ8=", + "lastModified": 1703902408, + "narHash": "sha256-qXdWvu+tlgNjeoz8yQMRKSom6QyRROfgpmeOhwbujqw=", "owner": "oxalica", "repo": "rust-overlay", - "rev": "c2a1dd067a928624c1aab36f976758c0722c79bd", + "rev": "319f57cd2c34348c55970a4bf2b35afe82088681", "type": "github" }, "original": { @@ -360,11 +360,11 @@ }, "unstable": { "locked": { - "lastModified": 1701718080, - "narHash": "sha256-6ovz0pG76dE0P170pmmZex1wWcQoeiomUZGggfH9XPs=", + "lastModified": 1703438236, + "narHash": "sha256-aqVBq1u09yFhL7bj1/xyUeJjzr92fXVvQSSEx6AdB1M=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "2c7f3c0fb7c08a0814627611d9d7d45ab6d75335", + "rev": "5f64a12a728902226210bf01d25ec6cbb9d9265b", "type": "github" }, "original": { From ae0cdfbc5d3ac7668bfbe610495115126f22419a Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Mon, 8 Jan 2024 16:40:20 -0500 Subject: [PATCH 03/77] feat: add vim color scheme --- user/modules/nvim/lazy-lock.json | 1 + user/modules/nvim/lua/plugins/colors.lua | 11 +++++++++++ 2 files changed, 12 insertions(+) create mode 100644 user/modules/nvim/lua/plugins/colors.lua diff --git a/user/modules/nvim/lazy-lock.json b/user/modules/nvim/lazy-lock.json index 8fa1bf1..69082e1 100644 --- a/user/modules/nvim/lazy-lock.json +++ b/user/modules/nvim/lazy-lock.json @@ -24,6 +24,7 @@ "mini.indentscope": { "branch": "main", "commit": "cbc07203ca8faae952ca373c1f6cc5881ce97af0" }, "mini.pairs": { "branch": "main", "commit": "6f6bd7ed5757b40bc29c73dac0d743e4e6978124" }, "mini.surround": { "branch": "main", "commit": "68ce058ef9716d7d955b79363845d2dd003d6500" }, + "monokai-pro.nvim": { "branch": "master", "commit": "b49795aa8a0cb6596660dae31ac10a43eff2d33b" }, "neo-tree.nvim": { "branch": "v3.x", "commit": "0b9a83e6dc47513a81fd9086440d5638683f4f17" }, "neoconf.nvim": { "branch": "main", "commit": "00dcf2b81c45de1768b4171faa16729f0888cfb8" }, "neodev.nvim": { "branch": "main", "commit": "d617d9eb27e73e701e446874c6ea2cb528719260" }, diff --git a/user/modules/nvim/lua/plugins/colors.lua b/user/modules/nvim/lua/plugins/colors.lua new file mode 100644 index 0000000..c0bd750 --- /dev/null +++ b/user/modules/nvim/lua/plugins/colors.lua @@ -0,0 +1,11 @@ +return { + { + "loctvl842/monokai-pro.nvim", + + config = function() + require("monokai-pro").setup() + + vim.cmd([[colorscheme monokai-pro]]) + end, + }, +} From 9570c81a28ea77d446108c2bbe11581bf9011a5b Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Tue, 9 Jan 2024 14:15:50 -0500 Subject: [PATCH 04/77] feat: migrate homebrew packages to nix --- machines/mac/configuration.nix | 12 ++---------- user/environments/mac/home.nix | 4 ++-- user/modules/zsh.nix | 4 ++-- 3 files changed, 6 insertions(+), 14 deletions(-) diff --git a/machines/mac/configuration.nix b/machines/mac/configuration.nix index a0f76b2..d3eea95 100644 --- a/machines/mac/configuration.nix +++ b/machines/mac/configuration.nix @@ -20,8 +20,6 @@ VISUAL = "nvim"; }; systemPackages = with pkgs; [ - # Terminal - git # Containers colima unstable.docker-client @@ -32,6 +30,8 @@ unstable.spicetify-cli # Java checkstyle + # XCode + cocoapods ]; }; @@ -63,21 +63,13 @@ # Upgrade outdated formulae on activation upgrade = true; }; - taps = [ - "ddev/ddev" - "homebrew/cask-fonts" - ]; brews = [ - "cocoapods" "openjdk@17" - "bash" # Required for nix-shell to function properly - "ddev/ddev/ddev" "firefoxpwa" ]; casks = [ "hiddenbar" "android-platform-tools" - "font-caskaydia-cove-nerd-font" "gcenx/wine/wineskin" ]; }; diff --git a/user/environments/mac/home.nix b/user/environments/mac/home.nix index 6e16c52..daa23f8 100644 --- a/user/environments/mac/home.nix +++ b/user/environments/mac/home.nix @@ -14,10 +14,10 @@ firebird-emu ]; - # Add homebrew applications to path programs.zsh = { + # Needed for nix-shell to have the correct bash version profileExtra = '' - PATH=/opt/homebrew/bin:$PATH + PATH=/run/current-system/sw/bin:$PATH ''; prezto.pmodules = [ "osx" diff --git a/user/modules/zsh.nix b/user/modules/zsh.nix index 7e48014..4073c7f 100644 --- a/user/modules/zsh.nix +++ b/user/modules/zsh.nix @@ -12,8 +12,8 @@ src = pkgs.fetchFromGitHub { owner = "chisui"; repo = "zsh-nix-shell"; - rev = "v0.1.0"; - sha256 = "0snhch9hfy83d4amkyxx33izvkhbwmindy0zjjk28hih1a9l2jmx"; + rev = "v0.8.0"; + sha256 = "1lzrn0n4fxfcgg65v0qhnj7wnybybqzs4adz7xsrkgmcsr0ii8b7"; }; } { From 61e883ab3c353b1efa4f062ae81201a816b8f175 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Tue, 9 Jan 2024 14:25:25 -0500 Subject: [PATCH 05/77] chore: update lockfile --- flake.lock | 48 ++++++++++++++++++++++++------------------------ 1 file changed, 24 insertions(+), 24 deletions(-) diff --git a/flake.lock b/flake.lock index 8d629d1..7ecdfe0 100644 --- a/flake.lock +++ b/flake.lock @@ -7,11 +7,11 @@ ] }, "locked": { - "lastModified": 1703887437, - "narHash": "sha256-awkp9jyXf8aV9eDWhLdKUqUdg9HfZKe0NdQebSiC0VA=", + "lastModified": 1704277720, + "narHash": "sha256-meAKNgmh3goankLGWqqpw73pm9IvXjEENJloF0coskE=", "owner": "lnl7", "repo": "nix-darwin", - "rev": "0a3afdc60042d8e1c2deb63bdfa017acc424a397", + "rev": "0dd382b70c351f528561f71a0a7df82c9d2be9a4", "type": "github" }, "original": { @@ -132,11 +132,11 @@ ] }, "locked": { - "lastModified": 1703367386, - "narHash": "sha256-FMbm48UGrBfOWGt8+opuS+uLBLQlRfhiYXhHNcYMS5k=", + "lastModified": 1704099619, + "narHash": "sha256-QRVMkdxLmv+aKGjcgeEg31xtJEIsYq4i1Kbyw5EPS6g=", "owner": "rycee", "repo": "home-manager", - "rev": "d5824a76bc6bb93d1dce9ebbbcb09a9b6abcc224", + "rev": "7e398b3d76bc1503171b1364c9d4a07ac06f3851", "type": "github" }, "original": { @@ -153,11 +153,11 @@ "nixpkgs": "nixpkgs" }, "locked": { - "lastModified": 1703898959, - "narHash": "sha256-vBevlls+e3lS1hUlTVyp1SDIo0HBfYQljywP6qpHCpo=", + "lastModified": 1704763209, + "narHash": "sha256-n++yFjIO8ZxAYCRgfY+82H/2Ng5GQ9vK8N+iq9wqVCs=", "owner": "nix-community", "repo": "nix-vscode-extensions", - "rev": "b67907fb7e477aceb16f87058df6daa53db1449c", + "rev": "c4177ec6600af2f26fe5a8fd14605240130f8e56", "type": "github" }, "original": { @@ -175,11 +175,11 @@ ] }, "locked": { - "lastModified": 1703646364, - "narHash": "sha256-uCj41nq4hnw5aItXJg4DUNpqLSCNRM3xHZbGo8dwoXs=", + "lastModified": 1704677738, + "narHash": "sha256-3WYyt1QitK6+PNngv9QOn1GrxI42PXRDhC+FjAQBHP4=", "owner": "nix-community", "repo": "NixOS-WSL", - "rev": "d72abaf29c40d8f6f9f527815c6dd24f76a50bd4", + "rev": "d8117453224ee4497573ed1b80f3bc62c68cf5be", "type": "github" }, "original": { @@ -206,11 +206,11 @@ }, "nixpkgs_2": { "locked": { - "lastModified": 1703467016, - "narHash": "sha256-/5A/dNPhbQx/Oa2d+Get174eNI3LERQ7u6WTWOlR1eQ=", + "lastModified": 1704420045, + "narHash": "sha256-C36QmoJd5tdQ5R9MC1jM7fBkZW9zBUqbUCsgwS6j4QU=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "d02d818f22c777aa4e854efc3242ec451e5d462a", + "rev": "c1be43e8e837b8dbee2b3665a007e761680f0c3d", "type": "github" }, "original": { @@ -237,11 +237,11 @@ }, "nur": { "locked": { - "lastModified": 1703900121, - "narHash": "sha256-YB7BXnPnwcOm7Uqa09/5yyGxliJm6vfd0KAId5InTzk=", + "lastModified": 1704818955, + "narHash": "sha256-andwUQj1sfSMYeZUJ5I++DzlSCK5IHD/U1ziD8cJt5g=", "owner": "nix-community", "repo": "NUR", - "rev": "0c482ca4bf19209dc57596182b0a67104e61e4a8", + "rev": "3db34f87f0972308898521c41a8bbcc4745066ea", "type": "github" }, "original": { @@ -270,11 +270,11 @@ "nixpkgs": "nixpkgs_3" }, "locked": { - "lastModified": 1703902408, - "narHash": "sha256-qXdWvu+tlgNjeoz8yQMRKSom6QyRROfgpmeOhwbujqw=", + "lastModified": 1704766659, + "narHash": "sha256-Q2wQ9jzp4j96HokmhUQey+pyZMp4Fye/ZPSLtBBV1J8=", "owner": "oxalica", "repo": "rust-overlay", - "rev": "319f57cd2c34348c55970a4bf2b35afe82088681", + "rev": "afa87241c19241aca9b7a9103635b82db2b147bb", "type": "github" }, "original": { @@ -360,11 +360,11 @@ }, "unstable": { "locked": { - "lastModified": 1703438236, - "narHash": "sha256-aqVBq1u09yFhL7bj1/xyUeJjzr92fXVvQSSEx6AdB1M=", + "lastModified": 1704538339, + "narHash": "sha256-1734d3mQuux9ySvwf6axRWZRBhtcZA9Q8eftD6EZg6U=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "5f64a12a728902226210bf01d25ec6cbb9d9265b", + "rev": "46ae0210ce163b3cba6c7da08840c1d63de9c701", "type": "github" }, "original": { From 8acc27488bb9d2c0abc4478ccd49afad30278229 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Tue, 9 Jan 2024 17:25:46 -0500 Subject: [PATCH 06/77] feat: install java using nix --- machines/mac/configuration.nix | 1 - user/modules/dev.nix | 5 +++++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/machines/mac/configuration.nix b/machines/mac/configuration.nix index d3eea95..9915023 100644 --- a/machines/mac/configuration.nix +++ b/machines/mac/configuration.nix @@ -64,7 +64,6 @@ upgrade = true; }; brews = [ - "openjdk@17" "firefoxpwa" ]; casks = [ diff --git a/user/modules/dev.nix b/user/modules/dev.nix index 63203e1..1ba51b5 100644 --- a/user/modules/dev.nix +++ b/user/modules/dev.nix @@ -34,6 +34,11 @@ enable = true; }; + programs.java = { + enable = true; + package = pkgs.jdk17; + }; + # Bun Git config programs.git = { attributes = [ From 07a7a343cb5d16ba50995fda123824464e655c09 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Tue, 9 Jan 2024 17:29:34 -0500 Subject: [PATCH 07/77] chore(mac): remove firefoxpwa --- machines/mac/configuration.nix | 3 --- 1 file changed, 3 deletions(-) diff --git a/machines/mac/configuration.nix b/machines/mac/configuration.nix index 9915023..c1b5328 100644 --- a/machines/mac/configuration.nix +++ b/machines/mac/configuration.nix @@ -63,9 +63,6 @@ # Upgrade outdated formulae on activation upgrade = true; }; - brews = [ - "firefoxpwa" - ]; casks = [ "hiddenbar" "android-platform-tools" From 0ef0b9daccaec044875c3fa89bab4dde2cec7728 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Tue, 9 Jan 2024 17:35:32 -0500 Subject: [PATCH 08/77] chore(mac): remove wineskin --- machines/mac/configuration.nix | 1 - 1 file changed, 1 deletion(-) diff --git a/machines/mac/configuration.nix b/machines/mac/configuration.nix index c1b5328..d6fb55d 100644 --- a/machines/mac/configuration.nix +++ b/machines/mac/configuration.nix @@ -66,7 +66,6 @@ casks = [ "hiddenbar" "android-platform-tools" - "gcenx/wine/wineskin" ]; }; From 799695731081932ca9f0e7a2930cbf7040bc1bd9 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Wed, 10 Jan 2024 10:26:26 -0500 Subject: [PATCH 09/77] fix(vscode): use correct vue plugins --- user/modules/vscode.nix | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/user/modules/vscode.nix b/user/modules/vscode.nix index 1181571..fc8bb00 100644 --- a/user/modules/vscode.nix +++ b/user/modules/vscode.nix @@ -50,7 +50,8 @@ in { astro-build.astro-vscode redwan-hossain.auto-rename-tag-clone bradlc.vscode-tailwindcss - johnsoncodehk.volar + vue.volar + pkgs.vscode-marketplace.vue.vscode-typescript-vue-plugin svelte.svelte-vscode dbaeumer.vscode-eslint esbenp.prettier-vscode From d1ae9c9bccccbd87211dc6bf81c75dd0eff85ebb Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Wed, 10 Jan 2024 10:26:36 -0500 Subject: [PATCH 10/77] feat(vscode): add direnv --- user/modules/vscode.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/user/modules/vscode.nix b/user/modules/vscode.nix index fc8bb00..a5bbfba 100644 --- a/user/modules/vscode.nix +++ b/user/modules/vscode.nix @@ -38,6 +38,7 @@ in { vscodevim.vim pkgs.vscode-marketplace.miguelsolorio.min-theme streetsidesoftware.code-spell-checker + mkhl.direnv # Git mhutchie.git-graph From 35cc2589a55f6af919a429fd9fdee6aed22635ed Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Wed, 10 Jan 2024 10:26:50 -0500 Subject: [PATCH 11/77] feat(vscode): add go plugin --- user/modules/vscode.nix | 3 +++ 1 file changed, 3 insertions(+) diff --git a/user/modules/vscode.nix b/user/modules/vscode.nix index a5bbfba..13660df 100644 --- a/user/modules/vscode.nix +++ b/user/modules/vscode.nix @@ -63,6 +63,9 @@ in { # Dart / Flutter dart-code.dart-code + # Go + golang.go + # Java redhat.java vscjava.vscode-java-debug From 12db0368dc4e281cfcbac2fc6247fc274175ef43 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Wed, 10 Jan 2024 11:25:29 -0500 Subject: [PATCH 12/77] fix(vscode): use prettier as formatter for vue files --- user/modules/vscode/settings.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/user/modules/vscode/settings.json b/user/modules/vscode/settings.json index 34b080c..aa53396 100644 --- a/user/modules/vscode/settings.json +++ b/user/modules/vscode/settings.json @@ -130,7 +130,7 @@ "editor.defaultFormatter": "esbenp.prettier-vscode" }, "[vue]": { - "editor.defaultFormatter": "dbaeumer.vscode-eslint" + "editor.defaultFormatter": "esbenp.prettier-vscode" }, "[markdown]": { "editor.wordWrap": "bounded" From 953e81f06e11957850a46e92f49b5a1571da9467 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Thu, 11 Jan 2024 13:15:38 -0500 Subject: [PATCH 13/77] fix(fonts): remove google-fonts package was causing reloads on macos to freeze the whole system --- user/modules/fonts.nix | 3 --- 1 file changed, 3 deletions(-) diff --git a/user/modules/fonts.nix b/user/modules/fonts.nix index c0ddd68..724ad27 100644 --- a/user/modules/fonts.nix +++ b/user/modules/fonts.nix @@ -1,10 +1,7 @@ {pkgs, ...}: { home.packages = with pkgs; [ (nerdfonts.override {fonts = ["FiraCode"];}) - google-fonts inter cascadia-code ]; - - # fonts.fontconfig.enable = true; } From 73126cf39e24800515496fb1c705bbf05d0648de Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Fri, 12 Jan 2024 20:36:31 -0500 Subject: [PATCH 14/77] chore(nvim): update plugins --- user/modules/nvim/lazy-lock.json | 82 ++++++++++++++++---------------- 1 file changed, 41 insertions(+), 41 deletions(-) diff --git a/user/modules/nvim/lazy-lock.json b/user/modules/nvim/lazy-lock.json index 69082e1..7a015db 100644 --- a/user/modules/nvim/lazy-lock.json +++ b/user/modules/nvim/lazy-lock.json @@ -1,52 +1,52 @@ { - "LazyVim": { "branch": "main", "commit": "e996eed750aabdfaa976357450f9ccbcd333a785" }, - "LuaSnip": { "branch": "master", "commit": "80a8528f084a97b624ae443a6f50ff8074ba486b" }, - "bufferline.nvim": { "branch": "main", "commit": "357cc8f8eeb64702e6fcf2995e3b9becee99a5d3" }, - "catppuccin": { "branch": "main", "commit": "dcef0a062de380885193fb0f919217d58b979753" }, + "LazyVim": { "branch": "main", "commit": "879e29504d43e9f178d967ecc34d482f902e5a91" }, + "LuaSnip": { "branch": "master", "commit": "82108e7e31cc6fc223cc5df5cae6d89f70bb199f" }, + "bufferline.nvim": { "branch": "main", "commit": "e48ce1805697e4bb97bc171c081e849a65859244" }, + "catppuccin": { "branch": "main", "commit": "5e36ca599f4aa41bdd87fbf2c5aae4397ac55074" }, "cmp-buffer": { "branch": "main", "commit": "3022dbc9166796b644a841a02de8dd1cc1d311fa" }, - "cmp-nvim-lsp": { "branch": "main", "commit": "44b16d11215dce86f253ce0c30949813c0a90765" }, + "cmp-nvim-lsp": { "branch": "main", "commit": "5af77f54de1b16c34b23cba810150689a3a90312" }, "cmp-path": { "branch": "main", "commit": "91ff86cd9c29299a64f968ebb45846c485725f23" }, "cmp_luasnip": { "branch": "master", "commit": "05a9ab28b53f71d1aece421ef32fee2cb857a843" }, - "conform.nvim": { "branch": "master", "commit": "7f5ff6d253ae3543f186787bccafdc411d3f4b0a" }, - "dashboard-nvim": { "branch": "master", "commit": "c71cab740e2add248c54c458b5ca9d6e77c30fa6" }, - "dressing.nvim": { "branch": "master", "commit": "1f2d1206a03bd3add8aedf6251e4534611de577f" }, + "conform.nvim": { "branch": "master", "commit": "75e7c5c7eb5fbd53f8b12dc420b31ec70770b231" }, + "dashboard-nvim": { "branch": "master", "commit": "63df28409d940f9cac0a925df09d3dc369db9841" }, + "dressing.nvim": { "branch": "master", "commit": "94b0d24483d56f3777ee0c8dc51675f21709318c" }, "flash.nvim": { "branch": "main", "commit": "48817af25f51c0590653bbc290866e4890fe1cbe" }, - "friendly-snippets": { "branch": "main", "commit": "43727c2ff84240e55d4069ec3e6158d74cb534b6" }, - "gitsigns.nvim": { "branch": "main", "commit": "5a9a6ac29a7805c4783cda21b80a1e361964b3f2" }, - "indent-blankline.nvim": { "branch": "master", "commit": "2546441840172cc41e70f67c52e205cc7aa3e6ed" }, - "lazy.nvim": { "branch": "main", "commit": "4c75c8eeb957a99aa44ce8e526c04340ab358c5e" }, - "lualine.nvim": { "branch": "master", "commit": "2248ef254d0a1488a72041cfb45ca9caada6d994" }, - "mason-lspconfig.nvim": { "branch": "main", "commit": "09be3766669bfbabbe2863c624749d8da392c916" }, - "mason.nvim": { "branch": "main", "commit": "cd7835b15f5a4204fc37e0aa739347472121a54c" }, - "mini.ai": { "branch": "main", "commit": "10ad2ed049fb681a829b44aeb23443c0a9c910ae" }, - "mini.bufremove": { "branch": "main", "commit": "f53c7f27e36009fe61563c11cde154b94a0e5b94" }, - "mini.comment": { "branch": "main", "commit": "e4320af992cd053a7da2f33d9f63a86c2ab6ce59" }, - "mini.indentscope": { "branch": "main", "commit": "cbc07203ca8faae952ca373c1f6cc5881ce97af0" }, - "mini.pairs": { "branch": "main", "commit": "6f6bd7ed5757b40bc29c73dac0d743e4e6978124" }, - "mini.surround": { "branch": "main", "commit": "68ce058ef9716d7d955b79363845d2dd003d6500" }, + "friendly-snippets": { "branch": "main", "commit": "69a2c1675b66e002799f5eef803b87a12f593049" }, + "gitsigns.nvim": { "branch": "main", "commit": "4aaacbf5e5e2218fd05eb75703fe9e0f85335803" }, + "indent-blankline.nvim": { "branch": "master", "commit": "12e92044d313c54c438bd786d11684c88f6f78cd" }, + "lazy.nvim": { "branch": "main", "commit": "96584866b9c5e998cbae300594d0ccfd0c464627" }, + "lualine.nvim": { "branch": "master", "commit": "566b7036f717f3d676362742630518a47f132fff" }, + "mason-lspconfig.nvim": { "branch": "main", "commit": "0989bdf4fdf7b5aa4c74131d7ffccc3f399ac788" }, + "mason.nvim": { "branch": "main", "commit": "e110bc3be1a7309617cecd77bfe4bf86ba1b8134" }, + "mini.ai": { "branch": "main", "commit": "f7787cff9cc42004f722ca1e64e6af4e64e34177" }, + "mini.bufremove": { "branch": "main", "commit": "020243bfed8c8b941f2c20626faf3ea39c0c0e1b" }, + "mini.comment": { "branch": "main", "commit": "67f00d3ebbeae15e84584d971d0c32aad4f4f3a4" }, + "mini.indentscope": { "branch": "main", "commit": "5a8369475cd7cd6f207a4d288406d03b0fc48bdb" }, + "mini.pairs": { "branch": "main", "commit": "552062017ff207e1f35f7028bfb3f27c7421d22d" }, + "mini.surround": { "branch": "main", "commit": "7bf8915ba15d7a4f3c2afe7868d3c15a858d73f1" }, "monokai-pro.nvim": { "branch": "master", "commit": "b49795aa8a0cb6596660dae31ac10a43eff2d33b" }, - "neo-tree.nvim": { "branch": "v3.x", "commit": "0b9a83e6dc47513a81fd9086440d5638683f4f17" }, - "neoconf.nvim": { "branch": "main", "commit": "00dcf2b81c45de1768b4171faa16729f0888cfb8" }, - "neodev.nvim": { "branch": "main", "commit": "d617d9eb27e73e701e446874c6ea2cb528719260" }, - "noice.nvim": { "branch": "main", "commit": "8f1b53ab85f83e0687d0f267085ad781ec240432" }, - "nui.nvim": { "branch": "main", "commit": "c0c8e347ceac53030f5c1ece1c5a5b6a17a25b32" }, - "nvim-cmp": { "branch": "main", "commit": "d3a3056204e1a9dbb7c7fe36c114dc43b681768c" }, - "nvim-lint": { "branch": "master", "commit": "a4b0511a9e757e78c8c9f9d3f201e0d8ff158b42" }, - "nvim-lspconfig": { "branch": "master", "commit": "6428fcab6f3c09e934bc016c329806314384a41e" }, - "nvim-notify": { "branch": "master", "commit": "e4a2022f4fec2d5ebc79afa612f96d8b11c627b3" }, - "nvim-spectre": { "branch": "master", "commit": "696cff781a4a7ecc91549736835e2acbd00fe859" }, - "nvim-treesitter": { "branch": "master", "commit": "0b50cf159283855b72f4c6b22f5ba3c9cf813b37" }, - "nvim-treesitter-context": { "branch": "master", "commit": "8aa32aa6b84dda357849dbc0f775e69f2e04c041" }, - "nvim-treesitter-textobjects": { "branch": "master", "commit": "eb208bfdfcf76efea0424747e23e44641e13aaa6" }, - "nvim-ts-autotag": { "branch": "main", "commit": "6be1192965df35f94b8ea6d323354f7dc7a557e4" }, - "nvim-ts-context-commentstring": { "branch": "main", "commit": "92e688f013c69f90c9bbd596019ec10235bc51de" }, - "nvim-web-devicons": { "branch": "master", "commit": "f0267921c845c42685968401bc49aa65e18d3e09" }, + "neo-tree.nvim": { "branch": "v3.x", "commit": "77d9f484b88fd380386b46ed9206e5374d69d9d8" }, + "neoconf.nvim": { "branch": "main", "commit": "64437787dba70fce50dad7bfbb97d184c5bc340f" }, + "neodev.nvim": { "branch": "main", "commit": "dde00106b9094f101980b364fae02fd85d357306" }, + "noice.nvim": { "branch": "main", "commit": "92433164e2f7118d4122c7674c3834d9511722ba" }, + "nui.nvim": { "branch": "main", "commit": "35da9ca1de0fc4dda96c2e214d93d363c145f418" }, + "nvim-cmp": { "branch": "main", "commit": "538e37ba87284942c1d76ed38dd497e54e65b891" }, + "nvim-lint": { "branch": "master", "commit": "8df53b5dde8ea80f0a039775777eae6648a10229" }, + "nvim-lspconfig": { "branch": "master", "commit": "e47ccfae775f0d572ef0f3a7d245f043b259dafc" }, + "nvim-notify": { "branch": "master", "commit": "1576123bff3bed67bc673a3076e591abfe5d8ca9" }, + "nvim-spectre": { "branch": "master", "commit": "d8906855f1949ac97b1e77aaf8d3fe12ed158ddc" }, + "nvim-treesitter": { "branch": "master", "commit": "8cd2b230174efbf7b5d9f49fe2f90bda6b5eb16e" }, + "nvim-treesitter-context": { "branch": "master", "commit": "400a99ad43ac78af1148061da3491cba2637ad29" }, + "nvim-treesitter-textobjects": { "branch": "master", "commit": "85b9d0cbd4ff901abcda862b50dbb34e0901848b" }, + "nvim-ts-autotag": { "branch": "main", "commit": "8515e48a277a2f4947d91004d9aa92c29fdc5e18" }, + "nvim-ts-context-commentstring": { "branch": "main", "commit": "1277b4a1f451b0f18c0790e1a7f12e1e5fdebfee" }, + "nvim-web-devicons": { "branch": "master", "commit": "db0c864375c198cacc171ff373e76bfce2a85045" }, "persistence.nvim": { "branch": "main", "commit": "ad538bfd5336f1335cdb6fd4e0b0eebfa6e12f32" }, - "plenary.nvim": { "branch": "master", "commit": "50012918b2fc8357b87cff2a7f7f0446e47da174" }, + "plenary.nvim": { "branch": "master", "commit": "55d9fe89e33efd26f532ef20223e5f9430c8b0c0" }, "telescope-fzf-native.nvim": { "branch": "main", "commit": "6c921ca12321edaa773e324ef64ea301a1d0da62" }, - "telescope.nvim": { "branch": "master", "commit": "4522d7e3ea75ffddabdc39957168a8a7060b5df0" }, - "todo-comments.nvim": { "branch": "main", "commit": "3094ead8edfa9040de2421deddec55d3762f64d1" }, - "tokyonight.nvim": { "branch": "main", "commit": "531b04704fc9ff994d8b9c0720428fdc3c7d49d1" }, + "telescope.nvim": { "branch": "master", "commit": "da8b3d485975a8727bea127518b65c980521ae22" }, + "todo-comments.nvim": { "branch": "main", "commit": "4a6737a8d70fe1ac55c64dfa47fcb189ca431872" }, + "tokyonight.nvim": { "branch": "main", "commit": "f247ee700b569ed43f39320413a13ba9b0aef0db" }, "trouble.nvim": { "branch": "main", "commit": "f1168feada93c0154ede4d1fe9183bf69bac54ea" }, "vim-illuminate": { "branch": "master", "commit": "3bd2ab64b5d63b29e05691e624927e5ebbf0fb86" }, "vim-startuptime": { "branch": "master", "commit": "454b3de856b7bd298700de33d79774ca9b9e3875" }, From 148b537c444a1e01fa13bef729c4a0fcaae74890 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Mon, 15 Jan 2024 22:21:24 -0500 Subject: [PATCH 15/77] feat(mac): completely remove homebrew --- machines/mac/configuration.nix | 18 ++---------------- 1 file changed, 2 insertions(+), 16 deletions(-) diff --git a/machines/mac/configuration.nix b/machines/mac/configuration.nix index d6fb55d..5ae9b07 100644 --- a/machines/mac/configuration.nix +++ b/machines/mac/configuration.nix @@ -32,6 +32,8 @@ checkstyle # XCode cocoapods + # Android Development + android-tools ]; }; @@ -53,22 +55,6 @@ nix-daemon.enable = true; }; - homebrew = { - enable = true; - onActivation = { - # Auto update packages - autoUpdate = true; - # Uninstall not listed packages and casks - cleanup = "zap"; - # Upgrade outdated formulae on activation - upgrade = true; - }; - casks = [ - "hiddenbar" - "android-platform-tools" - ]; - }; - nixpkgs = { # Workaround for pyopenssl being marked broken config.allowBroken = true; From 1d4a2c18f5038c834b84abd0dd7bc88661baf081 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Tue, 16 Jan 2024 23:11:52 -0500 Subject: [PATCH 16/77] fix(kitchen): clean up header --- machines/kitchen/configuration.nix | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/machines/kitchen/configuration.nix b/machines/kitchen/configuration.nix index 19b7d29..54d32b8 100644 --- a/machines/kitchen/configuration.nix +++ b/machines/kitchen/configuration.nix @@ -1,11 +1,4 @@ -# Edit this configuration file to define what should be installed on -# your system. Help is available in the configuration.nix(5) man page -# and in the NixOS manual (accessible by running ‘nixos-help’). -{ - config, - pkgs, - ... -}: { +{pkgs, ...}: { imports = [ # Include the results of the hardware scan. ./hardware-configuration.nix From b799c8ff8f7e74696f4b88bf46db46149d12b372 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Tue, 16 Jan 2024 23:12:25 -0500 Subject: [PATCH 17/77] feat(thinkcentre): initial configuration solidified --- machines/thinkcentre/configuration.nix | 103 ++++--------------------- 1 file changed, 16 insertions(+), 87 deletions(-) diff --git a/machines/thinkcentre/configuration.nix b/machines/thinkcentre/configuration.nix index 1e7f9e0..04459d7 100644 --- a/machines/thinkcentre/configuration.nix +++ b/machines/thinkcentre/configuration.nix @@ -1,28 +1,10 @@ -# Edit this configuration file to define what should be installed on -# your system. Help is available in the configuration.nix(5) man page -# and in the NixOS manual (accessible by running ‘nixos-help’). +{pkgs, ...}: { + imports = [ + # Include the results of the hardware scan. + ./hardware-configuration.nix + ]; -{ config, pkgs, ... }: - -{ - imports = - [ # Include the results of the hardware scan. - ./hardware-configuration.nix - ]; - - # Bootloader. - boot.loader.systemd-boot.enable = true; - boot.loader.efi.canTouchEfiVariables = true; - - networking.hostName = "nixos"; # Define your hostname. - # networking.wireless.enable = true; # Enables wireless support via wpa_supplicant. - - # Configure network proxy if necessary - # networking.proxy.default = "http://user:password@proxy:port/"; - # networking.proxy.noProxy = "127.0.0.1,localhost,internal.domain"; - - # Enable networking - networking.networkmanager.enable = true; + networking.hostName = "venus"; # Define your hostname. # Set your time zone. time.timeZone = "America/New_York"; @@ -42,82 +24,30 @@ LC_TIME = "en_US.UTF-8"; }; - # Enable the X11 windowing system. - services.xserver.enable = true; - - # Enable the GNOME Desktop Environment. - services.xserver.displayManager.gdm.enable = true; - services.xserver.desktopManager.gnome.enable = true; - # Configure keymap in X11 services.xserver = { layout = "us"; xkbVariant = ""; }; - # Enable CUPS to print documents. - services.printing.enable = true; + swapDevices = [ + { + device = "/swapfile"; + priority = 0; + size = 16384; + } + ]; - # Enable sound with pipewire. - sound.enable = true; - hardware.pulseaudio.enable = false; - security.rtkit.enable = true; - services.pipewire = { - enable = true; - alsa.enable = true; - alsa.support32Bit = true; - pulse.enable = true; - # If you want to use JACK applications, uncomment this - #jack.enable = true; - - # use the example session manager (no others are packaged yet so this is enabled by default, - # no need to redefine it in your config for now) - #media-session.enable = true; - }; - - # Enable touchpad support (enabled default in most desktopManager). - # services.xserver.libinput.enable = true; + programs.zsh.enable = true; # Define a user account. Don't forget to set a password with ‘passwd’. users.users.michael = { isNormalUser = true; description = "Michael Thomas"; - extraGroups = [ "networkmanager" "wheel" ]; - packages = with pkgs; [ - firefox - # thunderbird - ]; + extraGroups = ["wheel" "docker" "podman" "adbusers" "dialout"]; + shell = pkgs.zsh; }; - # Allow unfree packages - nixpkgs.config.allowUnfree = true; - - # List packages installed in system profile. To search, run: - # $ nix search wget - environment.systemPackages = with pkgs; [ - # vim # Do not forget to add an editor to edit configuration.nix! The Nano editor is also installed by default. - # wget - ]; - - # Some programs need SUID wrappers, can be configured further or are - # started in user sessions. - # programs.mtr.enable = true; - # programs.gnupg.agent = { - # enable = true; - # enableSSHSupport = true; - # }; - - # List services that you want to enable: - - # Enable the OpenSSH daemon. - # services.openssh.enable = true; - - # Open ports in the firewall. - # networking.firewall.allowedTCPPorts = [ ... ]; - # networking.firewall.allowedUDPPorts = [ ... ]; - # Or disable the firewall altogether. - # networking.firewall.enable = false; - # This value determines the NixOS release from which the default # settings for stateful data, like file locations and database versions # on your system were taken. It‘s perfectly fine and recommended to leave @@ -125,5 +55,4 @@ # Before changing this value read the documentation for this option # (e.g. man configuration.nix or on https://nixos.org/nixos/options.html). system.stateVersion = "23.11"; # Did you read the comment? - } From 9c6793a9738132308eb002fcab953d2ffd097552 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Tue, 16 Jan 2024 23:12:42 -0500 Subject: [PATCH 18/77] feat(sound): enable pipewire --- modules/sound.nix | 17 ++++++++++++++++- 1 file changed, 16 insertions(+), 1 deletion(-) diff --git a/modules/sound.nix b/modules/sound.nix index 8c32227..e0f7994 100644 --- a/modules/sound.nix +++ b/modules/sound.nix @@ -1,5 +1,20 @@ { # Enable sound. sound.enable = true; - hardware.pulseaudio.enable = true; + hardware.pulseaudio.enable = false; + security.rtkit.enable = true; + + # Enable pipewire + services.pipewire = { + enable = true; + alsa.enable = true; + alsa.support32Bit = true; + pulse.enable = true; + # If you want to use JACK applications, uncomment this + #jack.enable = true; + + # use the example session manager (no others are packaged yet so this is enabled by default, + # no need to redefine it in your config for now) + #media-session.enable = true; + }; } From 80596625b28a6866fd963f9b41399ad7e7ccf0a8 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Tue, 16 Jan 2024 23:13:09 -0500 Subject: [PATCH 19/77] feat(git_nixos): support oauth credential verification --- user/modules/git_nixos.nix | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/user/modules/git_nixos.nix b/user/modules/git_nixos.nix index c48e043..81d9dd7 100644 --- a/user/modules/git_nixos.nix +++ b/user/modules/git_nixos.nix @@ -1,9 +1,12 @@ {pkgs, ...}: { - # Use pkgs.gitAndTools.gitFull in order to get libsecret support programs.git = { package = pkgs.gitAndTools.gitFull; extraConfig = { - credential.helper = "libsecret"; + credential.helper = "oauth"; }; }; + + home.packages = with pkgs; [ + git-credential-oauth + ]; } From afb572e1b9150ed0b004ff1200286ea58e66067e Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Tue, 16 Jan 2024 23:13:32 -0500 Subject: [PATCH 20/77] feat(thinkcentre): add home-manager modules --- flake.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/flake.nix b/flake.nix index 37460da..c5eb652 100644 --- a/flake.nix +++ b/flake.nix @@ -103,8 +103,8 @@ modules = [ self.overlaysModule home-manager.nixosModules.home-manager - # ./modules/common.nix - # ./modules/containers.nix + ./modules/common.nix + ./modules/containers.nix { home-manager.useGlobalPkgs = true; home-manager.useUserPackages = true; From 287f3f959371a3938d4fc5c9e78c30b7a6616221 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Tue, 16 Jan 2024 23:13:46 -0500 Subject: [PATCH 21/77] fix(bootloader): add quiet param --- modules/bootloader.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/modules/bootloader.nix b/modules/bootloader.nix index b8c0550..760e6d2 100644 --- a/modules/bootloader.nix +++ b/modules/bootloader.nix @@ -4,4 +4,5 @@ boot.loader.systemd-boot.enable = true; boot.loader.efi.canTouchEfiVariables = false; boot.plymouth.enable = true; + boot.kernelParams = ["quiet"]; } From 0b7b01fe884be86897120c08f8d9efe6215bd53a Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Wed, 17 Jan 2024 11:44:16 -0500 Subject: [PATCH 22/77] feat: init emacs --- user/environments/mac/home.nix | 1 + user/modules/emacs.nix | 7 +++++++ 2 files changed, 8 insertions(+) create mode 100644 user/modules/emacs.nix diff --git a/user/environments/mac/home.nix b/user/environments/mac/home.nix index daa23f8..670efbd 100644 --- a/user/environments/mac/home.nix +++ b/user/environments/mac/home.nix @@ -2,6 +2,7 @@ imports = [ ../../modules/zsh.nix ../../modules/dev.nix + ../../modules/emacs.nix ../../modules/git.nix ../../modules/fonts.nix ../../modules/latex.nix diff --git a/user/modules/emacs.nix b/user/modules/emacs.nix new file mode 100644 index 0000000..6424dac --- /dev/null +++ b/user/modules/emacs.nix @@ -0,0 +1,7 @@ +{pkgs, ...}: { + programs.emacs = { + enable = true; + package = pkgs.unstable.emacs; + extraPackages = epkgs: [epkgs.vterm]; + }; +} From 547713889259fe197aabae01475bc74a989ef8a0 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Wed, 17 Jan 2024 13:30:00 -0500 Subject: [PATCH 23/77] fix(common): disable broken automatic upgrades --- modules/common.nix | 1 - 1 file changed, 1 deletion(-) diff --git a/modules/common.nix b/modules/common.nix index b3bc209..9bfdaee 100644 --- a/modules/common.nix +++ b/modules/common.nix @@ -1,6 +1,5 @@ { imports = [ - ./auto-upgrades.nix ./avahi.nix ./bootloader.nix ./cups.nix From 916dd9fd913c838c13cddd4edb989b6f3b983648 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Thu, 18 Jan 2024 13:16:29 -0500 Subject: [PATCH 24/77] feat(mac): add yabai --- flake.nix | 1 + modules/yabai.nix | 58 +++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 59 insertions(+) create mode 100644 modules/yabai.nix diff --git a/flake.nix b/flake.nix index c5eb652..7653ea0 100644 --- a/flake.nix +++ b/flake.nix @@ -145,6 +145,7 @@ home-manager.users.michael = import ./user/environments/mac/home.nix; } + ./modules/yabai.nix ./machines/mac/configuration.nix ]; }; diff --git a/modules/yabai.nix b/modules/yabai.nix new file mode 100644 index 0000000..bc4b6d2 --- /dev/null +++ b/modules/yabai.nix @@ -0,0 +1,58 @@ +{...}: { + services.yabai = { + enable = true; + config = { + mouse_follows_focus = "off"; + focus_follows_mouse = "off"; + window_origin_display = "default"; + window_placement = "second_child"; + window_zoom_persist = "on"; + window_shadow = "on"; + window_animation_duration = 0; + window_animation_frame_rate = 120; + window_opacity_duration = 0; + active_window_opacity = 1; + normal_window_opacity = 0; + window_opacity = "off"; + insert_feedback_color = "0xffd75f5f"; + split_ratio = 0; + split_type = "auto"; + auto_balance = "off"; + top_padding = 12; + bottom_padding = 12; + left_padding = 12; + right_padding = 12; + window_gap = 06; + layout = "bsp"; + mouse_modifier = "fn"; + mouse_action1 = "move"; + mouse_action2 = "resize"; + mouse_drop_action = "swap"; + }; + }; + + services.skhd = { + enable = true; + skhdConfig = '' + alt - h: yabai -m window --focus west + alt - j: yabai -m window --focus south + alt - k: yabai -m window --focus north + alt - l: yabai -m window --focus east + + shift + alt - h : yabai -m window --warp east + shift + alt - j : yabai -m window --warp north + shift + alt - k : yabai -m window --warp south + shift + alt - l : yabai -m window --warp west + + cmd + alt - 1 : yabai -m space --focus 1 + cmd + alt - 2 : yabai -m space --focus 2 + cmd + alt - 3 : yabai -m space --focus 3 + cmd + alt - 4 : yabai -m space --focus 4 + cmd + alt - 5 : yabai -m space --focus 5 + cmd + alt - 6 : yabai -m space --focus 6 + cmd + alt - 7 : yabai -m space --focus 7 + cmd + alt - 8 : yabai -m space --focus 8 + cmd + alt - 9 : yabai -m space --focus 9 + ''; + }; +} From db0ea6832b54ad5a5c19044b455635aaa8b6bfe1 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Sat, 20 Jan 2024 16:48:58 -0500 Subject: [PATCH 25/77] feat(bluetooth): add module --- modules/bluetooth.nix | 5 +++++ modules/common.nix | 1 + 2 files changed, 6 insertions(+) create mode 100644 modules/bluetooth.nix diff --git a/modules/bluetooth.nix b/modules/bluetooth.nix new file mode 100644 index 0000000..d109ddb --- /dev/null +++ b/modules/bluetooth.nix @@ -0,0 +1,5 @@ +{...}: { + hardware.bluetooth.enable = true; + + services.blueman.enable = true; +} diff --git a/modules/common.nix b/modules/common.nix index 9bfdaee..0d7a711 100644 --- a/modules/common.nix +++ b/modules/common.nix @@ -1,6 +1,7 @@ { imports = [ ./avahi.nix + ./bluetooth.nix ./bootloader.nix ./cups.nix ./flatpak.nix From 755dff4a9ebcf0787766fc3da76ce90ffe4b7599 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Sat, 20 Jan 2024 16:52:40 -0500 Subject: [PATCH 26/77] feat(hyprland): add modules --- flake.nix | 1 + modules/hyprland.nix | 39 ++++ user/environments/nixos/home.nix | 3 +- user/modules/hyprland.nix | 104 +++++++++++ user/modules/waybar/default.nix | 59 +++++++ .../modules/waybar/modules/custom-modules.nix | 107 +++++++++++ .../waybar/modules/default-modules.nix | 166 ++++++++++++++++++ user/modules/waybar/modules/group-modules.nix | 84 +++++++++ .../waybar/modules/hyprland-modules.nix | 95 ++++++++++ user/modules/waybar/modules/wlr-modules.nix | 46 +++++ user/modules/waybar/styles/catppuccin.css | 36 ++++ user/modules/waybar/styles/notifications.css | 82 +++++++++ user/modules/waybar/styles/power.css | 14 ++ user/modules/waybar/styles/stats.css | 43 +++++ user/modules/waybar/styles/style.css | 77 ++++++++ user/modules/waybar/styles/workspaces.css | 42 +++++ user/modules/wofi.nix | 5 + 17 files changed, 1002 insertions(+), 1 deletion(-) create mode 100644 modules/hyprland.nix create mode 100644 user/modules/hyprland.nix create mode 100644 user/modules/waybar/default.nix create mode 100644 user/modules/waybar/modules/custom-modules.nix create mode 100644 user/modules/waybar/modules/default-modules.nix create mode 100644 user/modules/waybar/modules/group-modules.nix create mode 100644 user/modules/waybar/modules/hyprland-modules.nix create mode 100644 user/modules/waybar/modules/wlr-modules.nix create mode 100644 user/modules/waybar/styles/catppuccin.css create mode 100644 user/modules/waybar/styles/notifications.css create mode 100644 user/modules/waybar/styles/power.css create mode 100644 user/modules/waybar/styles/stats.css create mode 100644 user/modules/waybar/styles/style.css create mode 100644 user/modules/waybar/styles/workspaces.css create mode 100644 user/modules/wofi.nix diff --git a/flake.nix b/flake.nix index c5eb652..ccd50f4 100644 --- a/flake.nix +++ b/flake.nix @@ -104,6 +104,7 @@ self.overlaysModule home-manager.nixosModules.home-manager ./modules/common.nix + ./modules/hyprland.nix ./modules/containers.nix { home-manager.useGlobalPkgs = true; diff --git a/modules/hyprland.nix b/modules/hyprland.nix new file mode 100644 index 0000000..38a8f27 --- /dev/null +++ b/modules/hyprland.nix @@ -0,0 +1,39 @@ +{pkgs, ...}: { + programs.hyprland = { + enable = true; + package = pkgs.unstable.hyprland; + }; + + environment.systemPackages = with pkgs; [ + # Theme + adw-gtk3 + + # Greeter + cage + greetd.gtkgreet + + # Applications + gnome.nautilus + gnome.sushi + gnome.eog + gnome.totem + gnome.cheese + gnome.file-roller + gnome.gnome-weather + gnome.gnome-contacts + gnome.gnome-calendar + gnome.gnome-screenshot + gnome.gnome-dictionary + gnome.gnome-font-viewer + gnome.gnome-system-monitor + ]; + + services.greetd = { + enable = true; + settings = { + default_session = { + command = "cage -s -- gtkgreet --command=Hyprland"; + }; + }; + }; +} diff --git a/user/environments/nixos/home.nix b/user/environments/nixos/home.nix index 80caea4..5414e6f 100644 --- a/user/environments/nixos/home.nix +++ b/user/environments/nixos/home.nix @@ -3,9 +3,10 @@ ../../modules/dev.nix ../../modules/firefox.nix ../../modules/fonts.nix + ../../modules/foot.nix ../../modules/git.nix ../../modules/git_nixos.nix - ../../modules/gnome.nix + ../../modules/hyprland.nix ../../modules/nvim.nix ../../modules/vscode.nix ../../modules/zsh.nix diff --git a/user/modules/hyprland.nix b/user/modules/hyprland.nix new file mode 100644 index 0000000..6e525a9 --- /dev/null +++ b/user/modules/hyprland.nix @@ -0,0 +1,104 @@ +{pkgs, ...}: { + imports = [ + ./waybar + ./wofi + ]; + + home.packages = with pkgs; [ + pavucontrol + swaynotificationcenter + ]; + + wayland.windowManager.hyprland = { + enable = true; + package = pkgs.unstable.hyprland; + settings = { + "$mod" = "SUPER"; + general = { + gaps_in = 5; + gaps_out = 10; + }; + input = { + follow_mouse = 2; + }; + exec-once = [ + "hyprctl setcursor Adwaita 24" + "waybar" + "swaync" + ]; + bind = + [ + # Program launcher + "$mod, SPACE, exec, wofi --show drun" + # Program shortcuts + "$mod, F, exec, firefox" + "$mod, Q, killactive" + "$mod, T, exec, foot" + ", Print, exec, grimblast copy area" + # Windows + "$mod, H, movefocus, l" + "$mod, J, movefocus, d" + "$mod, K, movefocus, u" + "$mod, L, movefocus, r" + # Moving windows + "$mod SHIFT, H, movewindow, l" + "$mod SHIFT, J, movewindow, d" + "$mod SHIFT, K, movewindow, u" + "$mod SHIFT, L, movewindow, r" + ] + ++ ( + # workspaces + # binds $mod + [shift +] {1..10} to [move to] workspace {1..10} + builtins.concatLists (builtins.genList ( + x: let + ws = let + c = (x + 1) / 10; + in + builtins.toString (x + 1 - (c * 10)); + in [ + "$mod, ${ws}, workspace, ${toString (x + 1)}" + "$mod SHIFT, ${ws}, movetoworkspace, ${toString (x + 1)}" + ] + ) + 10) + ); + }; + extraConfig = '' + # will switch to a submap called resize + bind=$mod,R,submap,resize + + # will start a submap called "resize" + submap=resize + + # sets repeatable binds for resizing the active window + binde=,h,resizeactive,-10 0 + binde=,j,resizeactive,0 10 + binde=,k,resizeactive,0 -10 + binde=,l,resizeactive,10 0 + + # use reset to go back to the global submap + bind=,escape,submap,reset + + # will reset the submap, meaning end the current one and return to the global one + submap=reset + ''; + }; + + gtk = { + enable = true; + font.name = "Inter 11"; + theme = { + name = "adw-gtk3-dark"; + package = pkgs.adw-gtk3; + }; + iconTheme = { + name = "Papirus"; + package = pkgs.papirus-icon-theme; + }; + cursorTheme = { + name = "Adwaita"; + package = pkgs.gnome.adwaita-icon-theme; + size = 24; + }; + }; +} diff --git a/user/modules/waybar/default.nix b/user/modules/waybar/default.nix new file mode 100644 index 0000000..20cc504 --- /dev/null +++ b/user/modules/waybar/default.nix @@ -0,0 +1,59 @@ +{ + config, + lib, + pkgs, + ... +}: let + inherit (lib) mkMerge; + + theme = builtins.readFile ./styles/catppuccin.css; + style = builtins.readFile ./styles/style.css; + notificationsStyle = builtins.readFile ./styles/notifications.css; + powerStyle = builtins.readFile ./styles/power.css; + statsStyle = builtins.readFile ./styles/stats.css; + workspacesStyle = builtins.readFile ./styles/workspaces.css; + + custom-modules = import ./modules/custom-modules.nix {inherit config lib pkgs;}; + default-modules = import ./modules/default-modules.nix {inherit lib pkgs;}; + group-modules = import ./modules/group-modules.nix; + hyprland-modules = import ./modules/hyprland-modules.nix {inherit config lib;}; + + allModules = mkMerge [ + custom-modules + default-modules + group-modules + hyprland-modules + ]; +in { + programs.waybar = { + enable = true; + style = "${theme}${style}${notificationsStyle}${powerStyle}${statsStyle}${workspacesStyle}"; + settings = { + mainBar = mkMerge [ + { + name = "main"; + "margin-top" = 10; + "margin-left" = 10; + "margin-right" = 10; + layer = "top"; + # Choose the order of the modules + "modules-left" = [ + "group/power" + "hyprland/workspaces" + ]; + "modules-center" = [ + "clock" + ]; + "modules-right" = [ + "group/tray-drawer" + "group/stats-drawer" + "group/notifications" + "hyprland/submap" + "custom/weather" + ]; + } + allModules + ]; + }; + }; +} diff --git a/user/modules/waybar/modules/custom-modules.nix b/user/modules/waybar/modules/custom-modules.nix new file mode 100644 index 0000000..f954291 --- /dev/null +++ b/user/modules/waybar/modules/custom-modules.nix @@ -0,0 +1,107 @@ +{ config +, lib +, pkgs +, ... +}: +let + inherit (lib) getExe getExe'; + + githubHelper = pkgs.writeShellScriptBin "githubHelper" /* bash */ '' + #!/usr/bin/env bash + + NOTIFICATIONS="$(${getExe pkgs.gh} api notifications)" + COUNT="$(echo "$NOTIFICATIONS" | ${getExe pkgs.jq} 'length')" + + echo '{"text":'"$COUNT"',"tooltip":"'"$COUNT"' Notifications","class":""}' + ''; +in +{ + "custom/ellipses" = { + "format" = ""; + "tooltip" = false; + }; + + "custom/github" = { + "format" = " {}"; + "return-type" = "json"; + "interval" = 60; + "exec" = "${getExe githubHelper}"; + "on-click" = "${getExe' pkgs.coreutils "sleep"} 0.1 && ${getExe' pkgs.xdg-utils "xdg-open"} https://github.com/notifications"; + }; + + "custom/lock" = { + "format" = "󰍁"; + "tooltip" = false; + "on-click" = "${getExe config.programs.swaylock.package}"; + }; + + "custom/media" = { + "format" = "{icon} {}"; + "return-type" = "json"; + "max-length" = 40; + "format-icons" = { + "spotify" = ""; + "default" = "🎜"; + }; + "escape" = true; + "exec" = "$HOME/.config/waybar/mediaplayer.py 2> /dev/null"; + }; + + "custom/notification" = { + "tooltip" = true; + "format" = "{icon} {}"; + "format-icons" = { + "notification" = ""; + "none" = ""; + "dnd-notification" = ""; + "dnd-none" = ""; + "inhibited-notification" = ""; + "inhibited-none" = ""; + "dnd-inhibited-notification" = ""; + "dnd-inhibited-none" = ""; + }; + "return-type" = "json"; + "exec-if" = "which ${getExe' pkgs.swaynotificationcenter "swaync-client"}"; + "exec" = "${getExe' pkgs.swaynotificationcenter "swaync-client"} -swb"; + "on-click" = "${getExe' pkgs.coreutils "sleep"} 0.1 && ${getExe' pkgs.swaynotificationcenter "swaync-client"} -t -sw"; + "on-click-right" = "${getExe' pkgs.coreutils "sleep"} 0.1 && ${getExe' pkgs.swaynotificationcenter "swaync-client"} -d -sw"; + "escape" = true; + }; + + "custom/power" = { + "format" = ""; + "tooltip" = false; + "on-click" = "shutdown now"; + }; + + "custom/reboot" = { + "format" = "󰜉"; + "tooltip" = false; + "on-click" = "reboot"; + }; + + "custom/separator-right" = { + "format" = ""; + "tooltip" = false; + }; + + "custom/separator-left" = { + "format" = ""; + "tooltip" = false; + }; + + "custom/weather" = { + "exec" = "${getExe pkgs.wttrbar} --location $(${getExe pkgs.jq} -r '.wttr | (.location)' ~/weather_config.json) --fahrenheit --main-indicator temp_F"; + "return-type" = "json"; + "format" = "{}"; + "tooltip" = true; + "interval" = 3600; + }; + + "custom/wlogout" = { + "format" = ""; + "interval" = "once"; + "tooltip" = false; + "on-click" = "${getExe' pkgs.coreutils "sleep"} 0.1 && ${getExe pkgs.wlogout} -c 5 -r 5 -p layer-shell"; + }; +} diff --git a/user/modules/waybar/modules/default-modules.nix b/user/modules/waybar/modules/default-modules.nix new file mode 100644 index 0000000..44a3422 --- /dev/null +++ b/user/modules/waybar/modules/default-modules.nix @@ -0,0 +1,166 @@ +{ + lib, + pkgs, + ... +}: let + inherit (lib) getExe getExe'; +in { + "clock" = { + "tooltip-format" = "{:%Y %B}\n{calendar}"; + "format" = "{:%A, %b %d %I:%M %p }"; + "format-alt" = "{:%Y-%m-%d}"; + }; + + "cpu" = { + "format" = " {usage}%"; + "tooltip" = true; + }; + + "disk" = { + "format" = " {percentage_used}%"; + }; + + "idle_inhibitor" = { + "format" = "{icon} "; + "format-icons" = { + "activated" = "󰅶"; + "deactivated" = "󰛊"; + }; + }; + + "keyboard-state" = { + "numlock" = true; + "capslock" = true; + "format" = "{icon} {name}"; + "format-icons" = { + "locked" = ""; + "unlocked" = ""; + }; + }; + + "memory" = { + "format" = "󰍛 {}%"; + }; + + "mpris" = { + "format" = "{player_icon} {status_icon} {dynamic}"; + "format-paused" = "{player_icon} {status_icon} {dynamic}"; + "max-length" = 45; + "player-icons" = { + "chromium" = ""; + "default" = ""; + "firefox" = ""; + "mopidy" = ""; + "mpv" = ""; + "spotify" = ""; + }; + "status-icons" = { + "paused" = ""; + "playing" = ""; + "stopped" = ""; + }; + }; + + "mpd" = { + "format" = "{stateIcon} {consumeIcon}{randomIcon}{repeatIcon}{singleIcon}{artist} - {album} - {title} ({elapsedTime:%M:%S}/{totalTime:%M:%S}) ⸨{songPosition}|{queueLength}⸩ {volume}% "; + "format-disconnected" = "Disconnected "; + "format-stopped" = "{consumeIcon}{randomIcon}{repeatIcon}{singleIcon}Stopped "; + "unknown-tag" = "N/A"; + "interval" = 2; + "consume-icons" = { + "on" = " "; + }; + "random-icons" = { + "off" = " "; + "on" = " "; + }; + "repeat-icons" = { + "on" = " "; + }; + "single-icons" = { + "on" = "1 "; + }; + "state-icons" = { + "paused" = ""; + "playing" = ""; + }; + "tooltip-format" = "MPD (connected)"; + "tooltip-format-disconnected" = "MPD (disconnected)"; + }; + + "network" = { + "interval" = 1; + "format-wifi" = " 󰜮 {bandwidthDownBytes} 󰜷 {bandwidthUpBytes}"; + "format-ethernet" = "󰈀 󰜮 {bandwidthDownBytes} 󰜷 {bandwidthUpBytes}"; + "tooltip-format" = " {ifname} via {gwaddr}"; + "format-linked" = "󰈁 {ifname} (No IP)"; + "format-disconnected" = " Disconnected"; + "format-alt" = "{ifname}: {ipaddr}/{cidr}"; + }; + + "pulseaudio" = { + "format" = "{volume}% {icon}"; + "format-bluetooth" = "{volume}% {icon}"; + "format-muted" = ""; + "format-icons" = { + "headphone" = ""; + "hands-free" = ""; + "headset" = ""; + "phone" = ""; + "portable" = ""; + "car" = ""; + "default" = [ + "" + "" + ]; + }; + "scroll-step" = 1; + "on-click" = "pavucontrol"; + "ignored-sinks" = [ + "Easy Effects Sink" + ]; + }; + + "pulseaudio/slider" = { + "min" = 0; + "max" = 100; + "orientation" = "horizontal"; + }; + + "temperature" = { + "hwmon-path-abs" = "/sys/devices/pci0000:00/0000:00:18.3/hwmon"; + "input-filename" = "temp3_input"; + "critical-threshold" = 80; + "format-critical" = "{temperatureC}°C {icon}"; + "format" = "{icon} {temperatureC}°C"; + "format-icons" = [ + "" + "" + "" + ]; + "interval" = "5"; + }; + + "tray" = { + "spacing" = 10; + }; + + "user" = { + "format" = "{user}"; + "interval" = 60; + "height" = 30; + "width" = 30; + "icon" = true; + }; + + "wireplumber" = { + "format" = "{volume}% {icon}"; + "format-muted" = ""; + "on-click" = "${getExe' pkgs.coreutils "sleep"} 0.1 && ${getExe pkgs.helvum}"; + "format-icons" = [ + "" + "" + "" + ]; + }; +} diff --git a/user/modules/waybar/modules/group-modules.nix b/user/modules/waybar/modules/group-modules.nix new file mode 100644 index 0000000..e9db523 --- /dev/null +++ b/user/modules/waybar/modules/group-modules.nix @@ -0,0 +1,84 @@ +{ + "group/audio" = { + "orientation" = "horizontal"; + "drawer" = { + "transition-duration" = 500; + "transition-left-to-right" = false; + }; + "modules" = [ + "pulseaudio" + "pulseaudio/slider" + ]; + }; + + "group/power" = { + "orientation" = "horizontal"; + "drawer" = { + "transition-duration" = 500; + "children-class" = "not-power"; + "transition-left-to-right" = false; + }; + "modules" = [ + "custom/wlogout" + # "custom/quit" + # "custom/lock" + # "custom/reboot" + ]; + }; + + "group/notifications" = { + "orientation" = "horizontal"; + "modules" = [ + "idle_inhibitor" + "custom/notification" + "custom/github" + "group/audio" + ]; + }; + + "group/tray" = { + "orientation" = "horizontal"; + "modules" = [ + "tray" + ]; + }; + + "group/stats" = { + "orientation" = "horizontal"; + "modules" = [ + "network" + "cpu" + "memory" + "disk" + "temperature" + ]; + }; + + "group/stats-drawer" = { + "orientation" = "horizontal"; + "drawer" = { + "transition-duration" = 500; + "transition-left-to-right" = false; + }; + "modules" = [ + "custom/separator-right" + "network" + "cpu" + "memory" + "disk" + "temperature" + ]; + }; + + "group/tray-drawer" = { + "orientation" = "horizontal"; + "drawer" = { + "transition-duration" = 500; + "transition-left-to-right" = true; + }; + "modules" = [ + "custom/separator-right" + "tray" + ]; + }; +} diff --git a/user/modules/waybar/modules/hyprland-modules.nix b/user/modules/waybar/modules/hyprland-modules.nix new file mode 100644 index 0000000..1bb5386 --- /dev/null +++ b/user/modules/waybar/modules/hyprland-modules.nix @@ -0,0 +1,95 @@ +{ + config, + lib, + ... +}: let + inherit (lib) getExe'; +in { + "custom/quit" = { + "format" = "󰗼"; + "tooltip" = false; + "on-click" = "${getExe' config.wayland.windowManager.hyprland.package "hyprctl"} dispatch exit"; + }; + + "hyprland/submap" = { + "format" = "✌️ {}"; + "max-length" = 8; + "tooltip" = false; + }; + + "hyprland/window" = { + "format" = "{}"; + "separate-outputs" = true; + }; + + "hyprland/workspaces" = { + "all-outputs" = false; + "active-only" = "false"; + "on-scroll-up" = "${getExe' config.wayland.windowManager.hyprland.package "hyprctl"} dispatch workspace e+1"; + "on-scroll-down" = "${getExe' config.wayland.windowManager.hyprland.package "hyprctl"} dispatch workspace e-1"; + "format" = "{icon} {windows}"; + "format-icons" = { + "1" = "󰎤"; + "2" = "󰎧"; + "3" = "󰎪"; + "4" = "󰎭"; + "5" = "󰎱"; + "6" = "󰎳"; + "7" = "󰎶"; + "8" = "󰎹"; + "9" = "󰎼"; + "10" = "󰽽"; + "urgent" = "󱨇"; + "default" = ""; + "empty" = "󱓼"; + }; + "persistent-workspaces" = { + "*" = [ + 2 + 3 + 4 + 5 + 6 + 7 + 8 + ]; + "DP-3" = [ + 1 + ]; + }; + # "format-window-separator" = "->"; + "window-rewrite-default" = ""; + "window-rewrite" = { + "class<1Password>" = "󰢁"; + "class" = "󰈎"; + "class" = "󰊤"; + "class" = ""; + "class" = ""; + "class" = "󰒱"; + "class" = "󰨞"; + "code-url-handler" = "󰨞"; + "class" = "󰙯"; + "class" = "󰈹"; + "class title<.*github.*>" = ""; + "class title<.*twitch|youtube|plex|tntdrama|bally sports.*>" = ""; + "class" = ""; + "class" = ""; + "class" = "󱂷"; + "class" = "󰄄"; + "class" = ""; + "class<.pitivi-wrapped>" = "󱄢"; + "class" = ""; + "class" = ""; + "class" = "󰢹"; + "class" = "󰕼"; + "class" = "󰉋"; + "class" = "󰉋"; + "class" = ""; + "title" = ""; + "class" = "󰽉"; + "class" = ""; + "class" = "󱎏"; + "class" = "󱎐"; + }; + }; +} diff --git a/user/modules/waybar/modules/wlr-modules.nix b/user/modules/waybar/modules/wlr-modules.nix new file mode 100644 index 0000000..5bda91a --- /dev/null +++ b/user/modules/waybar/modules/wlr-modules.nix @@ -0,0 +1,46 @@ +{ + "wlr/workspaces" = { + "all-outputs" = false; + "active-only" = "false"; + "on-click" = "activate"; + "format" = "{icon}"; + "format-icons" = { + "1" = ""; + "2" = ""; + "3" = ""; + "4" = ""; + "5" = ""; + "6" = ""; + "7" = ""; + "8" = "󰢹"; + "urgent" = ""; + "default" = ""; + }; + "persistent_workspaces" = { + "1" = [ + "DP-3" + ]; + "2" = [ + "DP-1" + ]; + "3" = [ + "DP-1" + ]; + "4" = [ + "DP-1" + ]; + "5" = [ + "DP-1" + ]; + "6" = [ + "DP-1" + ]; + "7" = [ + "DP-1" + ]; + "8" = [ + "DP-1" + ]; + }; + }; +} diff --git a/user/modules/waybar/styles/catppuccin.css b/user/modules/waybar/styles/catppuccin.css new file mode 100644 index 0000000..e662b6a --- /dev/null +++ b/user/modules/waybar/styles/catppuccin.css @@ -0,0 +1,36 @@ +/* +* +* Catppuccin Macchiato palette +* +*/ + +@define-color base #24273a; +@define-color mantle #1e2030; +@define-color crust #181926; + +@define-color text #cad3f5; +@define-color subtext0 #b8c0e0; +@define-color subtext1 #a5adcb; + +@define-color surface0 #363a4f; +@define-color surface1 #494d64; +@define-color surface2 #5b6078; + +@define-color overlay0 #6e738d; +@define-color overlay1 #8087a2; +@define-color overlay2 #939ab7; + +@define-color blue #8aadf4; +@define-color lavender #b7bdf8; +@define-color sapphire #7dc4e4; +@define-color sky #91d7e3; +@define-color teal #8bd5ca; +@define-color green #a6da95; +@define-color yellow #eed49f; +@define-color peach #f5a97f; +@define-color maroon #ee99a0; +@define-color red #ed8796; +@define-color mauve #c6a0f6; +@define-color pink #f5bde6; +@define-color flamingo #f0c6c6; +@define-color rosewater #f4dbd6; diff --git a/user/modules/waybar/styles/notifications.css b/user/modules/waybar/styles/notifications.css new file mode 100644 index 0000000..1fc9e51 --- /dev/null +++ b/user/modules/waybar/styles/notifications.css @@ -0,0 +1,82 @@ +#notifications { + margin: 0.4em; + padding-left: 5px; + padding-right: 5px; + color: @peach; + font-weight: bold; + background-color: @surface0; + border: 2px solid @surface1; +} +#custom-notification, +#custom-updates, +#custom-github, +#idle_inhibitor, +#wireplumber, +#pulseaudio + { + padding: 0 0.5em; +} + +#custom-updates.updated { + padding-left: 0; + padding-right: 1em; +} + +/* Unique colors for modules */ + +#custom-pipewire { + color: @green; +} + +#custom-github { + color: @blue; +} + +#custom-updates { + color: @red; +} + +#custom-pipewire.muted, +#pulseaudio.muted { + background-color: #90b1b1; + color: #2a5c45; +} + +#keyboard-state { + padding: 0 0px; + min-width: 16px; + color: @mauve; +} + +#keyboard-state > label { + padding: 0 5px; +} + +#keyboard-state > label.locked { + background: rgba(0, 0, 0, 0.2); +} + +#pulseaudio-slider { + padding: 0 12px; +} + +#pulseaudio-slider slider { + min-height: 0px; + min-width: 0px; + opacity: 0; + background-image: none; + border: none; + box-shadow: none; +} +#pulseaudio-slider trough { + min-height: 10px; + min-width: 80px; + border-radius: 5px; + background-color: @base; +} +#pulseaudio-slider highlight { + min-width: 10px; + border-radius: 5px; + background-color: @green; +} + diff --git a/user/modules/waybar/styles/power.css b/user/modules/waybar/styles/power.css new file mode 100644 index 0000000..bcd483f --- /dev/null +++ b/user/modules/waybar/styles/power.css @@ -0,0 +1,14 @@ +/* Custom styling for the logout icon on end */ +#custom-wlogout { + font-size: 1.75em; + padding: 0 0.5em; + color: @blue; +} + +#power { + margin-right: 0.25em; +} + +#power .not-power { + color: @red; +} diff --git a/user/modules/waybar/styles/stats.css b/user/modules/waybar/styles/stats.css new file mode 100644 index 0000000..456ea66 --- /dev/null +++ b/user/modules/waybar/styles/stats.css @@ -0,0 +1,43 @@ +#stats, +#stats-drawer { + margin: 0.4em; + padding-left: 5px; + padding-right: 5px; + color: @peach; + font-weight: bold; + background-color: @surface0; + border: 2px solid @surface1; +} +#battery, +#cpu, +#memory, +#temperature, +#disk, +#network { + padding: 0 0.5em; +} + +/* Unique colors for modules */ +#cpu { + color: @red; +} + +#memory { + color: @yellow; +} +#temperature { + color: @green; +} + +#network { + color: @blue; +} + +#network.disconnected { + background-color: #f53c3c; +} + +#temperature.critical { + background-color: #eb4d4b; +} + diff --git a/user/modules/waybar/styles/style.css b/user/modules/waybar/styles/style.css new file mode 100644 index 0000000..fd8e1c9 --- /dev/null +++ b/user/modules/waybar/styles/style.css @@ -0,0 +1,77 @@ +/** +* Global configuration for theme +* */ +* { + font-family: FiraCode Nerd Font; + font-size: 16px; + border-radius: 0.75em; +} + +window#waybar { + border: 2px solid @surface1; + background: @theme_base_color; + box-shadow: 1px 1px 10px 10px @mantle; + color: @theme_text_color; + transition-property: background-color; + transition-duration: 0.5s; +} + +window#waybar.hidden { + opacity: 0.2; +} + +tooltip { + background: @base; + border: 1px solid @blue; +} + +tooltip label { + color: white; +} + +label:focus { + background-color: #000000; +} + +button { + /* Use box-shadow instead of border so the text isn't offset */ + box-shadow: inset 0 -3px transparent; + /* Avoid rounded borders under each button name */ + border: none; + border-radius: 0; +} + +/* Remove border from parent waybar */ +box { + border: none; +} + +/* Add spacing for right side modules */ +#tray, +#user, +#custom-weather, +#keyboard-state, +#mpd { + padding: 0 1em; +} + +#clock { + font-size: 16px; + font-weight: 900; + padding: 0 1em; +} + +#custom-separator-right, +#custom-separator-left { + font-size: 20px; + padding-left: 1em; + padding-right: 1em; + color: @text; +} + +@keyframes blink { + to { + background-color: #ffffff; + color: #000000; + } +} diff --git a/user/modules/waybar/styles/workspaces.css b/user/modules/waybar/styles/workspaces.css new file mode 100644 index 0000000..83372c2 --- /dev/null +++ b/user/modules/waybar/styles/workspaces.css @@ -0,0 +1,42 @@ +#workspaces { + margin: 0.4em; + padding-left: 5px; + padding-right: 5px; + color: @peach; + font-weight: bold; + background-color: @surface0; + border: 2px solid @surface1; +} + +#workspaces label { + font-family: MonaspiceNe Nerd Font; + font-size: 20px; +} + +#workspaces button { + padding: 0 0.5em; + background-color: @surface0; + color: @text; + margin: 0.2em; +} + +#workspaces button.empty { + /* background-color: @surface2; */ + color: @overlay0; +} + +#workspaces button.visible { + /* background-color: @surface2; */ + color: @blue; +} + +#workspaces button.active { + /* background-color: @surface2; */ + color: @green; +} + +#workspaces button.urgent { + box-shadow: 2px 2px 2px 2px; + border-radius: 1em; + color: @red; +} diff --git a/user/modules/wofi.nix b/user/modules/wofi.nix new file mode 100644 index 0000000..e96db9a --- /dev/null +++ b/user/modules/wofi.nix @@ -0,0 +1,5 @@ +{...}: { + programs.wofi = { + enable = true; + }; +} From 1d63ce26c95bcf5f0a6264197ed7e1b947347058 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Sat, 20 Jan 2024 16:53:38 -0500 Subject: [PATCH 27/77] fix(git_nixos): cache git credentials from oauth --- user/modules/git_nixos.nix | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/user/modules/git_nixos.nix b/user/modules/git_nixos.nix index 81d9dd7..20d2c7c 100644 --- a/user/modules/git_nixos.nix +++ b/user/modules/git_nixos.nix @@ -2,7 +2,11 @@ programs.git = { package = pkgs.gitAndTools.gitFull; extraConfig = { - credential.helper = "oauth"; + credential.helper = [ + # Cache credentials for 2 weeks + "cache --timeout 1209600" + "oauth" + ]; }; }; From 3d535ac1b4bd655574cdf23df272e89f0bc88678 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Sat, 20 Jan 2024 16:54:39 -0500 Subject: [PATCH 28/77] fix(common): remove gnome from common modules --- modules/common.nix | 1 - 1 file changed, 1 deletion(-) diff --git a/modules/common.nix b/modules/common.nix index 0d7a711..1ae9d8f 100644 --- a/modules/common.nix +++ b/modules/common.nix @@ -6,7 +6,6 @@ ./cups.nix ./flatpak.nix ./fonts.nix - ./gnome.nix ./nix.nix ./sound.nix ]; From 4fd3ac04dda3a1f3f0cc7b462179a7cca13bb0cf Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Sat, 20 Jan 2024 16:54:51 -0500 Subject: [PATCH 29/77] feat(foot): add module --- user/modules/foot.nix | 10 ++++++++++ 1 file changed, 10 insertions(+) create mode 100644 user/modules/foot.nix diff --git a/user/modules/foot.nix b/user/modules/foot.nix new file mode 100644 index 0000000..25d5697 --- /dev/null +++ b/user/modules/foot.nix @@ -0,0 +1,10 @@ +{...}: { + programs.foot = { + enable = true; + settings = { + main = { + font = "FiraCode Nerd Font:size=12"; + }; + }; + }; +} From 3ddd90e08a216d4d16413911b597acb8c18d251d Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Sat, 20 Jan 2024 16:56:56 -0500 Subject: [PATCH 30/77] chore: update lockfile --- flake.lock | 54 +++++++++++++++++++++++++++--------------------------- 1 file changed, 27 insertions(+), 27 deletions(-) diff --git a/flake.lock b/flake.lock index 7ecdfe0..a42c433 100644 --- a/flake.lock +++ b/flake.lock @@ -7,11 +7,11 @@ ] }, "locked": { - "lastModified": 1704277720, - "narHash": "sha256-meAKNgmh3goankLGWqqpw73pm9IvXjEENJloF0coskE=", + "lastModified": 1705452289, + "narHash": "sha256-i/WodLabBcmRr9hdSv5jzDigL1hRYuI8vNh+xTbGt+g=", "owner": "lnl7", "repo": "nix-darwin", - "rev": "0dd382b70c351f528561f71a0a7df82c9d2be9a4", + "rev": "74ab0227ee495e526f2dd57ea684b34f6396445a", "type": "github" }, "original": { @@ -132,11 +132,11 @@ ] }, "locked": { - "lastModified": 1704099619, - "narHash": "sha256-QRVMkdxLmv+aKGjcgeEg31xtJEIsYq4i1Kbyw5EPS6g=", + "lastModified": 1705659542, + "narHash": "sha256-WA3xVfAk1AYmFdwghT7mt/erYpsU6JPu9mdTEP/e9HQ=", "owner": "rycee", "repo": "home-manager", - "rev": "7e398b3d76bc1503171b1364c9d4a07ac06f3851", + "rev": "10cd9c53115061aa6a0a90aad0b0dde6a999cdb9", "type": "github" }, "original": { @@ -153,11 +153,11 @@ "nixpkgs": "nixpkgs" }, "locked": { - "lastModified": 1704763209, - "narHash": "sha256-n++yFjIO8ZxAYCRgfY+82H/2Ng5GQ9vK8N+iq9wqVCs=", + "lastModified": 1705713606, + "narHash": "sha256-8VYBrwOxaofT+GAxQ5Z1wYF22KHOPwTrfliDTuOrNEc=", "owner": "nix-community", "repo": "nix-vscode-extensions", - "rev": "c4177ec6600af2f26fe5a8fd14605240130f8e56", + "rev": "8430e52a88282c7295c409ba315f6e0967403f39", "type": "github" }, "original": { @@ -175,11 +175,11 @@ ] }, "locked": { - "lastModified": 1704677738, - "narHash": "sha256-3WYyt1QitK6+PNngv9QOn1GrxI42PXRDhC+FjAQBHP4=", + "lastModified": 1705359964, + "narHash": "sha256-ys1MDjIH6z5UP7gAciRfUAlf2FJV0t3yFib965N/S+I=", "owner": "nix-community", "repo": "NixOS-WSL", - "rev": "d8117453224ee4497573ed1b80f3bc62c68cf5be", + "rev": "bb3eeeb96ce059ae29309138874ccf58e796f4b1", "type": "github" }, "original": { @@ -206,11 +206,11 @@ }, "nixpkgs_2": { "locked": { - "lastModified": 1704420045, - "narHash": "sha256-C36QmoJd5tdQ5R9MC1jM7fBkZW9zBUqbUCsgwS6j4QU=", + "lastModified": 1705641746, + "narHash": "sha256-D6c2aH8HQbWc7ZWSV0BUpFpd94ImFyCP8jFIsKQ4Slg=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "c1be43e8e837b8dbee2b3665a007e761680f0c3d", + "rev": "d2003f2223cbb8cd95134e4a0541beea215c1073", "type": "github" }, "original": { @@ -237,11 +237,11 @@ }, "nur": { "locked": { - "lastModified": 1704818955, - "narHash": "sha256-andwUQj1sfSMYeZUJ5I++DzlSCK5IHD/U1ziD8cJt5g=", + "lastModified": 1705787139, + "narHash": "sha256-QoOovgqrTq8GdMfvp5AbhHhunhXbgsxmWwlpVGL2tgM=", "owner": "nix-community", "repo": "NUR", - "rev": "3db34f87f0972308898521c41a8bbcc4745066ea", + "rev": "26884905e6e16577275d60f3985861eec185afa4", "type": "github" }, "original": { @@ -270,11 +270,11 @@ "nixpkgs": "nixpkgs_3" }, "locked": { - "lastModified": 1704766659, - "narHash": "sha256-Q2wQ9jzp4j96HokmhUQey+pyZMp4Fye/ZPSLtBBV1J8=", + "lastModified": 1705716951, + "narHash": "sha256-Yp4EkRWoXX57a7hDyx6xJDTtl0h1WRFdRlp9SejPPOQ=", "owner": "oxalica", "repo": "rust-overlay", - "rev": "afa87241c19241aca9b7a9103635b82db2b147bb", + "rev": "612b6a974cb921fe7aa4cafd54f4f5f899b19173", "type": "github" }, "original": { @@ -360,11 +360,11 @@ }, "unstable": { "locked": { - "lastModified": 1704538339, - "narHash": "sha256-1734d3mQuux9ySvwf6axRWZRBhtcZA9Q8eftD6EZg6U=", + "lastModified": 1705677747, + "narHash": "sha256-eyM3okYtMgYDgmYukoUzrmuoY4xl4FUujnsv/P6I/zI=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "46ae0210ce163b3cba6c7da08840c1d63de9c701", + "rev": "bbe7d8f876fbbe7c959c90ba2ae2852220573261", "type": "github" }, "original": { @@ -378,11 +378,11 @@ "systems": "systems_4" }, "locked": { - "lastModified": 1701680307, - "narHash": "sha256-kAuep2h5ajznlPMD9rnQyffWG8EM/C73lejGofXvdM8=", + "lastModified": 1705309234, + "narHash": "sha256-uNRRNRKmJyCRC/8y1RqBkqWBLM034y4qN7EprSdmgyA=", "owner": "numtide", "repo": "flake-utils", - "rev": "4022d587cbbfd70fe950c1e2083a02621806a725", + "rev": "1ef2e671c3b0c19053962c07dbda38332dcebf26", "type": "github" }, "original": { From 474412991ed1a73677bc33df8d4dab0981a2d9d3 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Sat, 20 Jan 2024 16:59:03 -0500 Subject: [PATCH 31/77] chore(nvim): update lockfile --- user/modules/nvim/lazy-lock.json | 40 ++++++++++++++++---------------- 1 file changed, 20 insertions(+), 20 deletions(-) diff --git a/user/modules/nvim/lazy-lock.json b/user/modules/nvim/lazy-lock.json index 7a015db..f56e8e4 100644 --- a/user/modules/nvim/lazy-lock.json +++ b/user/modules/nvim/lazy-lock.json @@ -1,22 +1,22 @@ { "LazyVim": { "branch": "main", "commit": "879e29504d43e9f178d967ecc34d482f902e5a91" }, - "LuaSnip": { "branch": "master", "commit": "82108e7e31cc6fc223cc5df5cae6d89f70bb199f" }, + "LuaSnip": { "branch": "master", "commit": "2dbef19461198630b3d7c39f414d09fb07d1fdd2" }, "bufferline.nvim": { "branch": "main", "commit": "e48ce1805697e4bb97bc171c081e849a65859244" }, - "catppuccin": { "branch": "main", "commit": "5e36ca599f4aa41bdd87fbf2c5aae4397ac55074" }, + "catppuccin": { "branch": "main", "commit": "6853cc8e6efc76e85e10ec153d05fc2520653508" }, "cmp-buffer": { "branch": "main", "commit": "3022dbc9166796b644a841a02de8dd1cc1d311fa" }, "cmp-nvim-lsp": { "branch": "main", "commit": "5af77f54de1b16c34b23cba810150689a3a90312" }, "cmp-path": { "branch": "main", "commit": "91ff86cd9c29299a64f968ebb45846c485725f23" }, "cmp_luasnip": { "branch": "master", "commit": "05a9ab28b53f71d1aece421ef32fee2cb857a843" }, - "conform.nvim": { "branch": "master", "commit": "75e7c5c7eb5fbd53f8b12dc420b31ec70770b231" }, + "conform.nvim": { "branch": "master", "commit": "cbc5745bf7519acaf3a5cbaaa677fd556aa813d7" }, "dashboard-nvim": { "branch": "master", "commit": "63df28409d940f9cac0a925df09d3dc369db9841" }, - "dressing.nvim": { "branch": "master", "commit": "94b0d24483d56f3777ee0c8dc51675f21709318c" }, + "dressing.nvim": { "branch": "master", "commit": "c1179336aaeca82a785cade27e9b7b276af3222e" }, "flash.nvim": { "branch": "main", "commit": "48817af25f51c0590653bbc290866e4890fe1cbe" }, "friendly-snippets": { "branch": "main", "commit": "69a2c1675b66e002799f5eef803b87a12f593049" }, - "gitsigns.nvim": { "branch": "main", "commit": "4aaacbf5e5e2218fd05eb75703fe9e0f85335803" }, + "gitsigns.nvim": { "branch": "main", "commit": "c5ff7628e19a47ec14d3657294cc074ecae27b99" }, "indent-blankline.nvim": { "branch": "master", "commit": "12e92044d313c54c438bd786d11684c88f6f78cd" }, "lazy.nvim": { "branch": "main", "commit": "96584866b9c5e998cbae300594d0ccfd0c464627" }, "lualine.nvim": { "branch": "master", "commit": "566b7036f717f3d676362742630518a47f132fff" }, - "mason-lspconfig.nvim": { "branch": "main", "commit": "0989bdf4fdf7b5aa4c74131d7ffccc3f399ac788" }, + "mason-lspconfig.nvim": { "branch": "main", "commit": "3ba1b92b771f33256b4969d696b82c8ae7075364" }, "mason.nvim": { "branch": "main", "commit": "e110bc3be1a7309617cecd77bfe4bf86ba1b8134" }, "mini.ai": { "branch": "main", "commit": "f7787cff9cc42004f722ca1e64e6af4e64e34177" }, "mini.bufremove": { "branch": "main", "commit": "020243bfed8c8b941f2c20626faf3ea39c0c0e1b" }, @@ -24,29 +24,29 @@ "mini.indentscope": { "branch": "main", "commit": "5a8369475cd7cd6f207a4d288406d03b0fc48bdb" }, "mini.pairs": { "branch": "main", "commit": "552062017ff207e1f35f7028bfb3f27c7421d22d" }, "mini.surround": { "branch": "main", "commit": "7bf8915ba15d7a4f3c2afe7868d3c15a858d73f1" }, - "monokai-pro.nvim": { "branch": "master", "commit": "b49795aa8a0cb6596660dae31ac10a43eff2d33b" }, - "neo-tree.nvim": { "branch": "v3.x", "commit": "77d9f484b88fd380386b46ed9206e5374d69d9d8" }, - "neoconf.nvim": { "branch": "main", "commit": "64437787dba70fce50dad7bfbb97d184c5bc340f" }, - "neodev.nvim": { "branch": "main", "commit": "dde00106b9094f101980b364fae02fd85d357306" }, + "monokai-pro.nvim": { "branch": "master", "commit": "add6e9107eec368acde6caed0766256c5dae5005" }, + "neo-tree.nvim": { "branch": "v3.x", "commit": "2f2d08894bbc679d4d181604c16bb7079f646384" }, + "neoconf.nvim": { "branch": "main", "commit": "fe9e3a933a8c5f9feb5b0fd4cc451f4241d94263" }, + "neodev.nvim": { "branch": "main", "commit": "aaeb44589cab39c2545a328661af355622d68479" }, "noice.nvim": { "branch": "main", "commit": "92433164e2f7118d4122c7674c3834d9511722ba" }, "nui.nvim": { "branch": "main", "commit": "35da9ca1de0fc4dda96c2e214d93d363c145f418" }, "nvim-cmp": { "branch": "main", "commit": "538e37ba87284942c1d76ed38dd497e54e65b891" }, - "nvim-lint": { "branch": "master", "commit": "8df53b5dde8ea80f0a039775777eae6648a10229" }, - "nvim-lspconfig": { "branch": "master", "commit": "e47ccfae775f0d572ef0f3a7d245f043b259dafc" }, - "nvim-notify": { "branch": "master", "commit": "1576123bff3bed67bc673a3076e591abfe5d8ca9" }, + "nvim-lint": { "branch": "master", "commit": "2cf9ad095130755d7d87f1730bcf33c91ee822e4" }, + "nvim-lspconfig": { "branch": "master", "commit": "8917d2c830e04bf944a699b8c41f097621283828" }, + "nvim-notify": { "branch": "master", "commit": "80b67b265530632505193553d05127ae7fe09ddd" }, "nvim-spectre": { "branch": "master", "commit": "d8906855f1949ac97b1e77aaf8d3fe12ed158ddc" }, - "nvim-treesitter": { "branch": "master", "commit": "8cd2b230174efbf7b5d9f49fe2f90bda6b5eb16e" }, - "nvim-treesitter-context": { "branch": "master", "commit": "400a99ad43ac78af1148061da3491cba2637ad29" }, - "nvim-treesitter-textobjects": { "branch": "master", "commit": "85b9d0cbd4ff901abcda862b50dbb34e0901848b" }, + "nvim-treesitter": { "branch": "master", "commit": "5cc562748729b6dc9563ea5a3d676ff102ab38b1" }, + "nvim-treesitter-context": { "branch": "master", "commit": "85cf977181fb8e816e47ac05df7f756e9cb72caf" }, + "nvim-treesitter-textobjects": { "branch": "master", "commit": "19a91a38b02c1c28c14e0ba468d20ae1423c39b2" }, "nvim-ts-autotag": { "branch": "main", "commit": "8515e48a277a2f4947d91004d9aa92c29fdc5e18" }, "nvim-ts-context-commentstring": { "branch": "main", "commit": "1277b4a1f451b0f18c0790e1a7f12e1e5fdebfee" }, - "nvim-web-devicons": { "branch": "master", "commit": "db0c864375c198cacc171ff373e76bfce2a85045" }, - "persistence.nvim": { "branch": "main", "commit": "ad538bfd5336f1335cdb6fd4e0b0eebfa6e12f32" }, + "nvim-web-devicons": { "branch": "master", "commit": "140edfcf25093e8b321d13e154cbce89ee868ca0" }, + "persistence.nvim": { "branch": "main", "commit": "4982499c1636eac254b72923ab826ee7827b3084" }, "plenary.nvim": { "branch": "master", "commit": "55d9fe89e33efd26f532ef20223e5f9430c8b0c0" }, "telescope-fzf-native.nvim": { "branch": "main", "commit": "6c921ca12321edaa773e324ef64ea301a1d0da62" }, - "telescope.nvim": { "branch": "master", "commit": "da8b3d485975a8727bea127518b65c980521ae22" }, + "telescope.nvim": { "branch": "master", "commit": "24778fd72fcf39a0b1a6f7c6f4c4e01fef6359a2" }, "todo-comments.nvim": { "branch": "main", "commit": "4a6737a8d70fe1ac55c64dfa47fcb189ca431872" }, - "tokyonight.nvim": { "branch": "main", "commit": "f247ee700b569ed43f39320413a13ba9b0aef0db" }, + "tokyonight.nvim": { "branch": "main", "commit": "5c74eb7ab33f4e5bc62198a8296fddb60595898c" }, "trouble.nvim": { "branch": "main", "commit": "f1168feada93c0154ede4d1fe9183bf69bac54ea" }, "vim-illuminate": { "branch": "master", "commit": "3bd2ab64b5d63b29e05691e624927e5ebbf0fb86" }, "vim-startuptime": { "branch": "master", "commit": "454b3de856b7bd298700de33d79774ca9b9e3875" }, From 67ecabd538229cf58a6bdf06c59861891f4da5f7 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Mon, 22 Jan 2024 10:44:12 -0500 Subject: [PATCH 32/77] fix(mac): disable automatic store optimization due to https://github.com/NixOS/nix/issues/7273 --- machines/mac/configuration.nix | 1 - 1 file changed, 1 deletion(-) diff --git a/machines/mac/configuration.nix b/machines/mac/configuration.nix index 5ae9b07..b709d89 100644 --- a/machines/mac/configuration.nix +++ b/machines/mac/configuration.nix @@ -68,7 +68,6 @@ options = "--delete-older-than 7d"; }; extraOptions = '' - auto-optimise-store = true experimental-features = nix-command flakes ''; settings.auto-optimise-store = false; From 04768bb6c965a384893eed8cb6c7b66e54733294 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Mon, 22 Jan 2024 10:56:13 -0500 Subject: [PATCH 33/77] feat(zathura): add module --- user/environments/mac/home.nix | 2 ++ user/modules/applications/zathura.nix | 11 +++++++++++ 2 files changed, 13 insertions(+) create mode 100644 user/modules/applications/zathura.nix diff --git a/user/environments/mac/home.nix b/user/environments/mac/home.nix index 670efbd..ecf4df0 100644 --- a/user/environments/mac/home.nix +++ b/user/environments/mac/home.nix @@ -1,5 +1,7 @@ {pkgs, ...}: { imports = [ + ../../modules/applications/zathura.nix + ../../modules/zsh.nix ../../modules/dev.nix ../../modules/emacs.nix diff --git a/user/modules/applications/zathura.nix b/user/modules/applications/zathura.nix new file mode 100644 index 0000000..2da548a --- /dev/null +++ b/user/modules/applications/zathura.nix @@ -0,0 +1,11 @@ +{...}: { + programs.zathura = { + enable = true; + options = { + scroll-page-aware = true; + smooth-scroll = true; + scroll-full-overlap = "0.01"; + scroll-step = 100; + }; + }; +} From e6aaf1627cb4de7c0aa5f95125a728e476d917b6 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Mon, 22 Jan 2024 11:11:10 -0500 Subject: [PATCH 34/77] feat(nvim): support javascript/typescript LSP, lint, and formatting --- user/modules/nvim.nix | 2 ++ user/modules/nvim/lua/plugins/lsp.lua | 8 ++++++++ 2 files changed, 10 insertions(+) diff --git a/user/modules/nvim.nix b/user/modules/nvim.nix index 522417e..28678a1 100644 --- a/user/modules/nvim.nix +++ b/user/modules/nvim.nix @@ -20,5 +20,7 @@ ripgrep gnumake gcc + eslint_d + prettierd ]; } diff --git a/user/modules/nvim/lua/plugins/lsp.lua b/user/modules/nvim/lua/plugins/lsp.lua index 6fd65ce..0431c10 100644 --- a/user/modules/nvim/lua/plugins/lsp.lua +++ b/user/modules/nvim/lua/plugins/lsp.lua @@ -6,6 +6,10 @@ return { ---@type lspconfig.options ---@diagnostic disable-next-line: missing-fields servers = { + ---@diagnostic disable-next-line: missing-fields + tsserver = {}, + ---@diagnostic disable-next-line: missing-fields + eslint = {}, nil_ls = {}, }, }, @@ -49,6 +53,10 @@ return { ---@type table formatters_by_ft = { nix = { "alejandra" }, + javascript = { { "prettierd", "prettier" } }, + javascriptreact = { { "prettierd", "prettier" } }, + typescript = { { "prettierd", "prettier" } }, + typescriptreact = { { "prettierd", "prettier" } }, }, }, }, From aec9bb14959525e99c3625e65f1d9c20eb195cbf Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Tue, 30 Jan 2024 20:54:15 -0500 Subject: [PATCH 35/77] chore: update lockfile --- flake.lock | 60 +++++++++++++++++++++++++++--------------------------- 1 file changed, 30 insertions(+), 30 deletions(-) diff --git a/flake.lock b/flake.lock index a42c433..b16a4d9 100644 --- a/flake.lock +++ b/flake.lock @@ -7,11 +7,11 @@ ] }, "locked": { - "lastModified": 1705452289, - "narHash": "sha256-i/WodLabBcmRr9hdSv5jzDigL1hRYuI8vNh+xTbGt+g=", + "lastModified": 1706581965, + "narHash": "sha256-1H7dRdK9LJ7+2X1XQtbwXr+QMqtVVo/ZF0/LIvkjdK8=", "owner": "lnl7", "repo": "nix-darwin", - "rev": "74ab0227ee495e526f2dd57ea684b34f6396445a", + "rev": "91b9daf672c957ef95a05491a75f62e6a01d5aaf", "type": "github" }, "original": { @@ -76,11 +76,11 @@ "systems": "systems_2" }, "locked": { - "lastModified": 1701680307, - "narHash": "sha256-kAuep2h5ajznlPMD9rnQyffWG8EM/C73lejGofXvdM8=", + "lastModified": 1705309234, + "narHash": "sha256-uNRRNRKmJyCRC/8y1RqBkqWBLM034y4qN7EprSdmgyA=", "owner": "numtide", "repo": "flake-utils", - "rev": "4022d587cbbfd70fe950c1e2083a02621806a725", + "rev": "1ef2e671c3b0c19053962c07dbda38332dcebf26", "type": "github" }, "original": { @@ -94,11 +94,11 @@ "systems": "systems_3" }, "locked": { - "lastModified": 1681202837, - "narHash": "sha256-H+Rh19JDwRtpVPAWp64F+rlEtxUWBAQW28eAi3SRSzg=", + "lastModified": 1705309234, + "narHash": "sha256-uNRRNRKmJyCRC/8y1RqBkqWBLM034y4qN7EprSdmgyA=", "owner": "numtide", "repo": "flake-utils", - "rev": "cfacdce06f30d2b68473a46042957675eebb3401", + "rev": "1ef2e671c3b0c19053962c07dbda38332dcebf26", "type": "github" }, "original": { @@ -153,11 +153,11 @@ "nixpkgs": "nixpkgs" }, "locked": { - "lastModified": 1705713606, - "narHash": "sha256-8VYBrwOxaofT+GAxQ5Z1wYF22KHOPwTrfliDTuOrNEc=", + "lastModified": 1706663720, + "narHash": "sha256-nPstfigc9FdWIwbtZcwfAjEP5fsI171CDMQ7rJdg0ok=", "owner": "nix-community", "repo": "nix-vscode-extensions", - "rev": "8430e52a88282c7295c409ba315f6e0967403f39", + "rev": "129d9ddaf92f8a0942037aebf99dfa09d31e0dde", "type": "github" }, "original": { @@ -175,11 +175,11 @@ ] }, "locked": { - "lastModified": 1705359964, - "narHash": "sha256-ys1MDjIH6z5UP7gAciRfUAlf2FJV0t3yFib965N/S+I=", + "lastModified": 1706608109, + "narHash": "sha256-Yc7pmonKJX/dOFm+qEInE+JlskMiN9OmOwUd/EKp4a0=", "owner": "nix-community", "repo": "NixOS-WSL", - "rev": "bb3eeeb96ce059ae29309138874ccf58e796f4b1", + "rev": "0b52d9e7a6c779f8b88c6e3bdfe6064fad648dcf", "type": "github" }, "original": { @@ -206,11 +206,11 @@ }, "nixpkgs_2": { "locked": { - "lastModified": 1705641746, - "narHash": "sha256-D6c2aH8HQbWc7ZWSV0BUpFpd94ImFyCP8jFIsKQ4Slg=", + "lastModified": 1706515015, + "narHash": "sha256-eFfY5A7wlYy3jD/75lx6IJRueg4noE+jowl0a8lIlVo=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "d2003f2223cbb8cd95134e4a0541beea215c1073", + "rev": "f4a8d6d5324c327dcc2d863eb7f3cc06ad630df4", "type": "github" }, "original": { @@ -221,11 +221,11 @@ }, "nixpkgs_3": { "locked": { - "lastModified": 1681358109, - "narHash": "sha256-eKyxW4OohHQx9Urxi7TQlFBTDWII+F+x2hklDOQPB50=", + "lastModified": 1706487304, + "narHash": "sha256-LE8lVX28MV2jWJsidW13D2qrHU/RUUONendL2Q/WlJg=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "96ba1c52e54e74c3197f4d43026b3f3d92e83ff9", + "rev": "90f456026d284c22b3e3497be980b2e47d0b28ac", "type": "github" }, "original": { @@ -237,11 +237,11 @@ }, "nur": { "locked": { - "lastModified": 1705787139, - "narHash": "sha256-QoOovgqrTq8GdMfvp5AbhHhunhXbgsxmWwlpVGL2tgM=", + "lastModified": 1706665018, + "narHash": "sha256-NtvxIQhRxavrL7PQ1ZURqWr15XM1Dc98yv4U5gTbJhk=", "owner": "nix-community", "repo": "NUR", - "rev": "26884905e6e16577275d60f3985861eec185afa4", + "rev": "98930fb5cf79e652111ed531e6ce777618b1c898", "type": "github" }, "original": { @@ -270,11 +270,11 @@ "nixpkgs": "nixpkgs_3" }, "locked": { - "lastModified": 1705716951, - "narHash": "sha256-Yp4EkRWoXX57a7hDyx6xJDTtl0h1WRFdRlp9SejPPOQ=", + "lastModified": 1706634984, + "narHash": "sha256-xn7lGPE8gRGBe3Lt8ESoN/uUHm7IrbiV7siupwjHX1o=", "owner": "oxalica", "repo": "rust-overlay", - "rev": "612b6a974cb921fe7aa4cafd54f4f5f899b19173", + "rev": "883b84c426107a8ec020e7124f263d7c35a5bb9f", "type": "github" }, "original": { @@ -360,11 +360,11 @@ }, "unstable": { "locked": { - "lastModified": 1705677747, - "narHash": "sha256-eyM3okYtMgYDgmYukoUzrmuoY4xl4FUujnsv/P6I/zI=", + "lastModified": 1706371002, + "narHash": "sha256-dwuorKimqSYgyu8Cw6ncKhyQjUDOyuXoxDTVmAXq88s=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "bbe7d8f876fbbe7c959c90ba2ae2852220573261", + "rev": "c002c6aa977ad22c60398daaa9be52f2203d0006", "type": "github" }, "original": { From f0c01667dfb1ec81204a043a4af94777c732c46d Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Tue, 30 Jan 2024 20:54:24 -0500 Subject: [PATCH 36/77] feat(latex): add packages --- user/modules/latex.nix | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/user/modules/latex.nix b/user/modules/latex.nix index a8b8d57..8a00698 100644 --- a/user/modules/latex.nix +++ b/user/modules/latex.nix @@ -1,5 +1,12 @@ {pkgs, ...}: { - home.packages = [ - pkgs.texlive.combined.scheme-medium - ]; + programs.texlive = { + enable = true; + extraPackages = tpkgs: { + inherit + (tpkgs) + scheme-medium + csquotes + ; + }; + }; } From 5bd8bdef97b4ebbc375021719fd99914264e3f6f Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Tue, 30 Jan 2024 21:11:02 -0500 Subject: [PATCH 37/77] fix(zathura): remove deprecated option --- user/modules/applications/zathura.nix | 1 - 1 file changed, 1 deletion(-) diff --git a/user/modules/applications/zathura.nix b/user/modules/applications/zathura.nix index 2da548a..94c52ac 100644 --- a/user/modules/applications/zathura.nix +++ b/user/modules/applications/zathura.nix @@ -3,7 +3,6 @@ enable = true; options = { scroll-page-aware = true; - smooth-scroll = true; scroll-full-overlap = "0.01"; scroll-step = 100; }; From ad1bbc9f18a93324dbbb770406a4febd081beeaf Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Mon, 26 Feb 2024 16:44:03 -0500 Subject: [PATCH 38/77] feat: move from zathura to sioyek --- user/environments/mac/home.nix | 2 +- user/modules/applications/sioyek.nix | 5 +++++ user/modules/applications/zathura.nix | 10 ---------- 3 files changed, 6 insertions(+), 11 deletions(-) create mode 100644 user/modules/applications/sioyek.nix delete mode 100644 user/modules/applications/zathura.nix diff --git a/user/environments/mac/home.nix b/user/environments/mac/home.nix index ecf4df0..39d8688 100644 --- a/user/environments/mac/home.nix +++ b/user/environments/mac/home.nix @@ -1,6 +1,6 @@ {pkgs, ...}: { imports = [ - ../../modules/applications/zathura.nix + ../../modules/applications/sioyek.nix ../../modules/zsh.nix ../../modules/dev.nix diff --git a/user/modules/applications/sioyek.nix b/user/modules/applications/sioyek.nix new file mode 100644 index 0000000..e8f5e04 --- /dev/null +++ b/user/modules/applications/sioyek.nix @@ -0,0 +1,5 @@ +{...}: { + programs.sioyek = { + enable = true; + }; +} diff --git a/user/modules/applications/zathura.nix b/user/modules/applications/zathura.nix deleted file mode 100644 index 94c52ac..0000000 --- a/user/modules/applications/zathura.nix +++ /dev/null @@ -1,10 +0,0 @@ -{...}: { - programs.zathura = { - enable = true; - options = { - scroll-page-aware = true; - scroll-full-overlap = "0.01"; - scroll-step = 100; - }; - }; -} From 98b6fd715f6966f8e22c7bb5ba1806de7d8361a2 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Tue, 27 Feb 2024 12:18:34 -0500 Subject: [PATCH 39/77] feat(yabai): add keyboard shortcuts --- modules/yabai.nix | 51 +++++++++++++++++++++++++++++++---------------- 1 file changed, 34 insertions(+), 17 deletions(-) diff --git a/modules/yabai.nix b/modules/yabai.nix index bc4b6d2..c19a320 100644 --- a/modules/yabai.nix +++ b/modules/yabai.nix @@ -34,25 +34,42 @@ services.skhd = { enable = true; skhdConfig = '' - alt - h: yabai -m window --focus west - alt - j: yabai -m window --focus south - alt - k: yabai -m window --focus north - alt - l: yabai -m window --focus east + ctrl + alt - h: yabai -m window --focus west + ctrl + alt - j: yabai -m window --focus south + ctrl + alt - k: yabai -m window --focus north + ctrl + alt - l: yabai -m window --focus east - shift + alt - h : yabai -m window --warp east - shift + alt - j : yabai -m window --warp north - shift + alt - k : yabai -m window --warp south - shift + alt - l : yabai -m window --warp west + cmd + ctrl + alt - h : yabai -m window --warp west + cmd + ctrl + alt - j : yabai -m window --warp south + cmd + ctrl + alt - k : yabai -m window --warp north + cmd + ctrl + alt - l : yabai -m window --warp east + + ctrl + alt - 1 : yabai -m space --focus 1 + ctrl + alt - 2 : yabai -m space --focus 2 + ctrl + alt - 3 : yabai -m space --focus 3 + ctrl + alt - 4 : yabai -m space --focus 4 + ctrl + alt - 5 : yabai -m space --focus 5 + ctrl + alt - 6 : yabai -m space --focus 6 + ctrl + alt - 7 : yabai -m space --focus 7 + ctrl + alt - 8 : yabai -m space --focus 8 + ctrl + alt - 9 : yabai -m space --focus 9 + + ctrl + alt - q: yabai -m window --close + + # 0x21 - [ + # 0x1E - ] + ctrl + alt - 0x21 : yabai -m query --spaces --space \ + | jq -re ".index" \ + | xargs -I{} yabai -m query --windows --space {} \ + | jq -sre "add | map(select(.minimized != 1)) | sort_by(.display, .frame.y, .frame.y, .id) | nth(index(map(select(.focused == 1))) - 1).id" \ + | xargs -I{} yabai -m window --focus {} + + ctrl + alt - 0x1E : yabai -m query --spaces --space \ + | jq -re ".index" \ + | xargs -I{} yabai -m query --windows --space {} \ + | jq -sre "add | map(select(.minimized != 1)) | sort_by(.display, .frame.y, .frame.x, .id) | reverse | nth(index(map(select(.focused == 1))) - 1).id" \ + | xargs -I{} yabai -m window --focus {} - cmd + alt - 1 : yabai -m space --focus 1 - cmd + alt - 2 : yabai -m space --focus 2 - cmd + alt - 3 : yabai -m space --focus 3 - cmd + alt - 4 : yabai -m space --focus 4 - cmd + alt - 5 : yabai -m space --focus 5 - cmd + alt - 6 : yabai -m space --focus 6 - cmd + alt - 7 : yabai -m space --focus 7 - cmd + alt - 8 : yabai -m space --focus 8 - cmd + alt - 9 : yabai -m space --focus 9 ''; }; } From e6d08e26c5f8083907a66841c0983a88cc0f2288 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Tue, 27 Feb 2024 12:18:56 -0500 Subject: [PATCH 40/77] feat(nvim): add asm tree-sitter grammar --- user/modules/nvim/lazy-lock.json | 41 ++++++++++++++------------- user/modules/nvim/lua/plugins/lsp.lua | 3 ++ 2 files changed, 24 insertions(+), 20 deletions(-) diff --git a/user/modules/nvim/lazy-lock.json b/user/modules/nvim/lazy-lock.json index f56e8e4..13b1121 100644 --- a/user/modules/nvim/lazy-lock.json +++ b/user/modules/nvim/lazy-lock.json @@ -1,22 +1,22 @@ { "LazyVim": { "branch": "main", "commit": "879e29504d43e9f178d967ecc34d482f902e5a91" }, - "LuaSnip": { "branch": "master", "commit": "2dbef19461198630b3d7c39f414d09fb07d1fdd2" }, + "LuaSnip": { "branch": "master", "commit": "82108e7e31cc6fc223cc5df5cae6d89f70bb199f" }, "bufferline.nvim": { "branch": "main", "commit": "e48ce1805697e4bb97bc171c081e849a65859244" }, - "catppuccin": { "branch": "main", "commit": "6853cc8e6efc76e85e10ec153d05fc2520653508" }, + "catppuccin": { "branch": "main", "commit": "5e36ca599f4aa41bdd87fbf2c5aae4397ac55074" }, "cmp-buffer": { "branch": "main", "commit": "3022dbc9166796b644a841a02de8dd1cc1d311fa" }, "cmp-nvim-lsp": { "branch": "main", "commit": "5af77f54de1b16c34b23cba810150689a3a90312" }, "cmp-path": { "branch": "main", "commit": "91ff86cd9c29299a64f968ebb45846c485725f23" }, "cmp_luasnip": { "branch": "master", "commit": "05a9ab28b53f71d1aece421ef32fee2cb857a843" }, - "conform.nvim": { "branch": "master", "commit": "cbc5745bf7519acaf3a5cbaaa677fd556aa813d7" }, + "conform.nvim": { "branch": "master", "commit": "75e7c5c7eb5fbd53f8b12dc420b31ec70770b231" }, "dashboard-nvim": { "branch": "master", "commit": "63df28409d940f9cac0a925df09d3dc369db9841" }, - "dressing.nvim": { "branch": "master", "commit": "c1179336aaeca82a785cade27e9b7b276af3222e" }, + "dressing.nvim": { "branch": "master", "commit": "94b0d24483d56f3777ee0c8dc51675f21709318c" }, "flash.nvim": { "branch": "main", "commit": "48817af25f51c0590653bbc290866e4890fe1cbe" }, "friendly-snippets": { "branch": "main", "commit": "69a2c1675b66e002799f5eef803b87a12f593049" }, - "gitsigns.nvim": { "branch": "main", "commit": "c5ff7628e19a47ec14d3657294cc074ecae27b99" }, + "gitsigns.nvim": { "branch": "main", "commit": "4aaacbf5e5e2218fd05eb75703fe9e0f85335803" }, "indent-blankline.nvim": { "branch": "master", "commit": "12e92044d313c54c438bd786d11684c88f6f78cd" }, "lazy.nvim": { "branch": "main", "commit": "96584866b9c5e998cbae300594d0ccfd0c464627" }, "lualine.nvim": { "branch": "master", "commit": "566b7036f717f3d676362742630518a47f132fff" }, - "mason-lspconfig.nvim": { "branch": "main", "commit": "3ba1b92b771f33256b4969d696b82c8ae7075364" }, + "mason-lspconfig.nvim": { "branch": "main", "commit": "0989bdf4fdf7b5aa4c74131d7ffccc3f399ac788" }, "mason.nvim": { "branch": "main", "commit": "e110bc3be1a7309617cecd77bfe4bf86ba1b8134" }, "mini.ai": { "branch": "main", "commit": "f7787cff9cc42004f722ca1e64e6af4e64e34177" }, "mini.bufremove": { "branch": "main", "commit": "020243bfed8c8b941f2c20626faf3ea39c0c0e1b" }, @@ -24,29 +24,30 @@ "mini.indentscope": { "branch": "main", "commit": "5a8369475cd7cd6f207a4d288406d03b0fc48bdb" }, "mini.pairs": { "branch": "main", "commit": "552062017ff207e1f35f7028bfb3f27c7421d22d" }, "mini.surround": { "branch": "main", "commit": "7bf8915ba15d7a4f3c2afe7868d3c15a858d73f1" }, - "monokai-pro.nvim": { "branch": "master", "commit": "add6e9107eec368acde6caed0766256c5dae5005" }, - "neo-tree.nvim": { "branch": "v3.x", "commit": "2f2d08894bbc679d4d181604c16bb7079f646384" }, - "neoconf.nvim": { "branch": "main", "commit": "fe9e3a933a8c5f9feb5b0fd4cc451f4241d94263" }, - "neodev.nvim": { "branch": "main", "commit": "aaeb44589cab39c2545a328661af355622d68479" }, + "monokai-pro.nvim": { "branch": "master", "commit": "b49795aa8a0cb6596660dae31ac10a43eff2d33b" }, + "neo-tree.nvim": { "branch": "v3.x", "commit": "77d9f484b88fd380386b46ed9206e5374d69d9d8" }, + "neoconf.nvim": { "branch": "main", "commit": "64437787dba70fce50dad7bfbb97d184c5bc340f" }, + "neodev.nvim": { "branch": "main", "commit": "dde00106b9094f101980b364fae02fd85d357306" }, "noice.nvim": { "branch": "main", "commit": "92433164e2f7118d4122c7674c3834d9511722ba" }, "nui.nvim": { "branch": "main", "commit": "35da9ca1de0fc4dda96c2e214d93d363c145f418" }, "nvim-cmp": { "branch": "main", "commit": "538e37ba87284942c1d76ed38dd497e54e65b891" }, - "nvim-lint": { "branch": "master", "commit": "2cf9ad095130755d7d87f1730bcf33c91ee822e4" }, - "nvim-lspconfig": { "branch": "master", "commit": "8917d2c830e04bf944a699b8c41f097621283828" }, - "nvim-notify": { "branch": "master", "commit": "80b67b265530632505193553d05127ae7fe09ddd" }, + "nvim-lint": { "branch": "master", "commit": "8df53b5dde8ea80f0a039775777eae6648a10229" }, + "nvim-lspconfig": { "branch": "master", "commit": "e47ccfae775f0d572ef0f3a7d245f043b259dafc" }, + "nvim-notify": { "branch": "master", "commit": "1576123bff3bed67bc673a3076e591abfe5d8ca9" }, "nvim-spectre": { "branch": "master", "commit": "d8906855f1949ac97b1e77aaf8d3fe12ed158ddc" }, - "nvim-treesitter": { "branch": "master", "commit": "5cc562748729b6dc9563ea5a3d676ff102ab38b1" }, - "nvim-treesitter-context": { "branch": "master", "commit": "85cf977181fb8e816e47ac05df7f756e9cb72caf" }, - "nvim-treesitter-textobjects": { "branch": "master", "commit": "19a91a38b02c1c28c14e0ba468d20ae1423c39b2" }, + "nvim-treesitter": { "branch": "master", "commit": "8cd2b230174efbf7b5d9f49fe2f90bda6b5eb16e" }, + "nvim-treesitter-context": { "branch": "master", "commit": "400a99ad43ac78af1148061da3491cba2637ad29" }, + "nvim-treesitter-textobjects": { "branch": "master", "commit": "85b9d0cbd4ff901abcda862b50dbb34e0901848b" }, "nvim-ts-autotag": { "branch": "main", "commit": "8515e48a277a2f4947d91004d9aa92c29fdc5e18" }, "nvim-ts-context-commentstring": { "branch": "main", "commit": "1277b4a1f451b0f18c0790e1a7f12e1e5fdebfee" }, - "nvim-web-devicons": { "branch": "master", "commit": "140edfcf25093e8b321d13e154cbce89ee868ca0" }, - "persistence.nvim": { "branch": "main", "commit": "4982499c1636eac254b72923ab826ee7827b3084" }, + "nvim-web-devicons": { "branch": "master", "commit": "db0c864375c198cacc171ff373e76bfce2a85045" }, + "persistence.nvim": { "branch": "main", "commit": "ad538bfd5336f1335cdb6fd4e0b0eebfa6e12f32" }, "plenary.nvim": { "branch": "master", "commit": "55d9fe89e33efd26f532ef20223e5f9430c8b0c0" }, "telescope-fzf-native.nvim": { "branch": "main", "commit": "6c921ca12321edaa773e324ef64ea301a1d0da62" }, - "telescope.nvim": { "branch": "master", "commit": "24778fd72fcf39a0b1a6f7c6f4c4e01fef6359a2" }, + "telescope.nvim": { "branch": "master", "commit": "da8b3d485975a8727bea127518b65c980521ae22" }, "todo-comments.nvim": { "branch": "main", "commit": "4a6737a8d70fe1ac55c64dfa47fcb189ca431872" }, - "tokyonight.nvim": { "branch": "main", "commit": "5c74eb7ab33f4e5bc62198a8296fddb60595898c" }, + "tokyonight.nvim": { "branch": "main", "commit": "f247ee700b569ed43f39320413a13ba9b0aef0db" }, + "tree-sitter-asm": { "branch": "main", "commit": "6ace266be7ad6bf486a95427ca3fc949aff66211" }, "trouble.nvim": { "branch": "main", "commit": "f1168feada93c0154ede4d1fe9183bf69bac54ea" }, "vim-illuminate": { "branch": "master", "commit": "3bd2ab64b5d63b29e05691e624927e5ebbf0fb86" }, "vim-startuptime": { "branch": "master", "commit": "454b3de856b7bd298700de33d79774ca9b9e3875" }, diff --git a/user/modules/nvim/lua/plugins/lsp.lua b/user/modules/nvim/lua/plugins/lsp.lua index 0431c10..1a581a9 100644 --- a/user/modules/nvim/lua/plugins/lsp.lua +++ b/user/modules/nvim/lua/plugins/lsp.lua @@ -60,4 +60,7 @@ return { }, }, }, + { + "rush-rs/tree-sitter-asm", + }, } From 3f3c4393f831dee6662eb0b24c46024333fd7ced Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Tue, 27 Feb 2024 12:19:22 -0500 Subject: [PATCH 41/77] feat(mac): add git-credential-oauth --- user/environments/mac/home.nix | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/user/environments/mac/home.nix b/user/environments/mac/home.nix index 39d8688..bc21383 100644 --- a/user/environments/mac/home.nix +++ b/user/environments/mac/home.nix @@ -15,6 +15,7 @@ home.packages = with pkgs; [ bitwarden-cli firebird-emu + git-credential-oauth ]; programs.zsh = { @@ -37,7 +38,10 @@ }; }; - programs.git.extraConfig.credential.helper = "osxkeychain"; + programs.git.extraConfig.credential.helper = [ + "osxkeychain" + "oauth" + ]; # Let Home Manager install and manage itself. programs.home-manager.enable = true; From c55f2cab4821de777c8c439d137293483538865b Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Tue, 27 Feb 2024 12:19:54 -0500 Subject: [PATCH 42/77] fix(dev): add rust packages --- user/modules/dev.nix | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/user/modules/dev.nix b/user/modules/dev.nix index 1ba51b5..1f57569 100644 --- a/user/modules/dev.nix +++ b/user/modules/dev.nix @@ -21,8 +21,10 @@ alejandra # Rust (rust-bin.stable.latest.default.override { - extensions = ["rust-src"]; + extensions = ["rust-src" "llvm-tools-preview"]; }) + pkg-config + openssl ]; programs.zsh.initExtra = '' From 3c2886faa9e0373e1f2e1d4cae4292fbc6bd22c4 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Tue, 27 Feb 2024 12:20:18 -0500 Subject: [PATCH 43/77] feat(vscode): add rust-analyzer --- user/modules/vscode.nix | 3 +++ 1 file changed, 3 insertions(+) diff --git a/user/modules/vscode.nix b/user/modules/vscode.nix index 13660df..c0455d9 100644 --- a/user/modules/vscode.nix +++ b/user/modules/vscode.nix @@ -76,6 +76,9 @@ in { # Nix jnoortheen.nix-ide kamadorueda.alejandra + + # Rust + rust-lang.rust-analyzer ]; }; }; From bc6f7f81016a45497e6c1160c0f900b00315419e Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Tue, 27 Feb 2024 12:20:36 -0500 Subject: [PATCH 44/77] feat(dev): add zoxide --- user/modules/dev.nix | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/user/modules/dev.nix b/user/modules/dev.nix index 1f57569..f994240 100644 --- a/user/modules/dev.nix +++ b/user/modules/dev.nix @@ -41,6 +41,10 @@ package = pkgs.jdk17; }; + programs.zoxide = { + enable = true; + }; + # Bun Git config programs.git = { attributes = [ From 6db28375b806b0cae98cb9a0ec54017021c46b38 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Wed, 10 Apr 2024 20:00:29 -0400 Subject: [PATCH 45/77] fix(hyprland): enable gvfs for nautilus --- modules/hyprland.nix | 3 +++ 1 file changed, 3 insertions(+) diff --git a/modules/hyprland.nix b/modules/hyprland.nix index 38a8f27..8affcd3 100644 --- a/modules/hyprland.nix +++ b/modules/hyprland.nix @@ -28,6 +28,9 @@ gnome.gnome-system-monitor ]; + # Required for Nautilus to work outside GNOME + services.gvfs.enable = true; + services.greetd = { enable = true; settings = { From d5adb7f0b161d684939fa3dfa95f67e4e025c0e3 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Thu, 11 Apr 2024 21:50:14 +0000 Subject: [PATCH 46/77] feat: add oracle machine --- flake.nix | 15 ++++++ machines/oracle/configuration.nix | 58 ++++++++++++++++++++++ machines/oracle/hardware-configuration.nix | 14 ++++++ user/environments/nixos-server/config.nix | 3 ++ user/environments/nixos-server/home.nix | 12 +++++ 5 files changed, 102 insertions(+) create mode 100644 machines/oracle/configuration.nix create mode 100644 machines/oracle/hardware-configuration.nix create mode 100644 user/environments/nixos-server/config.nix create mode 100644 user/environments/nixos-server/home.nix diff --git a/flake.nix b/flake.nix index f4f440f..75ecfa6 100644 --- a/flake.nix +++ b/flake.nix @@ -117,6 +117,21 @@ specialArgs = {inherit inputs;}; }; + oracle = nixpkgs.lib.nixosSystem { + system = utils.lib.system.x86_64-linux; + modules = [ + home-manager.nixosModules.home-manager + { + home-manager.useGlobalPkgs = true; + home-manager.useUserPackages = true; + home-manager.users.michael = import ./user/environments/nixos-server/home.nix; + } + + ./machines/oracle/configuration.nix + ]; + specialArgs = {inherit inputs;}; + }; + # WSL environment work = inputs.nixpkgs.lib.nixosSystem { system = utils.lib.system.x86_64-linux; diff --git a/machines/oracle/configuration.nix b/machines/oracle/configuration.nix new file mode 100644 index 0000000..a01056a --- /dev/null +++ b/machines/oracle/configuration.nix @@ -0,0 +1,58 @@ +{ pkgs, config, ... }: { + imports = [ + ./hardware-configuration.nix + ]; + + boot.tmp.cleanOnBoot = true; + zramSwap.enable = true; + + networking.hostName = "gringottsstatus"; + networking.domain = "subnet08161027.vcn08161027.oraclevcn.com"; + networking.firewall.enable = true; + + services.openssh.enable = true; + services.openssh.settings = { + PasswordAuthentication = false; + }; + + programs.zsh.enable = true; + + users.users.michael = { + isNormalUser = true; + home = "/home/michael"; + description = "Michael Thomas"; + extraGroups = [ "wheel" "networkmanager" ]; + shell = pkgs.zsh; + openssh.authorizedKeys.keys = [ + ''ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQDUYHiTel+RDzygCeNwV25cnBBNioM19EQWqxPC+xq7lNlNcAQ4wi9JIOONVGkshxPXzKZyR3F53Igs9JZr1E9088L52eUp35JhW1pthai82cw1jGkj9wxcKJnU6b7QNDKA+ejPTC/ciFFKytMyPgID0ICzBRQsnj15i4lGvGDgfTQ7qfI2J855H7S7qOpY7cbsGfeoz3f8Ye1FspJFDsNu9QhX05iunBcbni0uLoTtgS5cEBRr7H9RkKR7GCfd4Ae/sp+aeDkLU4aBkEi+A8VLfR74Juia1j/3mAAmkgJKGcBCKUv0ixBGd6XclZmkF8f2Hx0z8mDxJ7U8lsDUSKdvxK7fecsM4F/GTvjrUxV1nLD4SRQ06GtBmGQGDzIn3Nm1URd6gGT9W3486XJsqmGzjuHa5o4WhmBgh/Gs8xUcv7kWD5enrYacBr+HKVJWnnLFp+XfAYaMCT6j/4jc4D9/9hijRbhboICTDxWCWtFgz7QpsO6BQpi/wkR4Ql61vPc= michael@neptune'' + + ''ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDQr9lluvuGk3qU1bE7HrrZcE36x5hhD5Dat+E4My55aoh+Df/JeuWMPvzS4zLKMsIIZCUX6kbjvTtvWe7gPLflhDOUGI947MK9B01pojDn0LBugz57Ai9fPlG5+AlMWaxWitmP8JB637oxBpqesqxHdiEKW25u9t2qOvjX3kCdcoSYDlW72Xm8ZI9+qKcAlGLnFhiQxM18rjHcZYdn9ZyWRRSC1ocuTqnbh5lsYoMhD+4QWo5LmwMVjr5uix0i+ktqKzENaiDgA/MQIWQrHqUavfjvMRyyQO7bScVTe/PllKFpLOBym2SLC5hD7vG69BBo0dQUto8tAbIgI9Tmv1dx michael@venus'' + ]; + }; + + swapDevices = [ + { + device = "/var/lib/swapfile"; + size = 4*1024; + } + ]; + + # Services + services.caddy = { + enable = true; + }; + networking.firewall.allowedTCPPorts = [ 80 443 ]; + + services.uptime-kuma = { + enable = true; + settings = { + port = "3001"; + }; + }; + + services.caddy.virtualHosts."status.gringotts.michaelt.xyz".extraConfig = '' + reverse_proxy http://localhost:${config.services.uptime-kuma.settings.PORT} + ''; + + system.stateVersion = "23.11"; +} diff --git a/machines/oracle/hardware-configuration.nix b/machines/oracle/hardware-configuration.nix new file mode 100644 index 0000000..25a81a4 --- /dev/null +++ b/machines/oracle/hardware-configuration.nix @@ -0,0 +1,14 @@ +{ modulesPath, ... }: +{ + imports = [ (modulesPath + "/profiles/qemu-guest.nix") ]; + boot.loader.grub = { + efiSupport = true; + efiInstallAsRemovable = true; + device = "nodev"; + }; + fileSystems."/boot" = { device = "/dev/disk/by-uuid/97E5-76C2"; fsType = "vfat"; }; + boot.initrd.availableKernelModules = [ "ata_piix" "uhci_hcd" "xen_blkfront" "vmw_pvscsi" ]; + boot.initrd.kernelModules = [ "nvme" ]; + fileSystems."/" = { device = "/dev/mapper/centosvolume-root"; fsType = "xfs"; }; + +} diff --git a/user/environments/nixos-server/config.nix b/user/environments/nixos-server/config.nix new file mode 100644 index 0000000..1dd1750 --- /dev/null +++ b/user/environments/nixos-server/config.nix @@ -0,0 +1,3 @@ +{ + allowUnfree = true; +} diff --git a/user/environments/nixos-server/home.nix b/user/environments/nixos-server/home.nix new file mode 100644 index 0000000..6da0340 --- /dev/null +++ b/user/environments/nixos-server/home.nix @@ -0,0 +1,12 @@ +{ pkgs, ... }: { + imports = [ + ../../modules/git.nix + ../../modules/zsh.nix + ]; + + home.packages = with pkgs; [ + neovim + ]; + + home.stateVersion = "21.05"; +} From 1ca1f7edac6bba815f904f7bde5b925816ef43fe Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Thu, 11 Apr 2024 21:50:24 +0000 Subject: [PATCH 47/77] chore: update .editorconfig --- .editorconfig | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.editorconfig b/.editorconfig index 3853bb8..ce16426 100644 --- a/.editorconfig +++ b/.editorconfig @@ -1,5 +1,6 @@ root=true [*] -indent_style: tab +indent_style: space indent_size: 2 +end_of_line: lf From 640fe6418b95374f7077385856c7c0a84eb0a385 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Thu, 11 Apr 2024 22:28:46 +0000 Subject: [PATCH 48/77] fix(oracle): add nix module --- flake.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/flake.nix b/flake.nix index 75ecfa6..6681844 100644 --- a/flake.nix +++ b/flake.nix @@ -121,6 +121,7 @@ system = utils.lib.system.x86_64-linux; modules = [ home-manager.nixosModules.home-manager + ./modules/nix.nix { home-manager.useGlobalPkgs = true; home-manager.useUserPackages = true; From 7b1a8d3afc9c60ecf340b15c480ac7b09cf532ac Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Thu, 11 Apr 2024 22:29:06 +0000 Subject: [PATCH 49/77] packages(nixos-server): add lazygit --- user/environments/nixos-server/home.nix | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/user/environments/nixos-server/home.nix b/user/environments/nixos-server/home.nix index 6da0340..8239aeb 100644 --- a/user/environments/nixos-server/home.nix +++ b/user/environments/nixos-server/home.nix @@ -4,9 +4,10 @@ ../../modules/zsh.nix ]; - home.packages = with pkgs; [ - neovim - ]; + home.packages = with pkgs; [ + neovim + lazygit + ]; home.stateVersion = "21.05"; } From 70116909c67b8770e81ebe9b2769fee2b75f8a5a Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Thu, 11 Apr 2024 22:29:12 +0000 Subject: [PATCH 50/77] chore: update lockfile --- flake.lock | 80 +++++++++++++++++++++++++++--------------------------- 1 file changed, 40 insertions(+), 40 deletions(-) diff --git a/flake.lock b/flake.lock index b16a4d9..826ad49 100644 --- a/flake.lock +++ b/flake.lock @@ -7,11 +7,11 @@ ] }, "locked": { - "lastModified": 1706581965, - "narHash": "sha256-1H7dRdK9LJ7+2X1XQtbwXr+QMqtVVo/ZF0/LIvkjdK8=", + "lastModified": 1711763326, + "narHash": "sha256-sXcesZWKXFlEQ8oyGHnfk4xc9f2Ip0X/+YZOq3sKviI=", "owner": "lnl7", "repo": "nix-darwin", - "rev": "91b9daf672c957ef95a05491a75f62e6a01d5aaf", + "rev": "36524adc31566655f2f4d55ad6b875fb5c1a4083", "type": "github" }, "original": { @@ -24,11 +24,11 @@ "flake-compat": { "flake": false, "locked": { - "lastModified": 1673956053, - "narHash": "sha256-4gtG9iQuiKITOjNQQeQIpoIB6b16fm+504Ch3sNKLd8=", + "lastModified": 1696426674, + "narHash": "sha256-kvjfFW7WAETZlt09AgDn1MrtKzP7t90Vf7vypd3OL1U=", "owner": "edolstra", "repo": "flake-compat", - "rev": "35bb57c0c8d8b62bbfd284272c928ceb64ddbde9", + "rev": "0f9255e01c2351cc7d116c072cb317785dd33b33", "type": "github" }, "original": { @@ -58,11 +58,11 @@ "systems": "systems" }, "locked": { - "lastModified": 1681202837, - "narHash": "sha256-H+Rh19JDwRtpVPAWp64F+rlEtxUWBAQW28eAi3SRSzg=", + "lastModified": 1710146030, + "narHash": "sha256-SZ5L6eA7HJ/nmkzGG7/ISclqe6oZdOZTNoesiInkXPQ=", "owner": "numtide", "repo": "flake-utils", - "rev": "cfacdce06f30d2b68473a46042957675eebb3401", + "rev": "b1d9ab70662946ef0850d488da1c9019f3a9752a", "type": "github" }, "original": { @@ -132,11 +132,11 @@ ] }, "locked": { - "lastModified": 1705659542, - "narHash": "sha256-WA3xVfAk1AYmFdwghT7mt/erYpsU6JPu9mdTEP/e9HQ=", + "lastModified": 1712386041, + "narHash": "sha256-dA82pOMQNnCJMAsPG7AXG35VmCSMZsJHTFlTHizpKWQ=", "owner": "rycee", "repo": "home-manager", - "rev": "10cd9c53115061aa6a0a90aad0b0dde6a999cdb9", + "rev": "d6bb9f934f2870e5cbc5b94c79e9db22246141ff", "type": "github" }, "original": { @@ -153,11 +153,11 @@ "nixpkgs": "nixpkgs" }, "locked": { - "lastModified": 1706663720, - "narHash": "sha256-nPstfigc9FdWIwbtZcwfAjEP5fsI171CDMQ7rJdg0ok=", + "lastModified": 1712798884, + "narHash": "sha256-Q1qzg/UTsCdRx4g4rlweDL2yBQFnevsXTr74ONGoGm4=", "owner": "nix-community", "repo": "nix-vscode-extensions", - "rev": "129d9ddaf92f8a0942037aebf99dfa09d31e0dde", + "rev": "df5f35ed20d9f4fd64429c8e8c0bde079702f767", "type": "github" }, "original": { @@ -175,11 +175,11 @@ ] }, "locked": { - "lastModified": 1706608109, - "narHash": "sha256-Yc7pmonKJX/dOFm+qEInE+JlskMiN9OmOwUd/EKp4a0=", + "lastModified": 1710519878, + "narHash": "sha256-0dbc10OBFUVYyXC+C+N6vRUd8xyBSRxkcZ4Egipbx0M=", "owner": "nix-community", "repo": "NixOS-WSL", - "rev": "0b52d9e7a6c779f8b88c6e3bdfe6064fad648dcf", + "rev": "aef95bdb6800a3a2af7aa7083d6df03067da6592", "type": "github" }, "original": { @@ -190,27 +190,27 @@ }, "nixpkgs": { "locked": { - "lastModified": 1684570954, - "narHash": "sha256-FX5y4Sm87RWwfu9PI71XFvuRpZLowh00FQpIJ1WfXqE=", + "lastModified": 1712222121, + "narHash": "sha256-8f3glF4uwsPlDvaKDRgXD9xGe4YoCH4jA8ICxy/NbCo=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "3005f20ce0aaa58169cdee57c8aa12e5f1b6e1b3", + "rev": "23ff7d9dc4f3d553939e7bfe0d2667198f993536", "type": "github" }, "original": { "owner": "NixOS", - "ref": "nixos-unstable", + "ref": "nixpkgs-unstable", "repo": "nixpkgs", "type": "github" } }, "nixpkgs_2": { "locked": { - "lastModified": 1706515015, - "narHash": "sha256-eFfY5A7wlYy3jD/75lx6IJRueg4noE+jowl0a8lIlVo=", + "lastModified": 1712741485, + "narHash": "sha256-bCs0+MSTra80oXAsnM6Oq62WsirOIaijQ/BbUY59tR4=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "f4a8d6d5324c327dcc2d863eb7f3cc06ad630df4", + "rev": "b2cf36f43f9ef2ded5711b30b1f393ac423d8f72", "type": "github" }, "original": { @@ -237,11 +237,11 @@ }, "nur": { "locked": { - "lastModified": 1706665018, - "narHash": "sha256-NtvxIQhRxavrL7PQ1ZURqWr15XM1Dc98yv4U5gTbJhk=", + "lastModified": 1712871065, + "narHash": "sha256-DzEwVypkf1+GeTrMJu2aPshDOq0QzP8LpewiFg83h8A=", "owner": "nix-community", "repo": "NUR", - "rev": "98930fb5cf79e652111ed531e6ce777618b1c898", + "rev": "75f6c9334e9402f47d570172f57c78ea87792c13", "type": "github" }, "original": { @@ -270,11 +270,11 @@ "nixpkgs": "nixpkgs_3" }, "locked": { - "lastModified": 1706634984, - "narHash": "sha256-xn7lGPE8gRGBe3Lt8ESoN/uUHm7IrbiV7siupwjHX1o=", + "lastModified": 1712801594, + "narHash": "sha256-KZJnVw3TdfDyUhvClzgy3IEoC9tRhvG0yM+lHfqAm34=", "owner": "oxalica", "repo": "rust-overlay", - "rev": "883b84c426107a8ec020e7124f263d7c35a5bb9f", + "rev": "35ebec41fcdeeae8e012e7d62ba153a13645227f", "type": "github" }, "original": { @@ -360,11 +360,11 @@ }, "unstable": { "locked": { - "lastModified": 1706371002, - "narHash": "sha256-dwuorKimqSYgyu8Cw6ncKhyQjUDOyuXoxDTVmAXq88s=", + "lastModified": 1712608508, + "narHash": "sha256-vMZ5603yU0wxgyQeHJryOI+O61yrX2AHwY6LOFyV1gM=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "c002c6aa977ad22c60398daaa9be52f2203d0006", + "rev": "4cba8b53da471aea2ab2b0c1f30a81e7c451f4b6", "type": "github" }, "original": { @@ -378,11 +378,11 @@ "systems": "systems_4" }, "locked": { - "lastModified": 1705309234, - "narHash": "sha256-uNRRNRKmJyCRC/8y1RqBkqWBLM034y4qN7EprSdmgyA=", + "lastModified": 1710146030, + "narHash": "sha256-SZ5L6eA7HJ/nmkzGG7/ISclqe6oZdOZTNoesiInkXPQ=", "owner": "numtide", "repo": "flake-utils", - "rev": "1ef2e671c3b0c19053962c07dbda38332dcebf26", + "rev": "b1d9ab70662946ef0850d488da1c9019f3a9752a", "type": "github" }, "original": { @@ -399,11 +399,11 @@ ] }, "locked": { - "lastModified": 1684517665, - "narHash": "sha256-SaAr66uCQ8CF75jIr23FZjk1+9Kfwm5sQnwV25206Gs=", + "lastModified": 1709622318, + "narHash": "sha256-bTscF0366xtoIXgH7Zq+Mn0mpX3w4h/2xKpHiYMyLNc=", "owner": "nix-community", "repo": "nixos-vscode-server", - "rev": "1e1358493df6529d4c7bc4cc3066f76fd16d4ae6", + "rev": "d0ed9b8cf1f0a71f110df9119489ab047e0726bd", "type": "github" }, "original": { From ab6070b63bdf9de15c82c1b9a19fd644b09ad6c5 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Sun, 14 Apr 2024 17:28:07 -0400 Subject: [PATCH 51/77] wip: add agenix --- flake.nix | 12 ++++++++++++ secrets/secrets.nix | 8 ++++++++ secrets/wireguard-oracle.age | 0 secrets/wireguard-thinkcentre.age | 8 ++++++++ 4 files changed, 28 insertions(+) create mode 100644 secrets/secrets.nix create mode 100644 secrets/wireguard-oracle.age create mode 100644 secrets/wireguard-thinkcentre.age diff --git a/flake.nix b/flake.nix index f4f440f..012ce3e 100644 --- a/flake.nix +++ b/flake.nix @@ -10,6 +10,11 @@ rust-overlay.url = "github:oxalica/rust-overlay"; nix-vscode-extensions.url = "github:nix-community/nix-vscode-extensions"; + agenix = { + url = "github:ryantm/agenix"; + inputs.nixpkgs.follows = "nixpkgs"; + }; + nixos-wsl = { url = "github:nix-community/NixOS-WSL"; inputs = { @@ -39,6 +44,7 @@ nixpkgs, unstable, nur, + agenix, utils, rust-overlay, nix-vscode-extensions, @@ -113,6 +119,12 @@ } ./machines/thinkcentre/configuration.nix + agenix.nixosModules.default + { + environment.systemPackages = [ + agenix.packages.x86_64-linux.default + ]; + } ]; specialArgs = {inherit inputs;}; }; diff --git a/secrets/secrets.nix b/secrets/secrets.nix new file mode 100644 index 0000000..f65c165 --- /dev/null +++ b/secrets/secrets.nix @@ -0,0 +1,8 @@ +let + venus = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIKlbfu7ApeF0khvdzMSWfDaunI+5zy/BboN7qEE4jWd2 root@venus"; + oracle = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPc/HYsbpVsyoU2n0EiqQ4+3aSiFPtddjPCGK187W24f michael@oracle"; + # systems = [system1]; +in { + "wireguard-thinkcentre.age".publicKeys = venus; + "wireguard-oracle.age".publicKeys = oracle; +} diff --git a/secrets/wireguard-oracle.age b/secrets/wireguard-oracle.age new file mode 100644 index 0000000..e69de29 diff --git a/secrets/wireguard-thinkcentre.age b/secrets/wireguard-thinkcentre.age new file mode 100644 index 0000000..7a12fc8 --- /dev/null +++ b/secrets/wireguard-thinkcentre.age @@ -0,0 +1,8 @@ +age-encryption.org/v1 +-> ssh-ed25519 ZRcQJQ hW/podq9plJd2PjecAKIDoIrBauv2xW4fX8KnUqDWX0 +chaSLI/n9PJgS4GVLbpv72JT/ddzrQ9w5aRt8kvLr5s +-> ssh-ed25519 jBnYqQ rkO818kLhDFnnCFLFh3UkniZXscuSnVKGkf+2nck+CI +3TZVgJ6xRG0DyBjuhT+V7tr4XEauvhFh8fDJmK0Pf18 +--- P7UYIFfZ65jY4bM+MUXYptXT8UOnAkhcLqrXniG1EmQ +@>==g(nWˇA0*Z }k !mf/th +*m?sT a};lYF)]퐇[ \ No newline at end of file From 680c0d90fb09c363488b65a8f81cc308779981a9 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Sun, 14 Apr 2024 21:35:47 +0000 Subject: [PATCH 52/77] feat(oracle): add agenix --- flake.lock | 96 ++++++++++++++++++++++++++++++++++++++++++++++++++---- flake.nix | 6 ++++ 2 files changed, 95 insertions(+), 7 deletions(-) diff --git a/flake.lock b/flake.lock index 826ad49..62db2e8 100644 --- a/flake.lock +++ b/flake.lock @@ -1,6 +1,51 @@ { "nodes": { + "agenix": { + "inputs": { + "darwin": "darwin", + "home-manager": "home-manager", + "nixpkgs": [ + "nixpkgs" + ], + "systems": "systems" + }, + "locked": { + "lastModified": 1712079060, + "narHash": "sha256-/JdiT9t+zzjChc5qQiF+jhrVhRt8figYH29rZO7pFe4=", + "owner": "ryantm", + "repo": "agenix", + "rev": "1381a759b205dff7a6818733118d02253340fd5e", + "type": "github" + }, + "original": { + "owner": "ryantm", + "repo": "agenix", + "type": "github" + } + }, "darwin": { + "inputs": { + "nixpkgs": [ + "agenix", + "nixpkgs" + ] + }, + "locked": { + "lastModified": 1700795494, + "narHash": "sha256-gzGLZSiOhf155FW7262kdHo2YDeugp3VuIFb4/GGng0=", + "owner": "lnl7", + "repo": "nix-darwin", + "rev": "4b9b83d5a92e8c1fbfd8eb27eda375908c11ec4d", + "type": "github" + }, + "original": { + "owner": "lnl7", + "ref": "master", + "repo": "nix-darwin", + "type": "github" + } + }, + "darwin_2": { "inputs": { "nixpkgs": [ "nixpkgs" @@ -55,7 +100,7 @@ }, "flake-utils": { "inputs": { - "systems": "systems" + "systems": "systems_2" }, "locked": { "lastModified": 1710146030, @@ -73,7 +118,7 @@ }, "flake-utils_2": { "inputs": { - "systems": "systems_2" + "systems": "systems_3" }, "locked": { "lastModified": 1705309234, @@ -91,7 +136,7 @@ }, "flake-utils_3": { "inputs": { - "systems": "systems_3" + "systems": "systems_4" }, "locked": { "lastModified": 1705309234, @@ -109,7 +154,7 @@ }, "flake-utils_4": { "inputs": { - "systems": "systems_5" + "systems": "systems_6" }, "locked": { "lastModified": 1681202837, @@ -126,6 +171,27 @@ } }, "home-manager": { + "inputs": { + "nixpkgs": [ + "agenix", + "nixpkgs" + ] + }, + "locked": { + "lastModified": 1703113217, + "narHash": "sha256-7ulcXOk63TIT2lVDSExj7XzFx09LpdSAPtvgtM7yQPE=", + "owner": "nix-community", + "repo": "home-manager", + "rev": "3bfaacf46133c037bb356193bd2f1765d9dc82c1", + "type": "github" + }, + "original": { + "owner": "nix-community", + "repo": "home-manager", + "type": "github" + } + }, + "home-manager_2": { "inputs": { "nixpkgs": [ "nixpkgs" @@ -252,8 +318,9 @@ }, "root": { "inputs": { - "darwin": "darwin", - "home-manager": "home-manager", + "agenix": "agenix", + "darwin": "darwin_2", + "home-manager": "home-manager_2", "nix-vscode-extensions": "nix-vscode-extensions", "nixos-wsl": "nixos-wsl", "nixpkgs": "nixpkgs_2", @@ -358,6 +425,21 @@ "type": "github" } }, + "systems_6": { + "locked": { + "lastModified": 1681028828, + "narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=", + "owner": "nix-systems", + "repo": "default", + "rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e", + "type": "github" + }, + "original": { + "owner": "nix-systems", + "repo": "default", + "type": "github" + } + }, "unstable": { "locked": { "lastModified": 1712608508, @@ -375,7 +457,7 @@ }, "utils": { "inputs": { - "systems": "systems_4" + "systems": "systems_5" }, "locked": { "lastModified": 1710146030, diff --git a/flake.nix b/flake.nix index cc8e2b9..421cee7 100644 --- a/flake.nix +++ b/flake.nix @@ -139,6 +139,12 @@ home-manager.useUserPackages = true; home-manager.users.michael = import ./user/environments/nixos-server/home.nix; } + agenix.nixosModules.default + { + environment.systemPackages = [ + agenix.packages.x86_64-linux.default + ]; + } ./machines/oracle/configuration.nix ]; From 1ed8d522aefd323114435a61e4653864be1b1eaf Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Sun, 14 Apr 2024 21:36:01 +0000 Subject: [PATCH 53/77] fix(oracle): change hostname --- machines/oracle/configuration.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/machines/oracle/configuration.nix b/machines/oracle/configuration.nix index a01056a..e5840bf 100644 --- a/machines/oracle/configuration.nix +++ b/machines/oracle/configuration.nix @@ -6,7 +6,7 @@ boot.tmp.cleanOnBoot = true; zramSwap.enable = true; - networking.hostName = "gringottsstatus"; + networking.hostName = "oracle"; networking.domain = "subnet08161027.vcn08161027.oraclevcn.com"; networking.firewall.enable = true; From 7af13cdccbc01214da6c3874af94510e3d5144de Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Sun, 14 Apr 2024 17:41:23 -0400 Subject: [PATCH 54/77] fix(agenix): pass keys as lists --- secrets/secrets.nix | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/secrets/secrets.nix b/secrets/secrets.nix index f65c165..ab464e1 100644 --- a/secrets/secrets.nix +++ b/secrets/secrets.nix @@ -3,6 +3,6 @@ let oracle = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPc/HYsbpVsyoU2n0EiqQ4+3aSiFPtddjPCGK187W24f michael@oracle"; # systems = [system1]; in { - "wireguard-thinkcentre.age".publicKeys = venus; - "wireguard-oracle.age".publicKeys = oracle; + "wireguard-thinkcentre.age".publicKeys = [venus]; + "wireguard-oracle.age".publicKeys = [oracle]; } From e3020dd7b5ac603e542939e9590eccba277cfd09 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Mon, 15 Apr 2024 23:32:15 +0000 Subject: [PATCH 55/77] fix(oracle): make neovim default editor --- machines/oracle/configuration.nix | 1 + user/environments/nixos-server/home.nix | 5 ++++- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/machines/oracle/configuration.nix b/machines/oracle/configuration.nix index e5840bf..db3a2ba 100644 --- a/machines/oracle/configuration.nix +++ b/machines/oracle/configuration.nix @@ -16,6 +16,7 @@ }; programs.zsh.enable = true; + environment.variables.EDITOR = "nvim"; users.users.michael = { isNormalUser = true; diff --git a/user/environments/nixos-server/home.nix b/user/environments/nixos-server/home.nix index 8239aeb..ffd76fb 100644 --- a/user/environments/nixos-server/home.nix +++ b/user/environments/nixos-server/home.nix @@ -5,9 +5,12 @@ ]; home.packages = with pkgs; [ - neovim lazygit ]; + programs.neovim = { + enable = true; + }; + home.stateVersion = "21.05"; } From 8754bea4181548b4a54923a83e2004df64c2a830 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Mon, 15 Apr 2024 23:51:39 +0000 Subject: [PATCH 56/77] wip: wireguard tunnel configurations --- machines/oracle/configuration.nix | 19 +++++++++++++++++++ machines/thinkcentre/configuration.nix | 20 +++++++++++++++++++- secrets/wireguard-oracle.age | 5 +++++ 3 files changed, 43 insertions(+), 1 deletion(-) diff --git a/machines/oracle/configuration.nix b/machines/oracle/configuration.nix index db3a2ba..bd029fe 100644 --- a/machines/oracle/configuration.nix +++ b/machines/oracle/configuration.nix @@ -15,6 +15,25 @@ PasswordAuthentication = false; }; + environment.systemPackages = with pkgs; [ wireguard-tools ]; + + # Wireguard tunnel + age.secrets.wireguardOracle.file = "../../secrets/wireguard-oracle.age"; + networking.wg-quick.interfaces = { + wg0 = { + address = [ "10.0.10.1/24" ]; + listenPort = 51820; + privateKeyFile = config.age.secrets.wireguardOracle.path; + + peers = [ + { + publicKey = "iKJO9Q8LsdCdApapTX9CJmrtAKn1TYhg4YUiBUBPzmo="; + allowedIPs = "10.0.10.2/32"; + }; + ]; + }; + }; + programs.zsh.enable = true; environment.variables.EDITOR = "nvim"; diff --git a/machines/thinkcentre/configuration.nix b/machines/thinkcentre/configuration.nix index 04459d7..ae0f246 100644 --- a/machines/thinkcentre/configuration.nix +++ b/machines/thinkcentre/configuration.nix @@ -1,4 +1,4 @@ -{pkgs, ...}: { +{pkgs, config, ...}: { imports = [ # Include the results of the hardware scan. ./hardware-configuration.nix @@ -6,6 +6,24 @@ networking.hostName = "venus"; # Define your hostname. + # Wireguard tunnel to oracle + age.secrets.wireguardThinkcentre.file = "../../secrets/wireguard-thinkcentre.age"; + networking.wg-quick.interfaces = { + wg0 = { + address = [ "10.0.10.2/32" ]; + listenPort = 51820; + privateKeyFile = config.age.secrets.wireguardThinkcentre.path; + + peers = [ + { + publicKey = "sdqT2l1HRe9rDYejJ+luQK8zdC+/KqDuQ1rpvZq/KlQ="; + endpoint = "150.136.162.107:51820"; + allowedIPs = "10.0.10.1/24"; + }; + ]; + }; + }; + # Set your time zone. time.timeZone = "America/New_York"; diff --git a/secrets/wireguard-oracle.age b/secrets/wireguard-oracle.age index e69de29..9e52161 100644 --- a/secrets/wireguard-oracle.age +++ b/secrets/wireguard-oracle.age @@ -0,0 +1,5 @@ +age-encryption.org/v1 +-> ssh-ed25519 XlaGxQ 64T+sKc6cuLGJpF2mjdRoLupmh4r4xDJYWnz2XtW5yw +Fn2imf2lLbjRLQOG7FP844OfmLm2uX3zz+mEy4k4PbM +--- hVrfmKh1csvwWIvzvdcOiJVM9+KzG1xLr5eYj9qZ3oE +*nzkXI`{#.=,`Wghc.[wJdV,ߖ&izL9B"u}͟ \ No newline at end of file From 77eac934bf3c77d7ec8799d1aac01f55eb02d98b Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Mon, 15 Apr 2024 19:52:45 -0400 Subject: [PATCH 57/77] chore(thinkcentre): enable ssh access --- machines/thinkcentre/configuration.nix | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) diff --git a/machines/thinkcentre/configuration.nix b/machines/thinkcentre/configuration.nix index 04459d7..db0b945 100644 --- a/machines/thinkcentre/configuration.nix +++ b/machines/thinkcentre/configuration.nix @@ -1,10 +1,15 @@ -{pkgs, ...}: { +{ + config, + pkgs, + ... +}: { imports = [ # Include the results of the hardware scan. ./hardware-configuration.nix ]; networking.hostName = "venus"; # Define your hostname. + networking.nameservers = ["1.1.1.1" "8.8.8.8"]; # Set your time zone. time.timeZone = "America/New_York"; @@ -30,6 +35,15 @@ xkbVariant = ""; }; + services.openssh = { + enable = true; + settings = { + PermitRootLogin = "no"; + PasswordAuthentication = false; + AllowUsers = ["michael"]; + }; + }; + swapDevices = [ { device = "/swapfile"; @@ -46,6 +60,10 @@ description = "Michael Thomas"; extraGroups = ["wheel" "docker" "podman" "adbusers" "dialout"]; shell = pkgs.zsh; + openssh.authorizedKeys.keys = [ + # Neptune + "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQDUYHiTel+RDzygCeNwV25cnBBNioM19EQWqxPC+xq7lNlNcAQ4wi9JIOONVGkshxPXzKZyR3F53Igs9JZr1E9088L52eUp35JhW1pthai82cw1jGkj9wxcKJnU6b7QNDKA+ejPTC/ciFFKytMyPgID0ICzBRQsnj15i4lGvGDgfTQ7qfI2J855H7S7qOpY7cbsGfeoz3f8Ye1FspJFDsNu9QhX05iunBcbni0uLoTtgS5cEBRr7H9RkKR7GCfd4Ae/sp+aeDkLU4aBkEi+A8VLfR74Juia1j/3mAAmkgJKGcBCKUv0ixBGd6XclZmkF8f2Hx0z8mDxJ7U8lsDUSKdvxK7fecsM4F/GTvjrUxV1nLD4SRQ06GtBmGQGDzIn3Nm1URd6gGT9W3486XJsqmGzjuHa5o4WhmBgh/Gs8xUcv7kWD5enrYacBr+HKVJWnnLFp+XfAYaMCT6j/4jc4D9/9hijRbhboICTDxWCWtFgz7QpsO6BQpi/wkR4Ql61vPc= michael@neptune" + ]; }; # This value determines the NixOS release from which the default From c59cebdc32cc2227a40c1c1ac1588141830f2880 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Mon, 15 Apr 2024 20:10:08 -0400 Subject: [PATCH 58/77] fix(thinkcentre): corect syntax --- machines/thinkcentre/configuration.nix | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/machines/thinkcentre/configuration.nix b/machines/thinkcentre/configuration.nix index 9553288..58887a7 100644 --- a/machines/thinkcentre/configuration.nix +++ b/machines/thinkcentre/configuration.nix @@ -12,10 +12,10 @@ networking.nameservers = ["1.1.1.1" "8.8.8.8"]; # Wireguard tunnel to oracle - age.secrets.wireguardThinkcentre.file = "../../secrets/wireguard-thinkcentre.age"; + age.secrets.wireguardThinkcentre.file = ../../secrets/wireguard-thinkcentre.age; networking.wg-quick.interfaces = { wg0 = { - address = [ "10.0.10.2/32" ]; + address = ["10.0.10.2/32"]; listenPort = 51820; privateKeyFile = config.age.secrets.wireguardThinkcentre.path; @@ -23,8 +23,8 @@ { publicKey = "sdqT2l1HRe9rDYejJ+luQK8zdC+/KqDuQ1rpvZq/KlQ="; endpoint = "150.136.162.107:51820"; - allowedIPs = "10.0.10.1/24"; - }; + allowedIPs = ["10.0.10.1/24"]; + } ]; }; }; From 0691019f497f5d1b5d1bf6611a2282e43060c725 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Mon, 15 Apr 2024 20:10:27 -0400 Subject: [PATCH 59/77] chore: add thinkcentre wireguard secret --- secrets/wireguard-thinkcentre.age | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/secrets/wireguard-thinkcentre.age b/secrets/wireguard-thinkcentre.age index 7a12fc8..5373bc4 100644 --- a/secrets/wireguard-thinkcentre.age +++ b/secrets/wireguard-thinkcentre.age @@ -1,8 +1,6 @@ age-encryption.org/v1 --> ssh-ed25519 ZRcQJQ hW/podq9plJd2PjecAKIDoIrBauv2xW4fX8KnUqDWX0 -chaSLI/n9PJgS4GVLbpv72JT/ddzrQ9w5aRt8kvLr5s --> ssh-ed25519 jBnYqQ rkO818kLhDFnnCFLFh3UkniZXscuSnVKGkf+2nck+CI -3TZVgJ6xRG0DyBjuhT+V7tr4XEauvhFh8fDJmK0Pf18 ---- P7UYIFfZ65jY4bM+MUXYptXT8UOnAkhcLqrXniG1EmQ -@>==g(nWˇA0*Z }k !mf/th -*m?sT a};lYF)]퐇[ \ No newline at end of file +-> ssh-ed25519 jBnYqQ 48BjRfCsPvVwt45viGe49ZHISReZTniIK59WeUibHAQ +apkw2ylpsIsiUMKa1fUTZXAoZExcjLhIlKlMehJbl8U +--- n/WIoiJtGUO2zibPTd4/yGaZfiOKjOEMyLCm0L9OxzM +O*X&jic`x::9a1ǎn,Nv3jLzoj4.xkP +̤ \ No newline at end of file From 0ed08e8f0c9eb3f6274f4797581caad2479c985f Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Tue, 16 Apr 2024 13:33:45 +0000 Subject: [PATCH 60/77] fix(oracle): correct syntax and open firewall --- machines/oracle/configuration.nix | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/machines/oracle/configuration.nix b/machines/oracle/configuration.nix index bd029fe..7258b2d 100644 --- a/machines/oracle/configuration.nix +++ b/machines/oracle/configuration.nix @@ -8,7 +8,10 @@ networking.hostName = "oracle"; networking.domain = "subnet08161027.vcn08161027.oraclevcn.com"; - networking.firewall.enable = true; + networking.firewall = { + enable = true; + allowedUDPPorts = [ 51820 ]; + }; services.openssh.enable = true; services.openssh.settings = { @@ -18,7 +21,7 @@ environment.systemPackages = with pkgs; [ wireguard-tools ]; # Wireguard tunnel - age.secrets.wireguardOracle.file = "../../secrets/wireguard-oracle.age"; + age.secrets.wireguardOracle.file = ../../secrets/wireguard-oracle.age; networking.wg-quick.interfaces = { wg0 = { address = [ "10.0.10.1/24" ]; @@ -28,8 +31,8 @@ peers = [ { publicKey = "iKJO9Q8LsdCdApapTX9CJmrtAKn1TYhg4YUiBUBPzmo="; - allowedIPs = "10.0.10.2/32"; - }; + allowedIPs = ["10.0.10.2/32"]; + } ]; }; }; From 99dde2f4f25bd4b5a053b5e1dbb8debc8799dd31 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Tue, 16 Apr 2024 13:34:01 +0000 Subject: [PATCH 61/77] fix(oracle): rekey wireguard secret --- secrets/secrets.nix | 2 +- secrets/wireguard-oracle.age | Bin 257 -> 257 bytes 2 files changed, 1 insertion(+), 1 deletion(-) diff --git a/secrets/secrets.nix b/secrets/secrets.nix index ab464e1..04b852a 100644 --- a/secrets/secrets.nix +++ b/secrets/secrets.nix @@ -1,6 +1,6 @@ let venus = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIKlbfu7ApeF0khvdzMSWfDaunI+5zy/BboN7qEE4jWd2 root@venus"; - oracle = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPc/HYsbpVsyoU2n0EiqQ4+3aSiFPtddjPCGK187W24f michael@oracle"; + oracle = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJ0vHE/b6tKk6I6DwEemIF5VdS/JBXW8eiYIBmnbv5LI root@oracle"; # systems = [system1]; in { "wireguard-thinkcentre.age".publicKeys = [venus]; diff --git a/secrets/wireguard-oracle.age b/secrets/wireguard-oracle.age index 9e52161318fd553d7262ba80d68079c16fa72fc1..40d70c6755819161230dafafc4b1f86815b74b73 100644 GIT binary patch delta 228 zcmVfV>om{AT%&cH)&}(H*qmgb!AsUQfPBwR!>r6RyH+SHezo} zQE6>7R8Mj@Rzp)o3U6*mOlD6QbclbFHBNbXnHw!bzOLKZ#Y#`S}%2RPEt8D zV+wk@0FyHsRTH`byJ7XVFF!`!ToRx-$zlaO;EXmrpxe7L8vZ)7yN94_VDp-6M@n!;GHq&PQg2LkaBXNbax{2E zN?BKKdNNpaS2cNe3Px@+X>DdQY)oQmQcO`#M>j@LI5ad*W^GJuGIdxpdU`8uMR_!9 zG*Dtq3N0-yAZS){W^GGoF=KOfcUMVvdUj-EPiab4O*tz|dR<2`cuaCNWm#%DaauEP zMG7jgnBM)fZtA7^8cNjA eWYGfHRxIn^mL_R>ucesIOxig@>>_o2y3L=#2U%YL From 007969cdb55cd2c719276dcdeedf7dfbf1841def Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Tue, 16 Apr 2024 10:30:36 -0400 Subject: [PATCH 62/77] fix(git_nixos): move to git-credential-manager --- modules/hyprland.nix | 2 ++ user/modules/git_nixos.nix | 10 ++++------ 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/modules/hyprland.nix b/modules/hyprland.nix index 8affcd3..0a3243c 100644 --- a/modules/hyprland.nix +++ b/modules/hyprland.nix @@ -4,6 +4,8 @@ package = pkgs.unstable.hyprland; }; + services.gnome.gnome-keyring.enable = true; + environment.systemPackages = with pkgs; [ # Theme adw-gtk3 diff --git a/user/modules/git_nixos.nix b/user/modules/git_nixos.nix index 20d2c7c..6c76c5f 100644 --- a/user/modules/git_nixos.nix +++ b/user/modules/git_nixos.nix @@ -2,15 +2,13 @@ programs.git = { package = pkgs.gitAndTools.gitFull; extraConfig = { - credential.helper = [ - # Cache credentials for 2 weeks - "cache --timeout 1209600" - "oauth" - ]; + credential.helper = "manager"; + credential.credentialStore = "secretservice"; + credential."git.thomasfmly.org".provider = "generic"; }; }; home.packages = with pkgs; [ - git-credential-oauth + git-credential-manager ]; } From 86679ffcc81f43384483904f5226289702d8a597 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Tue, 16 Apr 2024 10:30:47 -0400 Subject: [PATCH 63/77] fix(thinkcentre): add wireguard keepalive --- machines/thinkcentre/configuration.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/machines/thinkcentre/configuration.nix b/machines/thinkcentre/configuration.nix index 58887a7..f76b785 100644 --- a/machines/thinkcentre/configuration.nix +++ b/machines/thinkcentre/configuration.nix @@ -24,6 +24,7 @@ publicKey = "sdqT2l1HRe9rDYejJ+luQK8zdC+/KqDuQ1rpvZq/KlQ="; endpoint = "150.136.162.107:51820"; allowedIPs = ["10.0.10.1/24"]; + persistentKeepalive = 25; } ]; }; From 440fd28d28eb18afed326f112372c810da3b2dce Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Tue, 16 Apr 2024 10:31:03 -0400 Subject: [PATCH 64/77] fix(thinkcentre): add oracle as authorized ssh user --- machines/thinkcentre/configuration.nix | 2 ++ 1 file changed, 2 insertions(+) diff --git a/machines/thinkcentre/configuration.nix b/machines/thinkcentre/configuration.nix index f76b785..a163b73 100644 --- a/machines/thinkcentre/configuration.nix +++ b/machines/thinkcentre/configuration.nix @@ -82,6 +82,8 @@ openssh.authorizedKeys.keys = [ # Neptune "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABgQDUYHiTel+RDzygCeNwV25cnBBNioM19EQWqxPC+xq7lNlNcAQ4wi9JIOONVGkshxPXzKZyR3F53Igs9JZr1E9088L52eUp35JhW1pthai82cw1jGkj9wxcKJnU6b7QNDKA+ejPTC/ciFFKytMyPgID0ICzBRQsnj15i4lGvGDgfTQ7qfI2J855H7S7qOpY7cbsGfeoz3f8Ye1FspJFDsNu9QhX05iunBcbni0uLoTtgS5cEBRr7H9RkKR7GCfd4Ae/sp+aeDkLU4aBkEi+A8VLfR74Juia1j/3mAAmkgJKGcBCKUv0ixBGd6XclZmkF8f2Hx0z8mDxJ7U8lsDUSKdvxK7fecsM4F/GTvjrUxV1nLD4SRQ06GtBmGQGDzIn3Nm1URd6gGT9W3486XJsqmGzjuHa5o4WhmBgh/Gs8xUcv7kWD5enrYacBr+HKVJWnnLFp+XfAYaMCT6j/4jc4D9/9hijRbhboICTDxWCWtFgz7QpsO6BQpi/wkR4Ql61vPc= michael@neptune" + # Oracle + "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIPc/HYsbpVsyoU2n0EiqQ4+3aSiFPtddjPCGK187W24f michael@oracle" ]; }; From d90a4fb372134acdbcd7eeec07d62c46eb9683aa Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Tue, 16 Apr 2024 17:11:04 -0400 Subject: [PATCH 65/77] feat(venus): add keycloak --- machines/thinkcentre/configuration.nix | 23 +++++++++++++++++++++++ secrets/keycloak-db.age | 6 ++++++ secrets/secrets.nix | 4 ++++ 3 files changed, 33 insertions(+) create mode 100644 secrets/keycloak-db.age diff --git a/machines/thinkcentre/configuration.nix b/machines/thinkcentre/configuration.nix index a163b73..71b39ea 100644 --- a/machines/thinkcentre/configuration.nix +++ b/machines/thinkcentre/configuration.nix @@ -10,6 +10,12 @@ networking.hostName = "venus"; # Define your hostname. networking.nameservers = ["1.1.1.1" "8.8.8.8"]; + networking.firewall = { + enable = true; + interfaces."wg0" = { + allowedTCPPorts = [7654]; + }; + }; # Wireguard tunnel to oracle age.secrets.wireguardThinkcentre.file = ../../secrets/wireguard-thinkcentre.age; @@ -63,6 +69,23 @@ }; }; + age.secrets.keycloakDb.file = ../../secrets/keycloak-db.age; + services.keycloak = { + enable = true; + settings = { + hostname-url = "https://auth.s.michaelt.xyz"; + hostname-admin-url = "https://auth.s.michaelt.xyz"; + hostname-strict = false; + hostname-strict-https = false; + # proxy-headers = "xforwarded"; + proxy = "edge"; + http-enabled = true; + http-port = 7654; + # https-port = -1; + }; + database.passwordFile = config.age.secrets.keycloakDb.path; + }; + swapDevices = [ { device = "/swapfile"; diff --git a/secrets/keycloak-db.age b/secrets/keycloak-db.age new file mode 100644 index 0000000..0d2f771 --- /dev/null +++ b/secrets/keycloak-db.age @@ -0,0 +1,6 @@ +age-encryption.org/v1 +-> ssh-ed25519 jBnYqQ 0cD5v5l7JGQmlnM0q7J8VDWrObgphnv3OqSu94BWKUk +XcFJF3Z7bJq87/dbwejxvNWlyXCpXAG8zFsdccP25/Y +--- HfE3zlQE++CyJhcsZ2v9u+lwgdUmNq07ujxK9fqHEfk +?ΖZݻuv|V@sc}دIirgӦ F +{c@[$ \ No newline at end of file diff --git a/secrets/secrets.nix b/secrets/secrets.nix index 04b852a..90b4180 100644 --- a/secrets/secrets.nix +++ b/secrets/secrets.nix @@ -3,6 +3,10 @@ let oracle = "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIJ0vHE/b6tKk6I6DwEemIF5VdS/JBXW8eiYIBmnbv5LI root@oracle"; # systems = [system1]; in { + # Venus "wireguard-thinkcentre.age".publicKeys = [venus]; + "keycloak-db.age".publicKeys = [venus]; + + # Oracle "wireguard-oracle.age".publicKeys = [oracle]; } From a487049887e2932996fd0c0ed68f2c24969ad63a Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Wed, 17 Apr 2024 09:26:40 -0400 Subject: [PATCH 66/77] chore: remove unnecessary comment --- machines/thinkcentre/configuration.nix | 1 - 1 file changed, 1 deletion(-) diff --git a/machines/thinkcentre/configuration.nix b/machines/thinkcentre/configuration.nix index 71b39ea..e2bb2bb 100644 --- a/machines/thinkcentre/configuration.nix +++ b/machines/thinkcentre/configuration.nix @@ -81,7 +81,6 @@ proxy = "edge"; http-enabled = true; http-port = 7654; - # https-port = -1; }; database.passwordFile = config.age.secrets.keycloakDb.path; }; From e0a19056d2196a7c8b6266c78aa60c0aa8520193 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Wed, 17 Apr 2024 09:26:51 -0400 Subject: [PATCH 67/77] feat: add hosts module --- modules/common.nix | 1 + modules/hosts.nix | 5 +++++ 2 files changed, 6 insertions(+) create mode 100644 modules/hosts.nix diff --git a/modules/common.nix b/modules/common.nix index 1ae9d8f..f74e9ce 100644 --- a/modules/common.nix +++ b/modules/common.nix @@ -6,6 +6,7 @@ ./cups.nix ./flatpak.nix ./fonts.nix + ./hosts.nix ./nix.nix ./sound.nix ]; diff --git a/modules/hosts.nix b/modules/hosts.nix new file mode 100644 index 0000000..25b3510 --- /dev/null +++ b/modules/hosts.nix @@ -0,0 +1,5 @@ +{ + networking.hosts = { + "150.136.162.107" = ["oracle"]; + }; +} From 71f2e6723574aa21db0f935346e541c117f6ec01 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Wed, 17 Apr 2024 09:27:54 -0400 Subject: [PATCH 68/77] chore: update lazy.nvim --- user/modules/nvim/lazy-lock.json | 78 +++++++++++--------------------- 1 file changed, 26 insertions(+), 52 deletions(-) diff --git a/user/modules/nvim/lazy-lock.json b/user/modules/nvim/lazy-lock.json index 13b1121..b364e8b 100644 --- a/user/modules/nvim/lazy-lock.json +++ b/user/modules/nvim/lazy-lock.json @@ -1,55 +1,29 @@ { - "LazyVim": { "branch": "main", "commit": "879e29504d43e9f178d967ecc34d482f902e5a91" }, - "LuaSnip": { "branch": "master", "commit": "82108e7e31cc6fc223cc5df5cae6d89f70bb199f" }, - "bufferline.nvim": { "branch": "main", "commit": "e48ce1805697e4bb97bc171c081e849a65859244" }, - "catppuccin": { "branch": "main", "commit": "5e36ca599f4aa41bdd87fbf2c5aae4397ac55074" }, - "cmp-buffer": { "branch": "main", "commit": "3022dbc9166796b644a841a02de8dd1cc1d311fa" }, - "cmp-nvim-lsp": { "branch": "main", "commit": "5af77f54de1b16c34b23cba810150689a3a90312" }, - "cmp-path": { "branch": "main", "commit": "91ff86cd9c29299a64f968ebb45846c485725f23" }, - "cmp_luasnip": { "branch": "master", "commit": "05a9ab28b53f71d1aece421ef32fee2cb857a843" }, - "conform.nvim": { "branch": "master", "commit": "75e7c5c7eb5fbd53f8b12dc420b31ec70770b231" }, - "dashboard-nvim": { "branch": "master", "commit": "63df28409d940f9cac0a925df09d3dc369db9841" }, - "dressing.nvim": { "branch": "master", "commit": "94b0d24483d56f3777ee0c8dc51675f21709318c" }, - "flash.nvim": { "branch": "main", "commit": "48817af25f51c0590653bbc290866e4890fe1cbe" }, - "friendly-snippets": { "branch": "main", "commit": "69a2c1675b66e002799f5eef803b87a12f593049" }, - "gitsigns.nvim": { "branch": "main", "commit": "4aaacbf5e5e2218fd05eb75703fe9e0f85335803" }, - "indent-blankline.nvim": { "branch": "master", "commit": "12e92044d313c54c438bd786d11684c88f6f78cd" }, - "lazy.nvim": { "branch": "main", "commit": "96584866b9c5e998cbae300594d0ccfd0c464627" }, - "lualine.nvim": { "branch": "master", "commit": "566b7036f717f3d676362742630518a47f132fff" }, - "mason-lspconfig.nvim": { "branch": "main", "commit": "0989bdf4fdf7b5aa4c74131d7ffccc3f399ac788" }, - "mason.nvim": { "branch": "main", "commit": "e110bc3be1a7309617cecd77bfe4bf86ba1b8134" }, - "mini.ai": { "branch": "main", "commit": "f7787cff9cc42004f722ca1e64e6af4e64e34177" }, - "mini.bufremove": { "branch": "main", "commit": "020243bfed8c8b941f2c20626faf3ea39c0c0e1b" }, - "mini.comment": { "branch": "main", "commit": "67f00d3ebbeae15e84584d971d0c32aad4f4f3a4" }, - "mini.indentscope": { "branch": "main", "commit": "5a8369475cd7cd6f207a4d288406d03b0fc48bdb" }, - "mini.pairs": { "branch": "main", "commit": "552062017ff207e1f35f7028bfb3f27c7421d22d" }, - "mini.surround": { "branch": "main", "commit": "7bf8915ba15d7a4f3c2afe7868d3c15a858d73f1" }, - "monokai-pro.nvim": { "branch": "master", "commit": "b49795aa8a0cb6596660dae31ac10a43eff2d33b" }, - "neo-tree.nvim": { "branch": "v3.x", "commit": "77d9f484b88fd380386b46ed9206e5374d69d9d8" }, - "neoconf.nvim": { "branch": "main", "commit": "64437787dba70fce50dad7bfbb97d184c5bc340f" }, - "neodev.nvim": { "branch": "main", "commit": "dde00106b9094f101980b364fae02fd85d357306" }, - "noice.nvim": { "branch": "main", "commit": "92433164e2f7118d4122c7674c3834d9511722ba" }, - "nui.nvim": { "branch": "main", "commit": "35da9ca1de0fc4dda96c2e214d93d363c145f418" }, - "nvim-cmp": { "branch": "main", "commit": "538e37ba87284942c1d76ed38dd497e54e65b891" }, - "nvim-lint": { "branch": "master", "commit": "8df53b5dde8ea80f0a039775777eae6648a10229" }, - "nvim-lspconfig": { "branch": "master", "commit": "e47ccfae775f0d572ef0f3a7d245f043b259dafc" }, - "nvim-notify": { "branch": "master", "commit": "1576123bff3bed67bc673a3076e591abfe5d8ca9" }, - "nvim-spectre": { "branch": "master", "commit": "d8906855f1949ac97b1e77aaf8d3fe12ed158ddc" }, - "nvim-treesitter": { "branch": "master", "commit": "8cd2b230174efbf7b5d9f49fe2f90bda6b5eb16e" }, - "nvim-treesitter-context": { "branch": "master", "commit": "400a99ad43ac78af1148061da3491cba2637ad29" }, - "nvim-treesitter-textobjects": { "branch": "master", "commit": "85b9d0cbd4ff901abcda862b50dbb34e0901848b" }, - "nvim-ts-autotag": { "branch": "main", "commit": "8515e48a277a2f4947d91004d9aa92c29fdc5e18" }, - "nvim-ts-context-commentstring": { "branch": "main", "commit": "1277b4a1f451b0f18c0790e1a7f12e1e5fdebfee" }, - "nvim-web-devicons": { "branch": "master", "commit": "db0c864375c198cacc171ff373e76bfce2a85045" }, - "persistence.nvim": { "branch": "main", "commit": "ad538bfd5336f1335cdb6fd4e0b0eebfa6e12f32" }, - "plenary.nvim": { "branch": "master", "commit": "55d9fe89e33efd26f532ef20223e5f9430c8b0c0" }, - "telescope-fzf-native.nvim": { "branch": "main", "commit": "6c921ca12321edaa773e324ef64ea301a1d0da62" }, - "telescope.nvim": { "branch": "master", "commit": "da8b3d485975a8727bea127518b65c980521ae22" }, - "todo-comments.nvim": { "branch": "main", "commit": "4a6737a8d70fe1ac55c64dfa47fcb189ca431872" }, - "tokyonight.nvim": { "branch": "main", "commit": "f247ee700b569ed43f39320413a13ba9b0aef0db" }, - "tree-sitter-asm": { "branch": "main", "commit": "6ace266be7ad6bf486a95427ca3fc949aff66211" }, - "trouble.nvim": { "branch": "main", "commit": "f1168feada93c0154ede4d1fe9183bf69bac54ea" }, - "vim-illuminate": { "branch": "master", "commit": "3bd2ab64b5d63b29e05691e624927e5ebbf0fb86" }, - "vim-startuptime": { "branch": "master", "commit": "454b3de856b7bd298700de33d79774ca9b9e3875" }, + "LazyVim": { "branch": "main", "commit": "5646ee5191da244ff8ea57b9dba8a7e0d1dbdd42" }, + "bufferline.nvim": { "branch": "main", "commit": "64e2c5def50dfd6b6f14d96a45fa3d815a4a1eef" }, + "catppuccin": { "branch": "main", "commit": "a1439ad7c584efb3d0ce14ccb835967f030450fe" }, + "conform.nvim": { "branch": "master", "commit": "820eec990d5f332d30cf939954c8672a43a0459e" }, + "dashboard-nvim": { "branch": "master", "commit": "681300934baf36f6184ca41f0b26aed22056d4ee" }, + "dressing.nvim": { "branch": "master", "commit": "18e5beb3845f085b6a33c24112b37988f3f93c06" }, + "indent-blankline.nvim": { "branch": "master", "commit": "3d08501caef2329aba5121b753e903904088f7e6" }, + "lazy.nvim": { "branch": "main", "commit": "bef521ac89c8d423f9d092e37b58e8af0c099309" }, + "lualine.nvim": { "branch": "master", "commit": "0a5a66803c7407767b799067986b4dc3036e1983" }, + "mini.indentscope": { "branch": "main", "commit": "a8274b6ea2d868198d27bd91a31ed5ea3a6a5744" }, + "monokai-pro.nvim": { "branch": "master", "commit": "aafde73a622435891d36b411d8623e705ead6293" }, + "noice.nvim": { "branch": "main", "commit": "0cbe3f88d038320bdbda3c4c5c95f43a13c3aa12" }, + "nui.nvim": { "branch": "main", "commit": "cbd2668414331c10039278f558630ed19b93e69b" }, + "nvim-lint": { "branch": "master", "commit": "f098232d70cebe90e27404928c9bc19ca7a5a7b5" }, + "nvim-lspconfig": { "branch": "master", "commit": "9266dc26862d8f3556c2ca77602e811472b4c5b8" }, + "nvim-notify": { "branch": "master", "commit": "5371f4bfc1f6d3adf4fe9d62cd3a9d44356bfd15" }, + "nvim-treesitter": { "branch": "master", "commit": "b350369740e885c85f0f62dd8fe645c6f887ddc6" }, + "nvim-treesitter-context": { "branch": "master", "commit": "c24a7a6dc5fde325af844d165323aa6f7082866e" }, + "nvim-treesitter-textobjects": { "branch": "master", "commit": "23b820146956b3b681c19e10d3a8bc0cbd9a1d4c" }, + "nvim-ts-autotag": { "branch": "main", "commit": "531f48334c422222aebc888fd36e7d109cb354cd" }, + "nvim-web-devicons": { "branch": "master", "commit": "b3468391470034353f0e5110c70babb5c62967d3" }, + "persistence.nvim": { "branch": "main", "commit": "4982499c1636eac254b72923ab826ee7827b3084" }, + "plenary.nvim": { "branch": "master", "commit": "8aad4396840be7fc42896e3011751b7609ca4119" }, + "tokyonight.nvim": { "branch": "main", "commit": "9bf9ec53d5e87b025e2404069b71e7ebdc3a13e5" }, + "tree-sitter-asm": { "branch": "main", "commit": "afdc3d5da18d42cbb471c0f40527dbed9cace7ad" }, + "vim-startuptime": { "branch": "master", "commit": "ac2cccb5be617672add1f4f3c0a55ce99ba34e01" }, "which-key.nvim": { "branch": "main", "commit": "4433e5ec9a507e5097571ed55c02ea9658fb268a" } } \ No newline at end of file From 5d0d5f7fb1d24a05450dc6148409e46f339d9b19 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Sun, 28 Apr 2024 16:45:32 -0400 Subject: [PATCH 69/77] feat(zsh): remove prezto for faster start times --- machines/mac/configuration.nix | 1 + user/modules/zsh.nix | 48 +++++++++++++++------------------- 2 files changed, 22 insertions(+), 27 deletions(-) diff --git a/machines/mac/configuration.nix b/machines/mac/configuration.nix index b709d89..71faf22 100644 --- a/machines/mac/configuration.nix +++ b/machines/mac/configuration.nix @@ -46,6 +46,7 @@ eval `/usr/libexec/path_helper -s` fi ''; + enableGlobalCompInit = false; }; }; diff --git a/user/modules/zsh.nix b/user/modules/zsh.nix index 4073c7f..ce22015 100644 --- a/user/modules/zsh.nix +++ b/user/modules/zsh.nix @@ -5,6 +5,27 @@ }: { programs.zsh = { enable = true; + + enableAutosuggestions = true; + # autosuggestion.enable = true; + syntaxHighlighting.enable = true; + historySubstringSearch.enable = true; + autocd = true; + enableCompletion = true; + + # Enable pure prompt + initExtra = '' + fpath+=${pkgs.pure-prompt}/share/zsh/site-functions + autoload -U promptinit; + promptinit + prompt pure + ''; + + sessionVariables = { + # Make ls colorful on MacOS + CLICOLOR = 1; + }; + plugins = [ { name = "zsh-nix-shell"; @@ -16,33 +37,6 @@ sha256 = "1lzrn0n4fxfcgg65v0qhnj7wnybybqzs4adz7xsrkgmcsr0ii8b7"; }; } - { - name = "powerlevel10k-config"; - src = lib.cleanSource ./p10k-config; - file = "p10k.zsh"; - } ]; - prezto = { - enable = true; - pmodules = [ - "archive" - "docker" - "environment" - "git" - "terminal" - "editor" - "history" - "directory" - "spectrum" - "utility" - "completion" - "command-not-found" - "syntax-highlighting" - "history-substring-search" - "autosuggestions" - "prompt" - ]; - prompt.theme = "powerlevel10k"; - }; }; } From 32a7404a020c9ba118873a0d81c60b8ab5f09aac Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Sun, 28 Apr 2024 18:12:03 -0400 Subject: [PATCH 70/77] fix(zsh): do not load global nixos config --- user/modules/zsh.nix | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/user/modules/zsh.nix b/user/modules/zsh.nix index ce22015..4c5e353 100644 --- a/user/modules/zsh.nix +++ b/user/modules/zsh.nix @@ -21,6 +21,11 @@ prompt pure ''; + envExtra = '' + # Do not load global configuration + setopt no_global_rcs + ''; + sessionVariables = { # Make ls colorful on MacOS CLICOLOR = 1; From bf7cc65df33dfef26b25b496d702872257eea1df Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Sun, 28 Apr 2024 18:19:10 -0400 Subject: [PATCH 71/77] feat(nvim): upgrade lazyvim to v3 --- user/modules/nvim/lazy-lock.json | 50 ++++++++++++++++++++++++-------- user/modules/nvim/lazyvim.json | 4 +-- 2 files changed, 40 insertions(+), 14 deletions(-) diff --git a/user/modules/nvim/lazy-lock.json b/user/modules/nvim/lazy-lock.json index b364e8b..92b61d1 100644 --- a/user/modules/nvim/lazy-lock.json +++ b/user/modules/nvim/lazy-lock.json @@ -1,29 +1,55 @@ { - "LazyVim": { "branch": "main", "commit": "5646ee5191da244ff8ea57b9dba8a7e0d1dbdd42" }, - "bufferline.nvim": { "branch": "main", "commit": "64e2c5def50dfd6b6f14d96a45fa3d815a4a1eef" }, + "LazyVim": { "branch": "main", "commit": "9b4675ddde38fdae09978bd7dbdba83ec91f4d80" }, + "LuaSnip": { "branch": "master", "commit": "8f3d3465ba5c7ade0a8adb41eca5736f291a3fa8" }, + "bufferline.nvim": { "branch": "main", "commit": "73540cb95f8d95aa1af3ed57713c6720c78af915" }, "catppuccin": { "branch": "main", "commit": "a1439ad7c584efb3d0ce14ccb835967f030450fe" }, - "conform.nvim": { "branch": "master", "commit": "820eec990d5f332d30cf939954c8672a43a0459e" }, - "dashboard-nvim": { "branch": "master", "commit": "681300934baf36f6184ca41f0b26aed22056d4ee" }, - "dressing.nvim": { "branch": "master", "commit": "18e5beb3845f085b6a33c24112b37988f3f93c06" }, + "cmp-buffer": { "branch": "main", "commit": "3022dbc9166796b644a841a02de8dd1cc1d311fa" }, + "cmp-nvim-lsp": { "branch": "main", "commit": "5af77f54de1b16c34b23cba810150689a3a90312" }, + "cmp-path": { "branch": "main", "commit": "91ff86cd9c29299a64f968ebb45846c485725f23" }, + "cmp_luasnip": { "branch": "master", "commit": "05a9ab28b53f71d1aece421ef32fee2cb857a843" }, + "conform.nvim": { "branch": "master", "commit": "12b3995537f52ba2810a9857e8ca256881febbda" }, + "dashboard-nvim": { "branch": "master", "commit": "6d06924b562de6f0bb136edf1bf549afbf6b7d00" }, + "dressing.nvim": { "branch": "master", "commit": "5162edb1442a729a885c45455a07e9a89058be2f" }, + "flash.nvim": { "branch": "main", "commit": "48817af25f51c0590653bbc290866e4890fe1cbe" }, + "friendly-snippets": { "branch": "main", "commit": "ea068f1becd91bcd4591fceb6420d4335e2e14d3" }, + "gitsigns.nvim": { "branch": "main", "commit": "035da036e68e509ed158414416c827d022d914bd" }, "indent-blankline.nvim": { "branch": "master", "commit": "3d08501caef2329aba5121b753e903904088f7e6" }, "lazy.nvim": { "branch": "main", "commit": "bef521ac89c8d423f9d092e37b58e8af0c099309" }, "lualine.nvim": { "branch": "master", "commit": "0a5a66803c7407767b799067986b4dc3036e1983" }, + "mason-lspconfig.nvim": { "branch": "main", "commit": "273fdde8ac5e51f3a223ba70980e52bbc09d9f6f" }, + "mason.nvim": { "branch": "main", "commit": "751b1fcbf3d3b783fcf8d48865264a9bcd8f9b10" }, + "mini.ai": { "branch": "main", "commit": "98e45e6832351354e41e82b32a80ce7537c20746" }, + "mini.bufremove": { "branch": "main", "commit": "931a3bb514147d9e812767275c4beba6b779b1d3" }, + "mini.comment": { "branch": "main", "commit": "f9f1a646fd3d9df7397aa1b9550a875fe8189eb0" }, "mini.indentscope": { "branch": "main", "commit": "a8274b6ea2d868198d27bd91a31ed5ea3a6a5744" }, + "mini.pairs": { "branch": "main", "commit": "04f58f2545ed80ac3b52dd4826e93f33e15b2af6" }, + "mini.surround": { "branch": "main", "commit": "a00d69be09e3fe27dfa9e5b0298410d0e148e3e2" }, "monokai-pro.nvim": { "branch": "master", "commit": "aafde73a622435891d36b411d8623e705ead6293" }, + "neo-tree.nvim": { "branch": "v3.x", "commit": "7aad1bf3f6b849cbf108e02c55ad4d701cb4d33a" }, + "neoconf.nvim": { "branch": "main", "commit": "ba3503e246ea687732e51f7f9878e653e2e2039b" }, + "neodev.nvim": { "branch": "main", "commit": "ce9a2e8eaba5649b553529c5498acb43a6c317cd" }, "noice.nvim": { "branch": "main", "commit": "0cbe3f88d038320bdbda3c4c5c95f43a13c3aa12" }, "nui.nvim": { "branch": "main", "commit": "cbd2668414331c10039278f558630ed19b93e69b" }, + "nvim-cmp": { "branch": "main", "commit": "8f3c541407e691af6163e2447f3af1bd6e17f9a3" }, "nvim-lint": { "branch": "master", "commit": "f098232d70cebe90e27404928c9bc19ca7a5a7b5" }, - "nvim-lspconfig": { "branch": "master", "commit": "9266dc26862d8f3556c2ca77602e811472b4c5b8" }, + "nvim-lspconfig": { "branch": "master", "commit": "3224b099845c24ca456d1e77a9268a788f106f0b" }, "nvim-notify": { "branch": "master", "commit": "5371f4bfc1f6d3adf4fe9d62cd3a9d44356bfd15" }, - "nvim-treesitter": { "branch": "master", "commit": "b350369740e885c85f0f62dd8fe645c6f887ddc6" }, - "nvim-treesitter-context": { "branch": "master", "commit": "c24a7a6dc5fde325af844d165323aa6f7082866e" }, + "nvim-spectre": { "branch": "master", "commit": "026394a8458d62c6b7b305c076ce675420dbaa4c" }, + "nvim-treesitter": { "branch": "master", "commit": "19f69a5b434470723c32311cdc4d8d0e8db76358" }, + "nvim-treesitter-context": { "branch": "master", "commit": "4fe0a54e86859744968e1a5c7867b49c86855774" }, "nvim-treesitter-textobjects": { "branch": "master", "commit": "23b820146956b3b681c19e10d3a8bc0cbd9a1d4c" }, "nvim-ts-autotag": { "branch": "main", "commit": "531f48334c422222aebc888fd36e7d109cb354cd" }, - "nvim-web-devicons": { "branch": "master", "commit": "b3468391470034353f0e5110c70babb5c62967d3" }, + "nvim-ts-context-commentstring": { "branch": "main", "commit": "a6382f744f584bbf71d0a563af789af7190aabda" }, + "nvim-web-devicons": { "branch": "master", "commit": "27eac98fd6675d29d0e19d4d0622fd7a3968483a" }, "persistence.nvim": { "branch": "main", "commit": "4982499c1636eac254b72923ab826ee7827b3084" }, - "plenary.nvim": { "branch": "master", "commit": "8aad4396840be7fc42896e3011751b7609ca4119" }, - "tokyonight.nvim": { "branch": "main", "commit": "9bf9ec53d5e87b025e2404069b71e7ebdc3a13e5" }, - "tree-sitter-asm": { "branch": "main", "commit": "afdc3d5da18d42cbb471c0f40527dbed9cace7ad" }, + "plenary.nvim": { "branch": "master", "commit": "08e301982b9a057110ede7a735dd1b5285eb341f" }, + "telescope-fzf-native.nvim": { "branch": "main", "commit": "9ef21b2e6bb6ebeaf349a0781745549bbb870d27" }, + "telescope.nvim": { "branch": "master", "commit": "35f94f0ef32d70e3664a703cefbe71bd1456d899" }, + "todo-comments.nvim": { "branch": "main", "commit": "a7e39ae9e74f2c8c6dc4eea6d40c3971ae84752d" }, + "tokyonight.nvim": { "branch": "main", "commit": "67afeaf7fd6ebba000633e89f63c31694057edde" }, + "tree-sitter-asm": { "branch": "main", "commit": "b0306e9bb2ebe01c6562f1aef265cc42ccc53070" }, + "trouble.nvim": { "branch": "main", "commit": "b9cf677f20bb2faa2dacfa870b084e568dca9572" }, + "vim-illuminate": { "branch": "master", "commit": "e522e0dd742a83506db0a72e1ced68c9c130f185" }, "vim-startuptime": { "branch": "master", "commit": "ac2cccb5be617672add1f4f3c0a55ce99ba34e01" }, "which-key.nvim": { "branch": "main", "commit": "4433e5ec9a507e5097571ed55c02ea9658fb268a" } } \ No newline at end of file diff --git a/user/modules/nvim/lazyvim.json b/user/modules/nvim/lazyvim.json index ff6a139..f03853f 100644 --- a/user/modules/nvim/lazyvim.json +++ b/user/modules/nvim/lazyvim.json @@ -3,7 +3,7 @@ ], "news": { - "NEWS.md": "2123" + "NEWS.md": "3314" }, - "version": 2 + "version": 3 } \ No newline at end of file From 3067d96eba2be89fa64fc32dfdccc946b97c86d8 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Sun, 28 Apr 2024 22:59:28 -0400 Subject: [PATCH 72/77] fix(dev): update java to v21 --- user/modules/dev.nix | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/user/modules/dev.nix b/user/modules/dev.nix index f994240..a5dad44 100644 --- a/user/modules/dev.nix +++ b/user/modules/dev.nix @@ -38,7 +38,7 @@ programs.java = { enable = true; - package = pkgs.jdk17; + package = pkgs.jdk21; }; programs.zoxide = { From d71614ac07be701ba371f54531c0cb85323834f0 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Sun, 28 Apr 2024 22:59:59 -0400 Subject: [PATCH 73/77] fix(zsh): enable 'correct' option --- user/modules/zsh.nix | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/user/modules/zsh.nix b/user/modules/zsh.nix index 4c5e353..6172308 100644 --- a/user/modules/zsh.nix +++ b/user/modules/zsh.nix @@ -26,6 +26,10 @@ setopt no_global_rcs ''; + loginExtra = '' + setopt correct + ''; + sessionVariables = { # Make ls colorful on MacOS CLICOLOR = 1; From 49832454dc30107ab7c67b9960fff85e3df0c285 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Sun, 28 Apr 2024 23:00:20 -0400 Subject: [PATCH 74/77] fix(latex): add 'exam' package --- user/modules/latex.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/user/modules/latex.nix b/user/modules/latex.nix index 8a00698..bc6dd01 100644 --- a/user/modules/latex.nix +++ b/user/modules/latex.nix @@ -6,6 +6,7 @@ (tpkgs) scheme-medium csquotes + exam ; }; }; From 6d620fe0cd017f2277dad831133fde35cf8baf04 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Sun, 28 Apr 2024 23:03:28 -0400 Subject: [PATCH 75/77] chore: update lockfile --- flake.lock | 72 +++++++++++++++++++++++++++--------------------------- 1 file changed, 36 insertions(+), 36 deletions(-) diff --git a/flake.lock b/flake.lock index 62db2e8..4199ecd 100644 --- a/flake.lock +++ b/flake.lock @@ -10,11 +10,11 @@ "systems": "systems" }, "locked": { - "lastModified": 1712079060, - "narHash": "sha256-/JdiT9t+zzjChc5qQiF+jhrVhRt8figYH29rZO7pFe4=", + "lastModified": 1714136352, + "narHash": "sha256-BtWQ2Th/jamO1SlD+2ASSW5Jaf7JhA/JLpQHk0Goqpg=", "owner": "ryantm", "repo": "agenix", - "rev": "1381a759b205dff7a6818733118d02253340fd5e", + "rev": "24a7ea390564ccd5b39b7884f597cfc8d7f6f44e", "type": "github" }, "original": { @@ -52,11 +52,11 @@ ] }, "locked": { - "lastModified": 1711763326, - "narHash": "sha256-sXcesZWKXFlEQ8oyGHnfk4xc9f2Ip0X/+YZOq3sKviI=", + "lastModified": 1713946171, + "narHash": "sha256-lc75rgRQLdp4Dzogv5cfqOg6qYc5Rp83oedF2t0kDp8=", "owner": "lnl7", "repo": "nix-darwin", - "rev": "36524adc31566655f2f4d55ad6b875fb5c1a4083", + "rev": "230a197063de9287128e2c68a7a4b0cd7d0b50a7", "type": "github" }, "original": { @@ -121,11 +121,11 @@ "systems": "systems_3" }, "locked": { - "lastModified": 1705309234, - "narHash": "sha256-uNRRNRKmJyCRC/8y1RqBkqWBLM034y4qN7EprSdmgyA=", + "lastModified": 1710146030, + "narHash": "sha256-SZ5L6eA7HJ/nmkzGG7/ISclqe6oZdOZTNoesiInkXPQ=", "owner": "numtide", "repo": "flake-utils", - "rev": "1ef2e671c3b0c19053962c07dbda38332dcebf26", + "rev": "b1d9ab70662946ef0850d488da1c9019f3a9752a", "type": "github" }, "original": { @@ -198,11 +198,11 @@ ] }, "locked": { - "lastModified": 1712386041, - "narHash": "sha256-dA82pOMQNnCJMAsPG7AXG35VmCSMZsJHTFlTHizpKWQ=", + "lastModified": 1714043624, + "narHash": "sha256-Xn2r0Jv95TswvPlvamCC46wwNo8ALjRCMBJbGykdhcM=", "owner": "rycee", "repo": "home-manager", - "rev": "d6bb9f934f2870e5cbc5b94c79e9db22246141ff", + "rev": "86853e31dc1b62c6eeed11c667e8cdd0285d4411", "type": "github" }, "original": { @@ -219,11 +219,11 @@ "nixpkgs": "nixpkgs" }, "locked": { - "lastModified": 1712798884, - "narHash": "sha256-Q1qzg/UTsCdRx4g4rlweDL2yBQFnevsXTr74ONGoGm4=", + "lastModified": 1714267526, + "narHash": "sha256-92vUWmEZgINBgC2uT39Ihpbc/Ok86iOT2DjPrmrnFnA=", "owner": "nix-community", "repo": "nix-vscode-extensions", - "rev": "df5f35ed20d9f4fd64429c8e8c0bde079702f767", + "rev": "6be0c88ffc813c82a6d3c99129c5cdaed5499468", "type": "github" }, "original": { @@ -241,11 +241,11 @@ ] }, "locked": { - "lastModified": 1710519878, - "narHash": "sha256-0dbc10OBFUVYyXC+C+N6vRUd8xyBSRxkcZ4Egipbx0M=", + "lastModified": 1714134704, + "narHash": "sha256-jgTn20s3qzar/IqhjQcEO+dIQbT4hBFIloVntiCURkA=", "owner": "nix-community", "repo": "NixOS-WSL", - "rev": "aef95bdb6800a3a2af7aa7083d6df03067da6592", + "rev": "4fb773cffed9bf1efdabcc01b25637eaeb4e8e9c", "type": "github" }, "original": { @@ -256,11 +256,11 @@ }, "nixpkgs": { "locked": { - "lastModified": 1712222121, - "narHash": "sha256-8f3glF4uwsPlDvaKDRgXD9xGe4YoCH4jA8ICxy/NbCo=", + "lastModified": 1713805509, + "narHash": "sha256-YgSEan4CcrjivCNO5ZNzhg7/8ViLkZ4CB/GrGBVSudo=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "23ff7d9dc4f3d553939e7bfe0d2667198f993536", + "rev": "1e1dc66fe68972a76679644a5577828b6a7e8be4", "type": "github" }, "original": { @@ -272,11 +272,11 @@ }, "nixpkgs_2": { "locked": { - "lastModified": 1712741485, - "narHash": "sha256-bCs0+MSTra80oXAsnM6Oq62WsirOIaijQ/BbUY59tR4=", + "lastModified": 1714272655, + "narHash": "sha256-3/ghIWCve93ngkx5eNPdHIKJP/pMzSr5Wc4rNKE1wOc=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "b2cf36f43f9ef2ded5711b30b1f393ac423d8f72", + "rev": "12430e43bd9b81a6b4e79e64f87c624ade701eaf", "type": "github" }, "original": { @@ -303,11 +303,11 @@ }, "nur": { "locked": { - "lastModified": 1712871065, - "narHash": "sha256-DzEwVypkf1+GeTrMJu2aPshDOq0QzP8LpewiFg83h8A=", + "lastModified": 1714340308, + "narHash": "sha256-2uX/VxxNTvxa0FZ5yY2BZDmMCtQVocqa6wdOC8YmzDE=", "owner": "nix-community", "repo": "NUR", - "rev": "75f6c9334e9402f47d570172f57c78ea87792c13", + "rev": "53a8759e2675301db38ae5cc17aa9b954a936e9c", "type": "github" }, "original": { @@ -337,11 +337,11 @@ "nixpkgs": "nixpkgs_3" }, "locked": { - "lastModified": 1712801594, - "narHash": "sha256-KZJnVw3TdfDyUhvClzgy3IEoC9tRhvG0yM+lHfqAm34=", + "lastModified": 1714270637, + "narHash": "sha256-sq/0YEupY9yoRpg9ft8r2sjoRo84MQipionTuk4w1YI=", "owner": "oxalica", "repo": "rust-overlay", - "rev": "35ebec41fcdeeae8e012e7d62ba153a13645227f", + "rev": "44f8738f4b9805f7c60118c48f85da835839311a", "type": "github" }, "original": { @@ -442,11 +442,11 @@ }, "unstable": { "locked": { - "lastModified": 1712608508, - "narHash": "sha256-vMZ5603yU0wxgyQeHJryOI+O61yrX2AHwY6LOFyV1gM=", + "lastModified": 1714253743, + "narHash": "sha256-mdTQw2XlariysyScCv2tTE45QSU9v/ezLcHJ22f0Nxc=", "owner": "NixOS", "repo": "nixpkgs", - "rev": "4cba8b53da471aea2ab2b0c1f30a81e7c451f4b6", + "rev": "58a1abdbae3217ca6b702f03d3b35125d88a2994", "type": "github" }, "original": { @@ -481,11 +481,11 @@ ] }, "locked": { - "lastModified": 1709622318, - "narHash": "sha256-bTscF0366xtoIXgH7Zq+Mn0mpX3w4h/2xKpHiYMyLNc=", + "lastModified": 1713958148, + "narHash": "sha256-8PDNi/dgoI2kyM7uSiU4eoLBqUKoA+3TXuz+VWmuCOc=", "owner": "nix-community", "repo": "nixos-vscode-server", - "rev": "d0ed9b8cf1f0a71f110df9119489ab047e0726bd", + "rev": "fc900c16efc6a5ed972fb6be87df018bcf3035bc", "type": "github" }, "original": { From 4f2121798eed20ab3c6feef223ac98a66f1266dc Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Wed, 1 May 2024 00:41:10 -0400 Subject: [PATCH 76/77] feat(applications): add alacritty --- user/modules/applications/alacritty.nix | 28 +++++++++++++++++++++++++ 1 file changed, 28 insertions(+) create mode 100644 user/modules/applications/alacritty.nix diff --git a/user/modules/applications/alacritty.nix b/user/modules/applications/alacritty.nix new file mode 100644 index 0000000..e24e878 --- /dev/null +++ b/user/modules/applications/alacritty.nix @@ -0,0 +1,28 @@ +{ + programs.alacritty = { + enable = true; + settings = { + window = { + decorations = "Buttonless"; + }; + font = { + size = 14; + offset.y = 4; + normal = { + family = "ZedMono Nerd Font"; + style = "Extended Light"; + }; + bold.style = "Extended Bold"; + italic.style = "Extended Italic"; + bold_italic.style = "Extended Bold Italic"; + }; + key_bindings = [ + { + key = "Slash"; + mods = "Control"; + chars = "\\x1f"; + } + ]; + }; + }; +} From 72c91a682a9e487839a410e01b327a24a2ddc7e0 Mon Sep 17 00:00:00 2001 From: Michael Thomas Date: Wed, 1 May 2024 00:42:28 -0400 Subject: [PATCH 77/77] feat(mac): add alacritty module --- user/environments/mac/home.nix | 1 + 1 file changed, 1 insertion(+) diff --git a/user/environments/mac/home.nix b/user/environments/mac/home.nix index bc21383..736d849 100644 --- a/user/environments/mac/home.nix +++ b/user/environments/mac/home.nix @@ -1,5 +1,6 @@ {pkgs, ...}: { imports = [ + ../../modules/applications/alacritty.nix ../../modules/applications/sioyek.nix ../../modules/zsh.nix