├── .editorconfig ├── .envrc ├── .gitignore ├── .sops.yaml ├── .vscode └── settings.json ├── LICENSE ├── README.md ├── _sources ├── generated.json └── generated.nix ├── default.nix ├── devshell.nix ├── flake.lock ├── flake.nix ├── lut.png ├── nvfetcher.toml ├── pkgs ├── default.nix ├── fennel-ls │ └── default.nix ├── firepwa │ ├── Cargo.lock │ └── default.nix ├── logseq.nix └── overlay.nix ├── secrets └── secrets.json ├── systems ├── EVIL-LAPTOP │ ├── config.nix │ ├── default.nix │ └── hardware.nix ├── GAMER-PC │ ├── config.nix │ ├── default.nix │ └── hardware.nix ├── default.nix ├── modules │ ├── amd.nix │ ├── bluetooth.nix │ ├── core │ │ ├── bootloader.nix │ │ ├── default.nix │ │ ├── fonts.nix │ │ ├── home-manager.nix │ │ ├── network.nix │ │ ├── nix.nix │ │ ├── opengl.nix │ │ ├── security.nix │ │ └── sound.nix │ ├── geoclue.nix │ ├── greetd │ │ └── default.nix │ ├── hyprland.nix │ ├── intel.nix │ ├── kleur.nix │ ├── laptop.nix │ ├── ld.nix │ ├── navidrome.nix │ ├── niri.nix │ ├── nix.png │ ├── nvidia.nix │ ├── openrgb │ │ └── default.nix │ ├── printing.nix │ ├── sops.nix │ ├── steam.nix │ ├── sunshine.nix │ ├── tablet.nix │ ├── teamviewer.nix │ ├── theme.nix │ ├── vaultwarden.nix │ └── wayland.nix └── tau │ ├── config.nix │ ├── default.nix │ └── hardware.nix ├── users ├── default.nix ├── modules │ ├── dunst.nix │ ├── editor.nix │ ├── electron │ │ ├── config │ │ │ └── electron-flags.conf │ │ └── default.nix │ ├── emacs │ │ ├── default.nix │ │ └── doom.d │ │ │ ├── config.el │ │ │ ├── init.el │ │ │ ├── packages.el │ │ │ └── splash.svg │ ├── eww │ │ ├── config │ │ │ ├── eww.scss │ │ │ ├── eww.yuck │ │ │ ├── polls.yuck │ │ │ ├── powermode │ │ │ │ ├── bottom.yuck │ │ │ │ ├── left.yuck │ │ │ │ ├── right.yuck │ │ │ │ └── top.yuck │ │ │ ├── scripts │ │ │ │ ├── getcoverArt │ │ │ │ └── getvol │ │ │ └── systemStats.yuck │ │ └── default.nix │ ├── fastfetch │ │ ├── config │ │ │ ├── config.json │ │ │ └── nix.png │ │ └── default.nix │ ├── firefox │ │ ├── default.nix │ │ ├── images │ │ │ ├── back.svg │ │ │ ├── bookmarks.svg │ │ │ ├── downloads.svg │ │ │ ├── forward.svg │ │ │ ├── history.svg │ │ │ ├── menu.svg │ │ │ ├── overflow.svg │ │ │ └── reload.svg │ │ └── userChrome.nix │ ├── fish │ │ └── default.nix │ ├── gammastep.nix │ ├── git.nix │ ├── gtk.nix │ ├── helix │ │ ├── config │ │ │ └── helix.scm │ │ └── default.nix │ ├── hyprland │ │ ├── default.nix │ │ └── hyprland.conf.nix │ ├── keyring.nix │ ├── kitty │ │ ├── default.nix │ │ └── kitty.conf │ ├── kleur.nix │ ├── laptop.nix │ ├── neovim │ │ ├── config │ │ │ ├── fnl │ │ │ │ ├── config.fnl │ │ │ │ ├── macros.fnl │ │ │ │ ├── plugins.fnl │ │ │ │ └── plugins │ │ │ │ │ ├── colourscheme.fnl │ │ │ │ │ ├── flash.fnl │ │ │ │ │ ├── focus.fnl │ │ │ │ │ ├── harpoon.fnl │ │ │ │ │ ├── keymap.fnl │ │ │ │ │ ├── lsp.fnl │ │ │ │ │ ├── lspsaga.fnl │ │ │ │ │ ├── neotree.fnl │ │ │ │ │ ├── noice.fnl │ │ │ │ │ ├── rzip.fnl │ │ │ │ │ ├── statusline.fnl │ │ │ │ │ ├── telescope.fnl │ │ │ │ │ ├── treesitter.fnl │ │ │ │ │ └── ufo.fnl │ │ │ ├── init.lua │ │ │ └── lua │ │ │ │ └── evil_line_2.lua │ │ ├── default.nix │ │ └── skia-externals.json │ ├── niri.nix │ ├── nushell │ │ ├── config │ │ │ ├── config.nu │ │ │ ├── env.nu │ │ │ ├── ls-colors │ │ │ └── starship.toml │ │ └── default.nix │ ├── obs │ │ └── default.nix │ ├── openrgb │ │ ├── MOOSIC TIME.orp │ │ └── default.nix │ ├── playerctl.nix │ ├── shell.nix │ ├── spotify │ │ ├── config │ │ │ └── config │ │ └── default.nix │ ├── swaylock.nix │ ├── syncthing.nix │ ├── terminal.nix │ ├── theme.nix │ ├── vscode │ │ └── default.nix │ ├── webcord │ │ └── default.nix │ ├── wezterm │ │ ├── default.nix │ │ └── wezterm.lua │ ├── wlsunset.nix │ ├── xdg.nix │ ├── yazi.nix │ └── zellij │ │ ├── default.nix │ │ └── layouts │ │ ├── default.kdl │ │ ├── js.kdl │ │ └── rust.kdl ├── tau │ └── default.nix └── tntman │ └── default.nix └── wallpapers ├── Orbit.png ├── Particles.png ├── colourlist.txt ├── gabriel.png ├── intoTheCatrix.png ├── justAReallyCoolArtwork.png ├── launch.jpg ├── linox.png ├── longRoadAhead.png ├── theAlmightyHexagon.png ├── vivaldiBackground.png └── waves.png /.editorconfig: -------------------------------------------------------------------------------- 1 | root = true 2 | 3 | [*] 4 | end_of_line = lf 5 | insert_final_newline = true 6 | indent_style = space 7 | indent_size = 2 8 | -------------------------------------------------------------------------------- /.envrc: -------------------------------------------------------------------------------- 1 | use flake 2 | watch_file devshell.nix -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | /.direnv 2 | -------------------------------------------------------------------------------- /.sops.yaml: -------------------------------------------------------------------------------- 1 | keys: 2 | - &suyashtnt_desktop age1wc2azunqm69j6uwdfrtw6z2td7me2qmqf5rfndwke2mner5g94nsc0j2ns 3 | - &suyashtnt_laptop age1yw5pd3kn7ss7h7zs822xweduggg6fr9l3cw3366699034jkegseq0wdps7 4 | creation_rules: 5 | - path_regex: secrets/[^/]+\.(yaml|json|env|ini)$ 6 | key_groups: 7 | - age: 8 | - *suyashtnt_desktop 9 | - *suyashtnt_laptop 10 | -------------------------------------------------------------------------------- /.vscode/settings.json: -------------------------------------------------------------------------------- 1 | { 2 | "nix.enableLanguageServer": true, 3 | "nix.formatterPath": "alejandra", 4 | "nix.serverPath": "nixd", 5 | "nix.serverSettings": { 6 | // settings for 'nixd' LSP 7 | "nixd": { 8 | "formatting": { 9 | // This is the default if ommited. 10 | "command": [ 11 | "alejandra" 12 | ] 13 | }, 14 | "options": { 15 | // By default, this entriy will be read from `import { }` 16 | // You can write arbitary nix expression here, to produce valid "options" declaration result. 17 | // Tip: for flake-based configuration, utilize `builtins.getFlake` 18 | "nixos": { 19 | "expr": "(builtins.getFlake \"/home/tntman/commafiles\").debug.config.flake.nixosConfigurations.GAMER-PC.options" 20 | }, 21 | "home-manager": { 22 | "expr": "(builtins.getFlake \"/home/tntman/commafiles\").debug.config.flake.homeConfigurations.\"tntman@GAMER-PC\".options" 23 | }, 24 | // For flake-parts opitons. 25 | // Firstly read the docs here to enable "debugging", exposing declarations for nixd. 26 | // https://flake.parts/debug 27 | "flake-parts": { 28 | "expr": "(builtins.getFlake \"/home/tntman/commafiles\").debug.options" 29 | }, 30 | // For a `perSystem` flake-parts option: 31 | "flake-parts2": { 32 | "expr": "(builtins.getFlake \"/home/tntman/commafiles\").currentSystem.options" 33 | } 34 | } 35 | } 36 | } 37 | } 38 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | MIT License 2 | 3 | Copyright (c) 2023 TNTMan1671 4 | 5 | Permission is hereby granted, free of charge, to any person obtaining a copy 6 | of this software and associated documentation files (the "Software"), to deal 7 | in the Software without restriction, including without limitation the rights 8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell 9 | copies of the Software, and to permit persons to whom the Software is 10 | furnished to do so, subject to the following conditions: 11 | 12 | The above copyright notice and this permission notice shall be included in all 13 | copies or substantial portions of the Software. 14 | 15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR 16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, 17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE 18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER 19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, 20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE 21 | SOFTWARE. 22 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Commafiles 2 | 3 | My new dots, since my old ones broke 4 | 5 | ## Niri 6 | ![image](https://github.com/Suyashtnt/commafiles/assets/45307955/3ca34aec-1225-44b1-b214-181437b13bb3) 7 | ![image](https://github.com/Suyashtnt/commafiles/assets/45307955/e7e03dc5-79fb-4a83-9fb7-8ebeb8805adf) 8 | 9 | 10 | 11 | 12 | ## Hyprland 13 | Unused because I kinda don't like hyprland anymore lol 14 | 15 | ![image](https://github.com/Suyashtnt/commafiles/assets/45307955/73f4c9f8-6fa3-4b5f-928a-28ed8435b707) 16 | -------------------------------------------------------------------------------- /_sources/generated.json: -------------------------------------------------------------------------------- 1 | { 2 | "fennel-ls": { 3 | "cargoLocks": null, 4 | "date": "2024-10-11", 5 | "extract": null, 6 | "name": "fennel-ls", 7 | "passthru": null, 8 | "pinned": false, 9 | "src": { 10 | "deepClone": false, 11 | "fetchSubmodules": false, 12 | "leaveDotGit": false, 13 | "name": null, 14 | "rev": "ea46f368bea4c749eb11399d8c6abf6305925bde", 15 | "sha256": "sha256-T9rl759olIFeeqaCe7KFKe9p2iZRSp88kWAlJIcXw4w=", 16 | "sparseCheckout": [], 17 | "type": "git", 18 | "url": "https://git.sr.ht/~xerool/fennel-ls" 19 | }, 20 | "version": "ea46f368bea4c749eb11399d8c6abf6305925bde" 21 | } 22 | } -------------------------------------------------------------------------------- /_sources/generated.nix: -------------------------------------------------------------------------------- 1 | # This file was generated by nvfetcher, please do not modify it manually. 2 | { fetchgit, fetchurl, fetchFromGitHub, dockerTools }: 3 | { 4 | fennel-ls = { 5 | pname = "fennel-ls"; 6 | version = "ea46f368bea4c749eb11399d8c6abf6305925bde"; 7 | src = fetchgit { 8 | url = "https://git.sr.ht/~xerool/fennel-ls"; 9 | rev = "ea46f368bea4c749eb11399d8c6abf6305925bde"; 10 | fetchSubmodules = false; 11 | deepClone = false; 12 | leaveDotGit = false; 13 | sparseCheckout = [ ]; 14 | sha256 = "sha256-T9rl759olIFeeqaCe7KFKe9p2iZRSp88kWAlJIcXw4w="; 15 | }; 16 | date = "2024-10-11"; 17 | }; 18 | } 19 | -------------------------------------------------------------------------------- /default.nix: -------------------------------------------------------------------------------- 1 | (import 2 | ( 3 | let lock = builtins.fromJSON (builtins.readFile ./flake.lock); in 4 | fetchTarball { 5 | url = "https://github.com/edolstra/flake-compat/archive/${lock.nodes.flake-compat.locked.rev}.tar.gz"; 6 | sha256 = lock.nodes.flake-compat.locked.narHash; 7 | } 8 | ) 9 | { src = ./.; } 10 | ).defaultNix 11 | -------------------------------------------------------------------------------- /devshell.nix: -------------------------------------------------------------------------------- 1 | {...}: { 2 | perSystem = { 3 | config, 4 | pkgs, 5 | ... 6 | }: { 7 | devShells.default = pkgs.mkShell { 8 | packages = with pkgs; [ 9 | # yaml-language-server # yaml LSP 10 | alejandra # uncomprimising nix formatter 11 | marksman # markdown LSP 12 | nixd # nix LSP 13 | # nodejs 14 | # nodePackages.typescript-language-server # typescript LSP for ags autocomplete 15 | sops 16 | ]; 17 | }; 18 | }; 19 | } 20 | -------------------------------------------------------------------------------- /flake.nix: -------------------------------------------------------------------------------- 1 | { 2 | description = "Suya's (maybe) good dotfiles"; 3 | 4 | inputs = { 5 | nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable"; 6 | 7 | home-manager = { 8 | url = "github:nix-community/home-manager"; 9 | inputs.nixpkgs.follows = "nixpkgs"; 10 | }; 11 | 12 | flake-parts = { 13 | url = "github:hercules-ci/flake-parts"; 14 | inputs.nixpkgs-lib.follows = "nixpkgs"; 15 | }; 16 | 17 | flake-compat = { 18 | url = "github:inclyc/flake-compat"; 19 | flake = false; 20 | }; 21 | 22 | lix-module = { 23 | url = "https://git.lix.systems/lix-project/nixos-module/archive/2.92.0.tar.gz"; 24 | inputs.nixpkgs.follows = "nixpkgs"; 25 | }; 26 | 27 | lanzaboote = { 28 | url = "github:nix-community/lanzaboote"; 29 | 30 | inputs = { 31 | nixpkgs.follows = "nixpkgs"; 32 | # rust-overlay.follows = "rust-overlay"; 33 | flake-parts.follows = "flake-parts"; 34 | # crane.follows = "crane"; 35 | flake-compat.follows = "flake-compat"; 36 | }; 37 | }; 38 | 39 | astal = { 40 | url = "github:aylur/astal"; 41 | inputs.nixpkgs.follows = "nixpkgs"; 42 | }; 43 | 44 | # copilot-mode-src = { 45 | # url = "github:zerolfx/copilot.el"; 46 | # flake = false; 47 | # }; 48 | 49 | # crane = { 50 | # url = "github:ipetkov/crane"; 51 | # inputs.nixpkgs.follows = "nixpkgs"; 52 | # }; 53 | 54 | # emacs-overlay = { 55 | # url = "github:nix-community/emacs-overlay"; 56 | # inputs.nixpkgs.follows = "nixpkgs"; 57 | # }; 58 | 59 | # eww = { 60 | # url = "github:elkowar/eww"; 61 | # inputs.nixpkgs.follows = "nixpkgs"; 62 | # inputs.rust-overlay.follows = "rust-overlay"; 63 | # }; 64 | 65 | ez-configs = { 66 | url = "github:ehllie/ez-configs"; 67 | 68 | inputs = { 69 | nixpkgs.follows = "nixpkgs"; 70 | flake-parts.follows = "flake-parts"; 71 | }; 72 | }; 73 | 74 | # helix = { 75 | # url = "github:helix-editor/helix"; 76 | # inputs.nixpkgs.follows = "nixpkgs"; 77 | # }; 78 | 79 | # hyprland = { 80 | # url = "github:hyprwm/Hyprland"; 81 | # inputs.nixpkgs.follows = "nixpkgs"; 82 | # }; 83 | 84 | kleur = { 85 | url = "github:Suya1671/kleur"; 86 | inputs.nixpkgs.follows = "nixpkgs"; 87 | }; 88 | 89 | # neovide-src = { 90 | # url = "github:neovide/neovide"; 91 | # flake = false; 92 | # }; 93 | 94 | # neovim-nightly-overlay.url = "github:nix-community/neovim-nightly-overlay"; 95 | 96 | # doom-emacs = { 97 | # url = "github:doomemacs/doomemacs"; 98 | # flake = false; 99 | # }; 100 | 101 | niri = { 102 | url = "github:sodiboo/niri-flake"; 103 | 104 | inputs = { 105 | nixpkgs.follows = "nixpkgs"; 106 | }; 107 | }; 108 | 109 | nixos-hardware.url = "github:NixOS/nixos-hardware"; 110 | 111 | nixpkgs-f2k = { 112 | url = "github:fortuneteller2k/nixpkgs-f2k"; 113 | inputs.nixpkgs.follows = "nixpkgs"; 114 | }; 115 | 116 | nix-index-database = { 117 | url = "github:nix-community/nix-index-database"; 118 | inputs.nixpkgs.follows = "nixpkgs"; 119 | }; 120 | 121 | # rust-overlay = { 122 | # url = "github:oxalica/rust-overlay"; 123 | # inputs.nixpkgs.follows = "nixpkgs"; 124 | # }; 125 | 126 | sops-nix = { 127 | url = "github:Mic92/sops-nix"; 128 | inputs.nixpkgs.follows = "nixpkgs"; 129 | }; 130 | 131 | # spotify-player-src = { 132 | # url = "github:aome510/spotify-player"; 133 | # flake = false; 134 | # }; 135 | 136 | stylix = { 137 | url = "github:danth/stylix"; 138 | inputs.nixpkgs.follows = "nixpkgs"; 139 | inputs.home-manager.follows = "home-manager"; 140 | }; 141 | 142 | # typst-mode-src = { 143 | # url = "github:Ziqi-Yang/typst-mode.el"; 144 | # flake = false; 145 | # }; 146 | 147 | # xdg-desktop-portal-hyprland = { 148 | # url = "github:hyprwm/xdg-desktop-portal-hyprland"; 149 | # inputs.nixpkgs.follows = "nixpkgs"; 150 | # }; 151 | 152 | zen-browser = { 153 | url = "github:0xc000022070/zen-browser-flake"; 154 | inputs.nixpkgs.follows = "nixpkgs"; 155 | }; 156 | }; 157 | 158 | outputs = inputs @ {self, ...}: 159 | inputs.flake-parts.lib.mkFlake {inherit inputs;} { 160 | systems = ["x86_64-linux" "aarch64-linux"]; 161 | 162 | debug = true; 163 | 164 | imports = [ 165 | inputs.ez-configs.flakeModule 166 | ./devshell.nix 167 | ./pkgs 168 | ./pkgs/overlay.nix 169 | ./systems 170 | ./users 171 | ]; 172 | 173 | ezConfigs = { 174 | root = ./.; 175 | 176 | globalArgs = { 177 | inherit inputs; 178 | inherit (self) packages; 179 | wallpapers = ./wallpapers; 180 | secrets = ./secrets; 181 | flakeOverlays = self.overlays; 182 | }; 183 | }; 184 | }; 185 | } 186 | -------------------------------------------------------------------------------- /lut.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Suya1671/commafiles/386603e0af2253d673f5299952eeaee37493b644/lut.png -------------------------------------------------------------------------------- /nvfetcher.toml: -------------------------------------------------------------------------------- 1 | [fennel-ls] 2 | src.git = "https://git.sr.ht/~xerool/fennel-ls" 3 | fetch.git = "https://git.sr.ht/~xerool/fennel-ls" 4 | -------------------------------------------------------------------------------- /pkgs/default.nix: -------------------------------------------------------------------------------- 1 | {config, ...}: { 2 | perSystem = { 3 | self', 4 | pkgs, 5 | ... 6 | }: { 7 | packages = let 8 | getPackage = pname: (pkgs.callPackage ../_sources/generated.nix {}).${pname}; 9 | in { 10 | fennel-ls = pkgs.callPackage ./fennel-ls { 11 | inherit (getPackage "fennel-ls") src version pname; 12 | }; 13 | firefox-pwa = pkgs.callPackage ./firepwa {}; 14 | }; 15 | }; 16 | } 17 | -------------------------------------------------------------------------------- /pkgs/fennel-ls/default.nix: -------------------------------------------------------------------------------- 1 | { 2 | stdenv, 3 | luajit, 4 | fennel, 5 | src, 6 | version, 7 | pname, 8 | ... 9 | }: 10 | stdenv.mkDerivation { 11 | inherit src version pname; 12 | 13 | nativeBuildInputs = [ 14 | luajit 15 | fennel 16 | ]; 17 | 18 | installPhase = '' 19 | DESTDIR=$out PREFIX=$out make install 20 | install -Dm755 fennel-ls $out/bin/fennel-ls 21 | ''; 22 | } 23 | -------------------------------------------------------------------------------- /pkgs/firepwa/default.nix: -------------------------------------------------------------------------------- 1 | # credits to Camille Mondon @ https://github.com/NixOS/nixpkgs/pull/263404. MIT License 2 | { lib 3 | , rustPlatform 4 | , fetchFromGitHub 5 | , makeWrapper 6 | , pkg-config 7 | , installShellFiles 8 | , firefox-unwrapped 9 | , openssl 10 | , stdenv 11 | , udev 12 | , libva 13 | , mesa 14 | , libnotify 15 | , xorg 16 | , cups 17 | , pciutils 18 | , libcanberra-gtk3 19 | , extraLibs ? [ ] 20 | , nixosTests 21 | }: 22 | 23 | rustPlatform.buildRustPackage rec { 24 | pname = "firefoxpwa"; 25 | version = "2.10.1"; 26 | 27 | src = fetchFromGitHub { 28 | owner = "filips123"; 29 | repo = "PWAsForFirefox"; 30 | rev = "v${version}"; 31 | hash = "sha256-ART/GrJTmGzyUlG9ohEEVNJeaWFrYnnGO9q0nf12hyc="; 32 | }; 33 | 34 | sourceRoot = "${src.name}/native"; 35 | buildFeatures = [ "immutable-runtime" ]; 36 | 37 | cargoLock = { 38 | lockFile = ./Cargo.lock; 39 | outputHashes = { 40 | "mime-0.4.0-a.0" = "sha256-LjM7LH6rL3moCKxVsA+RUL9lfnvY31IrqHa9pDIAZNE="; 41 | "web_app_manifest-0.0.0" = "sha256-G+kRN8AEmAY1TxykhLmgoX8TG8y2lrv7SCRJlNy0QzA="; 42 | }; 43 | }; 44 | 45 | preConfigure = '' 46 | sed -i 's;version = "0.0.0";version = "${version}";' Cargo.toml 47 | sed -zi 's;name = "firefoxpwa"\nversion = "0.0.0";name = "firefoxpwa"\nversion = "${version}";' Cargo.lock 48 | sed -i $'s;DISTRIBUTION_VERSION = \'0.0.0\';DISTRIBUTION_VERSION = \'${version}\';' userchrome/profile/chrome/pwa/chrome.jsm 49 | ''; 50 | 51 | nativeBuildInputs = [ makeWrapper pkg-config installShellFiles ]; 52 | buildInputs = [ openssl ]; 53 | 54 | FFPWA_EXECUTABLES = ""; # .desktop entries generated without any store path references 55 | FFPWA_SYSDATA = "${placeholder "out"}/share/firefoxpwa"; 56 | completions = "target/${stdenv.targetPlatform.config}/release/completions"; 57 | 58 | gtk_modules = map (x: x + x.gtkModule) [ libcanberra-gtk3 ]; 59 | libs = let libs = lib.optionals stdenv.isLinux [ udev libva mesa libnotify xorg.libXScrnSaver cups pciutils ] ++ gtk_modules ++ extraLibs; in lib.makeLibraryPath libs + ":" + lib.makeSearchPathOutput "lib" "lib64" libs; 60 | 61 | postInstall = '' 62 | # Runtime 63 | mkdir -p $out/share/firefoxpwa 64 | cp -Lr ${firefox-unwrapped}/lib/firefox $out/share/firefoxpwa/runtime 65 | chmod -R +w $out/share/firefoxpwa 66 | 67 | # UserChrome 68 | cp -r userchrome $out/share/firefoxpwa 69 | 70 | # Runtime patching 71 | FFPWA_USERDATA=$out/share/firefoxpwa $out/bin/firefoxpwa runtime patch 72 | 73 | # Manifest 74 | sed -i "s!/usr/libexec!$out/bin!" manifests/linux.json 75 | install -Dm644 manifests/linux.json $out/lib/mozilla/native-messaging-hosts/firefoxpwa.json 76 | 77 | installShellCompletion --cmd firefoxpwa \ 78 | --bash $completions/firefoxpwa.bash \ 79 | --fish $completions/firefoxpwa.fish \ 80 | --zsh $completions/_firefoxpwa 81 | 82 | # AppStream Metadata 83 | install -Dm644 packages/appstream/si.filips.FirefoxPWA.metainfo.xml $out/share/metainfo/si.filips.FirefoxPWA.metainfo.xml 84 | install -Dm644 packages/appstream/si.filips.FirefoxPWA.svg $out/share/icons/hicolor/scalable/apps/si.filips.FirefoxPWA.svg 85 | 86 | wrapProgram $out/bin/firefoxpwa \ 87 | --prefix FFPWA_SYSDATA : "$out/share/firefoxpwa" \ 88 | --prefix LD_LIBRARY_PATH : "$libs" \ 89 | --suffix-each GTK_PATH : "$gtk_modules" 90 | 91 | wrapProgram $out/bin/firefoxpwa-connector \ 92 | --prefix FFPWA_SYSDATA : "$out/share/firefoxpwa" \ 93 | --prefix LD_LIBRARY_PATH : "$libs" \ 94 | --suffix-each GTK_PATH : "$gtk_modules" 95 | ''; 96 | 97 | passthru.tests.firefoxpwa = nixosTests.firefoxpwa; 98 | 99 | meta = with lib; { 100 | description = "A tool to install, manage and use Progressive Web Apps (PWAs) in Mozilla Firefox (native component)"; 101 | longDescription = '' 102 | Progressive Web Apps (PWAs) are web apps that use web APIs and features along 103 | with progressive enhancement strategy to bring a native app-like user experience 104 | to cross-platform web applications. Although Firefox supports many of Progressive 105 | Web App APIs, it does not support functionality to install them as a standalone 106 | system app with an app-like experience. 107 | 108 | This project creates a custom modified Firefox runtime to allow websites to be 109 | installed as standalone apps and provides a console tool and browser extension 110 | to install, manage and use them. 111 | 112 | This package contains only the native part of the PWAsForFirefox project. You 113 | should also install the browser extension if you haven't already. You can download 114 | it from the [Firefox Add-ons](https://addons.mozilla.org/firefox/addon/pwas-for-firefox/) 115 | website. 116 | 117 | To install the package on NixOS, you need to add the following options: 118 | 119 | ``` 120 | programs.firefox.nativeMessagingHosts.packages = [ pkgs.firefoxpwa ]; 121 | environment.systemPackages = [ pkgs.firefoxpwa ]; 122 | ``` 123 | 124 | As it needs to be both in the `PATH` and in the `nativeMessagingHosts` to make it 125 | possible for the extension to detect and use it. 126 | ''; 127 | homepage = "https://pwasforfirefox.filips.si/"; 128 | changelog = "https://github.com/filips123/PWAsForFirefox/releases/tag/v${version}"; 129 | license = licenses.mpl20; 130 | platforms = platforms.unix; 131 | maintainers = with maintainers; [ camillemndn pasqui23 ]; 132 | mainProgram = "firefoxpwa"; 133 | }; 134 | } 135 | -------------------------------------------------------------------------------- /pkgs/logseq.nix: -------------------------------------------------------------------------------- 1 | { 2 | zulu11, 3 | clojure, 4 | nodejs_20, 5 | babashka, 6 | src, 7 | version, 8 | pname, 9 | mkYarnPackage, 10 | mk-deps-cache, 11 | ... 12 | }: 13 | mkYarnPackage rec { 14 | inherit src version pname; 15 | 16 | packageJSON = "${src}/package.json"; 17 | yarnLock = "${src}/yarn.lock"; 18 | 19 | nativeBuildInputs = [ 20 | zulu11 21 | clojure 22 | nodejs_20 23 | babashka 24 | ]; 25 | 26 | buildInputs = [ 27 | electron_31 28 | ]; 29 | 30 | yarnOfflineCache = fetchYarnDeps { 31 | yarnLock = "${src}/yarn.lock"; 32 | }; 33 | 34 | staticCache = fetchYarnDeps { 35 | yarnLock = "${src}/static/yarn.lock"; 36 | }; 37 | 38 | clojureCache = mk-deps-cache { 39 | lockfile = 40 | } 41 | 42 | installPhase = '' 43 | DESTDIR=$out PREFIX=$out make install 44 | install -Dm755 fennel-ls $out/bin/fennel-ls 45 | ''; 46 | } 47 | -------------------------------------------------------------------------------- /pkgs/overlay.nix: -------------------------------------------------------------------------------- 1 | {inputs, ...}: { 2 | imports = [ 3 | inputs.flake-parts.flakeModules.easyOverlay 4 | ]; 5 | perSystem = { config, pkgs, final, ... }: { 6 | overlayAttrs = { 7 | inherit (config.packages) fennel-ls firefox-pwa; 8 | }; 9 | }; 10 | } 11 | -------------------------------------------------------------------------------- /secrets/secrets.json: -------------------------------------------------------------------------------- 1 | { 2 | "lastfm": { 3 | "key": "ENC[AES256_GCM,data:COGGWOvpL7638Yuh3VxYE6MpjTRGWD2etnKxZsh+puM=,iv:i8KoriWnzNcj/GCS0TAzJIdCW/ZxvepJ1TI7XrU1Uik=,tag:v3FcToldJQnGFYKbBSbxLw==,type:str]", 4 | "secret": "ENC[AES256_GCM,data:4ziCqnY0Rv6QMcwMbTTv9axi6H5VPdubcKEGVa0p1t8=,iv:ICOsLlzso4fj6Kw+lpPL0e27XogUdePPqvPCCwtvdzA=,tag:FzW3FXsH3F/pIzBVPPoXYA==,type:str]" 5 | }, 6 | "spotify": { 7 | "id": "ENC[AES256_GCM,data:jFCSXVIWBikXKx5jZYq7nDFdnrBXI9xXDgpQZcX8YZ0=,iv:NNtbAIsEK4KvjzLoc8STCdhH1s10n+6TtHFodwluWT0=,tag:JVR6tHqtRZgjZ+hNCQBP3Q==,type:str]", 8 | "secret": "ENC[AES256_GCM,data:ZOXTFa+WbRaoyzquhNkvBd+ubdxOuUZinZmLqMdPh2U=,iv:PjUkagCuB6CSfVMt6HvhbVtcLVJpvEy8sCTuJNkVkl0=,tag:YORYbVR7QBbBf0r/McITSQ==,type:str]" 9 | }, 10 | "copilot": { 11 | "key": "ENC[AES256_GCM,data:LSdSklWu0Ht1yLXeQGrLACN5UuxsQBDQfq+/MbfCVjW6SlJt3O/LSw==,iv:dk5Vt7t2hgJe+IrjHr8rUjAB/xNT1RHYdPnJWxUSqWM=,tag:KeXOGRzEKSsDiKIobpLVlg==,type:str]" 12 | }, 13 | "cloudflared": { 14 | "tau": "ENC[AES256_GCM,data:xqbvWDoeMNjfxvmPdzXO6Q6BOnRtkfkBbTc/J4C71x668MyOr2X4HAKEodPV3nlwwg4kvAZfOTWJE/UCGJp7J5bkN1jf+oDPOK4LLJfhyBdZnEVFuw6snOW+Qf82s78s9mAf6fVLTahBM0mzlt9nruI30LcjM19hHuEJ7wSlsG9M/8pWr5Mful3+g+h1TaebSXLvM+9wpWAb7eCbxM/9ImA=,iv:Hqlcjk7gZ7Ja2Aorbp9J1YjuZJxtOhTaBpT9ga+JAGQ=,tag:7CZjyP1Sh3IQpzWXsr8pcg==,type:str]", 15 | "gamer-pc": "ENC[AES256_GCM,data:TZzJqH3HKb+/+gFNMHhUz0UFDa7hgIENRr4hX1lQ0nE3GIFzk3Njg13cuab0wE+QDGGKxcZdfigZLYa2x1OZbzKjKlmN50TDR3TZb2zIrsGKWiSJTzvM5hOkNWfAzYgOSMdwdr8DTgclLkf7X+7XGbap4Y5CzNCWLOOsVGf0LNRWQDZbG8rGDbJmziXuy5JC9RvEKy6H9cSz0hTrXIDIpOA=,iv:+euGrClu2YTOYJ4PFowoo4WhERvF4XWbTEn6Rc72GJg=,tag:4T2oKQT8WZomnw5s053v0g==,type:str]" 16 | }, 17 | "sops": { 18 | "kms": null, 19 | "gcp_kms": null, 20 | "azure_kv": null, 21 | "hc_vault": null, 22 | "age": [ 23 | { 24 | "recipient": "age1wc2azunqm69j6uwdfrtw6z2td7me2qmqf5rfndwke2mner5g94nsc0j2ns", 25 | "enc": "-----BEGIN AGE ENCRYPTED FILE-----\nYWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSBtVHlDR1Vzbm8zTmtvcDAw\nb0pQeVBnbUIvUmp6aFhyUVhLWFFqVTB6Mmw0CnNXbDdZb1ZaQVF1cFg5QXphN3hs\nT0JFWmZ4c1hJQUpsUms1aG1WamJDYnMKLS0tIG1TUjJqOWI1SnV4K29kVk9YeXdX\nM1M4bHJUN1U1V3ZheVNmRW5KTGI3MDAKDn32/GRHUSFYyXYfgKom6hchRSnGfOea\nzXi05Uh5nx/XIl8zaiCwl9QEE5lFiuCwkt2e/hiCJKVK4CU+gIjcpA==\n-----END AGE ENCRYPTED FILE-----\n" 26 | }, 27 | { 28 | "recipient": "age1yw5pd3kn7ss7h7zs822xweduggg6fr9l3cw3366699034jkegseq0wdps7", 29 | "enc": "-----BEGIN AGE ENCRYPTED FILE-----\nYWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSBhbDgxWnFFeVg5OFRQZnAr\nVURXeWovUGhxM3cvZml5K3BjcDNwSDFLQlhVCmI1VVEvOE85K04xbVJRdEthWDhm\nUWZBZ2RkQUpoQzF4U0JtUFJ4MTlYd3cKLS0tIDdieXg3bmhUZjdwUllueTc2bC9n\nVXF3UVU0UDkzV0ZSSFV6bFB3TW56YVEKYCgIlatZVCSxEmpJMfDxZzow7VXCxlqf\nWw3GFTrV3Mb1XLsrfXKcz4Nk8vtMHjS4bza6tK3GaYq2N+o26EQ0Mw==\n-----END AGE ENCRYPTED FILE-----\n" 30 | } 31 | ], 32 | "lastmodified": "2025-01-10T16:52:38Z", 33 | "mac": "ENC[AES256_GCM,data:NufGNeVRSX+x+mfl4xp/UxMpIJgvgc37zX8qc6P93CfPvsqa8/GfAExQh1WHF7yCld5cOJq/49uc8D4rUFWG3tDgmICpvhM5IcPwS1eEoTWgt1p8Wy+9qAAh85NpkM6jOwrG4E9haNRJXqS2FOOPxComxBVUgC0FcgvtPTxKv+w=,iv:2NCEm9i/T7FZsETGDd36WBYXF8xxznh67lU2wcg26bo=,tag:UoceYojLmhSPPOjeCEprJw==,type:str]", 34 | "pgp": null, 35 | "unencrypted_suffix": "_unencrypted", 36 | "version": "3.9.2" 37 | } 38 | } -------------------------------------------------------------------------------- /systems/EVIL-LAPTOP/config.nix: -------------------------------------------------------------------------------- 1 | {pkgs, ...}: { 2 | networking.hostName = "EVIL-LAPTOP"; 3 | 4 | boot = { 5 | loader.grub.enable = true; 6 | }; 7 | 8 | # Set your time zone. 9 | time.timeZone = "Africa/Johannesburg"; 10 | i18n.defaultLocale = "en_US.UTF-8"; 11 | 12 | # Configure keymap in X11 13 | services.xserver.xkb = { 14 | layout = "us"; 15 | }; 16 | 17 | # Enable touchpad support (enabled default in most desktopManager). 18 | services.libinput.enable = true; 19 | 20 | # Define a user account. Don't forget to set a password with ‘passwd’. 21 | users.users.tntman = { 22 | isNormalUser = true; 23 | description = "Suyash"; 24 | extraGroups = ["networkmanager" "wheel" "scanner" "lp" "docker"]; 25 | packages = with pkgs; [ 26 | firefox 27 | ]; 28 | shell = pkgs.nushell; 29 | }; 30 | 31 | environment.systemPackages = with pkgs; [ 32 | vim 33 | helix 34 | ]; 35 | 36 | services = { 37 | usbmuxd.enable = true; 38 | avahi.enable = true; 39 | avahi.nssmdns4 = true; 40 | flatpak.enable = true; 41 | openssh.enable = true; 42 | gvfs.enable = true; 43 | }; 44 | 45 | services.upower.enable = true; 46 | 47 | # This value determines the NixOS release from which the default 48 | # settings for stateful data, like file locations and database versions 49 | # on your system were taken. It‘s perfectly fine and recommended to leave 50 | # this value at the release version of the first install of this system. 51 | # Before changing this value read the documentation for this option 52 | # (e.g. man configuration.nix or on https://nixos.org/nixos/options.html). 53 | system.stateVersion = "23.11"; # Did you read the comment? 54 | } 55 | -------------------------------------------------------------------------------- /systems/EVIL-LAPTOP/default.nix: -------------------------------------------------------------------------------- 1 | { 2 | ezModules, 3 | inputs, 4 | ... 5 | }: { 6 | imports = [ 7 | inputs.home-manager.nixosModules.default 8 | inputs.stylix.nixosModules.stylix 9 | 10 | ezModules.bluetooth 11 | ezModules.core 12 | ezModules.laptop 13 | ezModules.intel 14 | ezModules.ld 15 | ezModules.printing 16 | ezModules.wayland 17 | ezModules.niri 18 | ezModules.greetd 19 | ezModules.sops 20 | ezModules.niri 21 | 22 | ezModules.theme 23 | ezModules.kleur 24 | 25 | ./config.nix 26 | ./hardware.nix 27 | ]; 28 | } 29 | -------------------------------------------------------------------------------- /systems/EVIL-LAPTOP/hardware.nix: -------------------------------------------------------------------------------- 1 | # Do not modify this file! It was generated by ‘nixos-generate-config’ 2 | # and may be overwritten by future invocations. Please make changes 3 | # to /etc/nixos/configuration.nix instead. 4 | { config, lib, pkgs, modulesPath, ... }: 5 | 6 | { 7 | imports = 8 | [ (modulesPath + "/installer/scan/not-detected.nix") 9 | ]; 10 | 11 | boot.initrd.availableKernelModules = [ "vmd" "xhci_pci" "ahci" "nvme" "usb_storage" "sd_mod" ]; 12 | boot.initrd.kernelModules = [ ]; 13 | boot.kernelModules = [ "kvm-intel" ]; 14 | boot.extraModulePackages = [ ]; 15 | 16 | fileSystems."/" = 17 | { device = "/dev/disk/by-uuid/9d955180-5dae-4615-85d1-522434940dfb"; 18 | fsType = "ext4"; 19 | }; 20 | 21 | fileSystems."/boot" = 22 | { device = "/dev/disk/by-uuid/2856-A110"; 23 | fsType = "vfat"; 24 | options = [ "fmask=0022" "dmask=0022" ]; 25 | }; 26 | 27 | swapDevices = [ ]; 28 | 29 | # Enables DHCP on each ethernet and wireless interface. In case of scripted networking 30 | # (the default) this is the recommended approach. When using systemd-networkd it's 31 | # still possible to use this option, but it's recommended to use it in conjunction 32 | # with explicit per-interface declarations with `networking.interfaces..useDHCP`. 33 | networking.useDHCP = lib.mkDefault true; 34 | # networking.interfaces.enp1s0.useDHCP = lib.mkDefault true; 35 | # networking.interfaces.wlp0s20f3.useDHCP = lib.mkDefault true; 36 | 37 | nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux"; 38 | hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware; 39 | } 40 | -------------------------------------------------------------------------------- /systems/GAMER-PC/config.nix: -------------------------------------------------------------------------------- 1 | {pkgs, inputs, config, ...}: { 2 | users.users.tntman = { 3 | isNormalUser = true; 4 | description = "Tabiasgeee Human"; 5 | extraGroups = ["networkmanager" "wheel" "scanner" "lp" "docker" "dialout"]; 6 | initialPassword = "password"; # Change this with passwd 7 | shell = pkgs.fish; 8 | }; 9 | nixpkgs.hostPlatform = "x86_64-linux"; 10 | 11 | imports = [inputs.lanzaboote.nixosModules.lanzaboote]; 12 | 13 | boot = { 14 | lanzaboote = { 15 | enable = false; 16 | pkiBundle = "/etc/secureboot"; 17 | }; 18 | }; 19 | 20 | networking.hostName = "GAMER-PC"; 21 | hardware.nvidia-container-toolkit.enable = true; 22 | 23 | time.timeZone = "Africa/Johannesburg"; 24 | i18n.defaultLocale = "en_ZA.UTF-8"; 25 | 26 | services = { 27 | xserver = { 28 | xkb = { 29 | layout = "za"; 30 | }; 31 | }; 32 | 33 | gnome = { 34 | glib-networking.enable = true; 35 | }; 36 | 37 | openssh = { 38 | enable = true; 39 | # require public key authentication for better security 40 | settings.PasswordAuthentication = false; 41 | settings.KbdInteractiveAuthentication = false; 42 | #settings.PermitRootLogin = "yes"; 43 | }; 44 | 45 | # cloudflared 46 | cloudflared = { 47 | enable = true; 48 | tunnels = { 49 | "ca4db441-b264-4db7-aa4e-cf59764d73c5" = { 50 | credentialsFile = "${config.sops.secrets."cloudflared/gamer-pc".path}"; 51 | default = "http_status:404"; 52 | }; 53 | }; 54 | }; 55 | 56 | jellyfin.enable = true; 57 | usbmuxd.enable = true; 58 | avahi.enable = true; 59 | avahi.nssmdns4 = true; 60 | flatpak.enable = true; 61 | gvfs.enable = true; 62 | teamviewer.enable = true; # Being school tech support moment 63 | telepathy.enable = true; 64 | }; 65 | 66 | programs.dconf.enable = true; 67 | programs.wshowkeys.enable = true; 68 | programs.fish.enable = true; 69 | 70 | virtualisation = { 71 | podman = { 72 | enable = true; 73 | dockerCompat = true; 74 | defaultNetwork.settings.dns_enabled = true; 75 | }; 76 | }; 77 | 78 | environment.systemPackages = with pkgs; [ 79 | vim # backup editor 80 | libimobiledevice 81 | adwaita-icon-theme 82 | cloudflared 83 | ifuse 84 | virt-manager 85 | xdg-desktop-portal-gtk 86 | sbctl 87 | ]; 88 | 89 | sops.secrets."cloudflared/gamer-pc" = { 90 | # Both are "cloudflared" by default 91 | owner = config.services.cloudflared.user; 92 | group = config.services.cloudflared.group; 93 | }; 94 | } 95 | -------------------------------------------------------------------------------- /systems/GAMER-PC/default.nix: -------------------------------------------------------------------------------- 1 | { 2 | ezModules, 3 | inputs, 4 | ... 5 | }: { 6 | imports = [ 7 | inputs.home-manager.nixosModules.default 8 | inputs.stylix.nixosModules.stylix 9 | inputs.lix-module.nixosModules.default 10 | 11 | ezModules.core 12 | ezModules.intel 13 | ezModules.nvidia 14 | ezModules.sops 15 | ezModules.ld 16 | ezModules.printing 17 | ezModules.wayland 18 | ezModules.greetd 19 | ezModules.geoclue 20 | ezModules.niri 21 | ezModules.openrgb 22 | ezModules.tablet 23 | # ezModules.steam 24 | # ezModules.sunshine 25 | 26 | ezModules.theme 27 | ezModules.kleur 28 | 29 | ./config.nix 30 | ./hardware.nix 31 | ]; 32 | 33 | sops.secrets."copilot/key" = { 34 | owner = "tntman"; 35 | }; 36 | } 37 | -------------------------------------------------------------------------------- /systems/GAMER-PC/hardware.nix: -------------------------------------------------------------------------------- 1 | # Do not modify this file! It was generated by ‘nixos-generate-config’ 2 | # and may be overwritten by future invocations. Please make changes 3 | # to /etc/nixos/configuration.nix instead. 4 | { 5 | config, 6 | lib, 7 | modulesPath, 8 | ... 9 | }: { 10 | imports = [ 11 | (modulesPath + "/installer/scan/not-detected.nix") 12 | ]; 13 | 14 | boot = { 15 | initrd = { 16 | availableKernelModules = ["xhci_pci" "ahci" "nvme" "usbhid" "usb_storage" "sd_mod"]; 17 | kernelModules = []; 18 | }; 19 | kernelModules = ["kvm-intel" "v4l2loopback" "snd-aloop"]; 20 | extraModulePackages = [ config.boot.kernelPackages.v4l2loopback.out ]; 21 | supportedFilesystems = ["ntfs"]; 22 | extraModprobeConfig = '' 23 | # exclusive_caps: Skype, Zoom, Teams etc. will only show device when actually streaming 24 | # card_label: Name of virtual camera, how it'll show up in Skype, Zoom, Teams 25 | # https://github.com/umlaeute/v4l2loopback 26 | options v4l2loopback exclusive_caps=1 card_label="Virtual Camera" 27 | ''; 28 | binfmt = { 29 | emulatedSystems = ["aarch64-linux"]; 30 | 31 | registrations."aarch64-linux" = { 32 | preserveArgvZero = true; 33 | matchCredentials = true; 34 | fixBinary = true; 35 | }; 36 | }; 37 | }; 38 | 39 | fileSystems."/" = { 40 | device = "/dev/disk/by-uuid/2cd284bd-f0a1-48bc-868e-be3def467995"; 41 | fsType = "ext4"; 42 | }; 43 | 44 | fileSystems."/boot/efi" = { 45 | device = "/dev/disk/by-uuid/F695-008D"; 46 | fsType = "vfat"; 47 | }; 48 | 49 | fileSystems."/mnt/BulkStorage" = 50 | { device = "/dev/disk/by-label/GAMES"; 51 | fsType = "ntfs-3g"; 52 | options = [ "rw" "uid=1000"]; 53 | }; 54 | 55 | # Enables DHCP on each ethernet and wireless interface. In case of scripted networking 56 | # (the default) this is the recommended approach. When using systemd-networkd it's 57 | # still possible to use this option, but it's recommended to use it in conjunction 58 | # with explicit per-interface declarations with `networking.interfaces..useDHCP`. 59 | networking.useDHCP = lib.mkDefault true; 60 | # networking.interfaces.eno1.useDHCP = lib.mkDefault true; 61 | 62 | hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware; 63 | } 64 | -------------------------------------------------------------------------------- /systems/default.nix: -------------------------------------------------------------------------------- 1 | {config, ...}: { 2 | ezConfigs = { 3 | nixos = { 4 | modulesDirectory = ./modules; 5 | configurationsDirectory = ./.; 6 | 7 | hosts = { 8 | GAMER-PC = { 9 | userHomeModules = ["tntman"]; 10 | }; 11 | tau = { 12 | userHomeModules = ["tau"]; 13 | }; 14 | EVIL-LAPTOP = { 15 | userHomeModules = ["tntman"]; 16 | }; 17 | }; 18 | }; 19 | }; 20 | 21 | flake = { 22 | images = { 23 | tau = config.nixosConfigurations.tau.config.system.build.sdImage; 24 | }; 25 | }; 26 | } 27 | -------------------------------------------------------------------------------- /systems/modules/amd.nix: -------------------------------------------------------------------------------- 1 | { ... }: { 2 | boot.initrd.kernelModules = [ "amdgpu" ]; 3 | services.xserver.videoDrivers = [ "amdgpu" ]; 4 | } 5 | -------------------------------------------------------------------------------- /systems/modules/bluetooth.nix: -------------------------------------------------------------------------------- 1 | {pkgs, ...}: { 2 | services.blueman.enable = true; 3 | 4 | # for until https://github.com/NixOS/nixpkgs/pull/292115 has been merged 5 | services.pipewire.wireplumber.configPackages = [ 6 | (pkgs.writeTextDir "share/wireplumber/bluetooth.lua.d/51-bluez-config.lua" '' 7 | bluez_monitor.properties = { 8 | ["bluez5.enable-sbc-xq"] = true, 9 | ["bluez5.enable-msbc"] = true, 10 | ["bluez5.enable-hw-volume"] = true, 11 | ["bluez5.headset-roles"] = "[ hsp_hs hsp_ag hfp_hf hfp_ag ]" 12 | } 13 | '') 14 | ]; 15 | 16 | hardware = { 17 | bluetooth = { 18 | enable = true; 19 | powerOnBoot = true; 20 | settings = { 21 | General = { 22 | Enable = "Source,Sink,Media,Socket"; 23 | }; 24 | }; 25 | }; 26 | pulseaudio.package = pkgs.pulseaudioFull; 27 | pulseaudio.extraConfig = " 28 | load-module module-switch-on-connect 29 | "; 30 | }; 31 | } 32 | -------------------------------------------------------------------------------- /systems/modules/core/bootloader.nix: -------------------------------------------------------------------------------- 1 | { 2 | inputs, 3 | pkgs, 4 | lib, 5 | ... 6 | }: { 7 | boot = { 8 | loader = { 9 | systemd-boot.enable = lib.mkForce true; 10 | systemd-boot.netbootxyz.enable = true; 11 | grub = { 12 | enable = lib.mkDefault false; # enable when setting up/not securebooting 13 | efiSupport = true; 14 | device = "nodev"; 15 | useOSProber = true; 16 | }; 17 | efi = { 18 | canTouchEfiVariables = true; 19 | efiSysMountPoint = "/boot/efi"; 20 | }; 21 | }; 22 | 23 | initrd.systemd.enable = true; 24 | 25 | extraModprobeConfig = "options kvm_intel nested=1"; 26 | supportedFilesystems = ["ntfs" "mtpfs"]; 27 | 28 | kernelPackages = pkgs.linuxKernel.packages.linux_6_11; 29 | 30 | plymouth = { 31 | enable = true; 32 | }; 33 | }; 34 | } 35 | -------------------------------------------------------------------------------- /systems/modules/core/default.nix: -------------------------------------------------------------------------------- 1 | {...}: { 2 | # some things that will always be needed 3 | imports = [ 4 | ./bootloader.nix 5 | ./fonts.nix 6 | ./network.nix 7 | ./nix.nix 8 | ./opengl.nix 9 | ./security.nix 10 | ./sound.nix 11 | ./home-manager.nix 12 | ]; 13 | } 14 | -------------------------------------------------------------------------------- /systems/modules/core/fonts.nix: -------------------------------------------------------------------------------- 1 | {pkgs, ...}: { 2 | fonts = { 3 | enableDefaultPackages = true; 4 | packages = with pkgs; [ 5 | font-awesome 6 | noto-fonts 7 | noto-fonts-lgc-plus 8 | noto-fonts-cjk-sans 9 | inter 10 | emacs-all-the-icons-fonts 11 | hack-font 12 | open-sans 13 | ]; 14 | 15 | fontconfig = { 16 | defaultFonts = { 17 | sansSerif = ["Recursive Sans Linear" "Inter"]; 18 | monospace = ["ComicCodeLigatures Nerd Font" "JetBrainsMono Nerd Font"]; 19 | }; 20 | }; 21 | }; 22 | } 23 | -------------------------------------------------------------------------------- /systems/modules/core/home-manager.nix: -------------------------------------------------------------------------------- 1 | {inputs, ...}: { 2 | home-manager = { 3 | useGlobalPkgs = true; 4 | backupFileExtension = ".back"; 5 | sharedModules = [ 6 | inputs.sops-nix.homeManagerModules.sops 7 | ]; 8 | }; 9 | } 10 | -------------------------------------------------------------------------------- /systems/modules/core/network.nix: -------------------------------------------------------------------------------- 1 | {...}: { 2 | networking = { 3 | firewall = { 4 | enable = false; 5 | allowedTCPPorts = [443 80 22 631]; 6 | allowedUDPPorts = [443 80 631]; 7 | }; 8 | 9 | networkmanager.enable = true; 10 | nameservers = ["1.1.1.1" "8.8.8.8"]; 11 | }; 12 | } 13 | -------------------------------------------------------------------------------- /systems/modules/core/nix.nix: -------------------------------------------------------------------------------- 1 | { 2 | pkgs, 3 | inputs, 4 | packages, 5 | ... 6 | }: { 7 | environment.defaultPackages = []; 8 | 9 | nixpkgs.config.allowUnfree = true; 10 | nixpkgs.config.allowBroken = true; # latest kernel 11 | 12 | nixpkgs.config.permittedInsecurePackages = [ 13 | "electron-24.8.6" # obsidian 14 | ]; 15 | 16 | nixpkgs.overlays = [ 17 | inputs.nixpkgs-f2k.overlays.terminal-emulators 18 | # inputs.helix.overlays.default 19 | (final: super: { 20 | makeModulesClosure = x: 21 | super.makeModulesClosure (x // {allowMissing = true;}); 22 | 23 | inherit (packages.${pkgs.system}) firefox-pwa; 24 | }) 25 | ]; 26 | 27 | nix = { 28 | package = pkgs.lix; 29 | extraOptions = '' 30 | experimental-features = nix-command flakes 31 | ''; 32 | settings = { 33 | trusted-users = ["@wheel"]; 34 | auto-optimise-store = true; 35 | trusted-public-keys = [ 36 | "cache.nixos.org-1:6NCHdD59X431o0gWypbMrAURkbJ16ZPMQFGspcDShjY=" 37 | "cache.garnix.io:CTFPyKSLcx5RMJKfLo5EEPUObbA78b0YQ2DTCJXqr9g=" 38 | "fortuneteller2k.cachix.org-1:kXXNkMV5yheEQwT0I4XYh1MaCSz+qg72k8XAi2PthJI=" 39 | "nix-community.cachix.org-1:mB9FSh9qf2dCimDSUo8Zy7bkq5CX+/rkCWyvRCYg3Fs=" 40 | "cache.garnix.io:CTFPyKSLcx5RMJKfLo5EEPUObbA78b0YQ2DTCJXqr9g=" 41 | "niri.cachix.org-1:Wv0OmO7PsuocRKzfDoJ3mulSl7Z6oezYhGhR+3W2964=" 42 | "helix.cachix.org-1:ejp9KQpR1FBI2onstMQ34yogDm4OgU2ru6lIwPvuCVs=" 43 | "suyashtnt.cachix.org-1:8l4tu5IiSv4xm9Zz1+KfwEW7dvljcjp+kgsO/TUA6fI=" 44 | ]; 45 | substituters = [ 46 | "https://cache.nixos.org?priority=10" 47 | "https://cache.garnix.io" 48 | "https://fortuneteller2k.cachix.org" 49 | "https://nix-community.cachix.org" 50 | "https://cache.garnix.io" 51 | "https://niri.cachix.org" 52 | "https://helix.cachix.org" 53 | "https://suyashtnt.cachix.org" 54 | ]; 55 | }; 56 | }; 57 | 58 | documentation = { 59 | enable = true; 60 | man.enable = true; 61 | }; 62 | 63 | # recompile nixos 64 | programs.nh = { 65 | enable = true; 66 | clean.enable = true; 67 | }; 68 | 69 | # CD via cachix 70 | services.cachix-agent.enable = true; 71 | 72 | # This value determines the NixOS release from which the default 73 | # settings for stateful data, like file locations and database versions 74 | # on your system were taken. It‘s perfectly fine and recommended to leave 75 | # this value at the release version of the first install of this system. 76 | # Before changing this value read the documentation for this option 77 | # (e.g. man configuration.nix or on https://nixos.org/nixos/options.html). 78 | system.stateVersion = pkgs.lib.mkDefault "22.05"; # Did you read the comment? If not, TLDR don't change this 79 | } 80 | -------------------------------------------------------------------------------- /systems/modules/core/opengl.nix: -------------------------------------------------------------------------------- 1 | {pkgs, ...}: { 2 | hardware = { 3 | graphics = { 4 | enable = pkgs.lib.mkDefault true; 5 | extraPackages = with pkgs; [ 6 | intel-compute-runtime 7 | intel-media-driver 8 | vaapiIntel 9 | vaapiVdpau 10 | libvdpau-va-gl 11 | nvidia-vaapi-driver 12 | libGL 13 | ]; 14 | }; 15 | }; 16 | } 17 | -------------------------------------------------------------------------------- /systems/modules/core/security.nix: -------------------------------------------------------------------------------- 1 | {pkgs, ...}: { 2 | security.pam.loginLimits = [ 3 | # Unlimited amount of processes for root 4 | { 5 | domain = "root"; 6 | item = "nproc"; 7 | value = "unlimited"; 8 | } 9 | # Unlimited open file descriptors 10 | { 11 | domain = "*"; 12 | item = "nofile"; 13 | value = "unlimited"; 14 | } 15 | ]; 16 | 17 | security.polkit.enable = true; 18 | 19 | services.udev.packages = with pkgs; [ 20 | gnome-settings-daemon 21 | picotool 22 | ]; 23 | 24 | # add nushell to list of valid shells 25 | environment.shells = [ pkgs.nushell ]; 26 | } 27 | -------------------------------------------------------------------------------- /systems/modules/core/sound.nix: -------------------------------------------------------------------------------- 1 | {...}: { 2 | services.pipewire = { 3 | enable = true; 4 | alsa.enable = true; 5 | alsa.support32Bit = true; 6 | pulse.enable = true; 7 | 8 | jack.enable = true; 9 | }; 10 | 11 | security.rtkit.enable = true; 12 | } 13 | -------------------------------------------------------------------------------- /systems/modules/geoclue.nix: -------------------------------------------------------------------------------- 1 | {...}: { 2 | services.geoclue2 = { 3 | enable = true; 4 | submitData = true; 5 | }; 6 | } 7 | -------------------------------------------------------------------------------- /systems/modules/greetd/default.nix: -------------------------------------------------------------------------------- 1 | {wallpapers, pkgs, ...}: { 2 | programs.regreet = { 3 | enable = true; 4 | settings = { 5 | background = { 6 | path = "${wallpapers}/Orbit.png"; 7 | fit = "Cover"; 8 | }; 9 | commands = { 10 | reboot = ["systemctl" "reboot"]; 11 | poweroff = ["systemctl" "poweroff"]; 12 | }; 13 | }; 14 | }; 15 | 16 | services.greetd = { 17 | enable = true; 18 | settings = { 19 | command = "dbus-run-session cage -s -- regreet"; 20 | }; 21 | }; 22 | } 23 | -------------------------------------------------------------------------------- /systems/modules/hyprland.nix: -------------------------------------------------------------------------------- 1 | {...}: { 2 | nixpkgs.overlays = [ 3 | inputs.xdg-desktop-portal-hyprland.overlays.default 4 | ]; 5 | programs.hyprland.enable = true; 6 | } 7 | -------------------------------------------------------------------------------- /systems/modules/intel.nix: -------------------------------------------------------------------------------- 1 | {pkgs, ...}: { 2 | hardware.graphics.extraPackages = with pkgs; [ 3 | intel-compute-runtime 4 | intel-media-driver 5 | vaapiIntel 6 | vaapiVdpau 7 | libvdpau-va-gl 8 | ]; 9 | 10 | services.xserver.videoDrivers = ["intel"]; 11 | services.hardware.openrgb.motherboard = "intel"; 12 | } 13 | -------------------------------------------------------------------------------- /systems/modules/kleur.nix: -------------------------------------------------------------------------------- 1 | {inputs, pkgs, ...}: let 2 | path = inputs.kleur.themes.${pkgs.system}.dark; 3 | in { 4 | tntman.theme.base16 = path.base16; 5 | } 6 | -------------------------------------------------------------------------------- /systems/modules/laptop.nix: -------------------------------------------------------------------------------- 1 | {pkgs, ...}: { 2 | services = { 3 | upower.enable = true; 4 | 5 | tlp = { 6 | enable = true; 7 | settings = { 8 | CPU_SCALING_GOVERNOR_ON_AC = "performance"; 9 | CPU_SCALING_GOVERNOR_ON_BAT = "powersave"; 10 | 11 | CPU_ENERGY_PERF_POLICY_ON_BAT = "power"; 12 | CPU_ENERGY_PERF_POLICY_ON_AC = "performance"; 13 | 14 | CPU_MIN_PERF_ON_AC = 0; 15 | CPU_MAX_PERF_ON_AC = 100; 16 | CPU_MIN_PERF_ON_BAT = 0; 17 | CPU_MAX_PERF_ON_BAT = 60; 18 | 19 | #Optional helps save long term battery health 20 | START_CHARGE_THRESH_BAT0 = 40; # 40 and bellow it starts to charge 21 | STOP_CHARGE_THRESH_BAT0 = 100; 22 | }; 23 | }; 24 | }; 25 | } 26 | -------------------------------------------------------------------------------- /systems/modules/ld.nix: -------------------------------------------------------------------------------- 1 | # taken from https://github.com/Mic92/dotfiles/blob/main/nixos/modules/nix-ld.nix 2 | {pkgs, config, ...}: { 3 | # Enable nix ld 4 | programs.nix-ld.enable = true; 5 | 6 | programs.nix-ld.libraries = with pkgs; [ 7 | stdenv.cc.cc 8 | fuse3 9 | alsa-lib 10 | at-spi2-atk 11 | at-spi2-core 12 | atk 13 | cairo 14 | cups 15 | curl 16 | dbus 17 | expat 18 | fontconfig 19 | freetype 20 | gdk-pixbuf 21 | glib 22 | gtk3 23 | libGL 24 | libappindicator-gtk3 25 | libdrm 26 | libnotify 27 | libpulseaudio 28 | libuuid 29 | libusb1 30 | xorg.libxcb 31 | libxkbcommon 32 | mesa 33 | nspr 34 | nss 35 | pango 36 | pipewire 37 | systemd 38 | icu 39 | openssl 40 | webkitgtk 41 | xorg.libX11 42 | xorg.libXScrnSaver 43 | xorg.libXcomposite 44 | xorg.libXcursor 45 | xorg.libXdamage 46 | xorg.libXext 47 | xorg.libXfixes 48 | xorg.libXi 49 | xorg.libXrandr 50 | xorg.libXrender 51 | xorg.libXtst 52 | xorg.libxkbfile 53 | xorg.libxshmfence 54 | zlib 55 | ]; 56 | } 57 | -------------------------------------------------------------------------------- /systems/modules/navidrome.nix: -------------------------------------------------------------------------------- 1 | { pkgs, config, lib, ... }: { 2 | # sops required to run this anyways 3 | sops.secrets."lastfm/key" = { 4 | owner = config.systemd.services.navidrome.serviceConfig.User; 5 | restartUnits = [ "navidrome.service" ]; 6 | }; 7 | sops.secrets."lastfm/secret" = { 8 | owner = config.systemd.services.navidrome.serviceConfig.User; 9 | restartUnits = [ "navidrome.service" ]; 10 | }; 11 | sops.secrets."spotify/id" = { 12 | owner = config.systemd.services.navidrome.serviceConfig.User; 13 | restartUnits = [ "navidrome.service" ]; 14 | }; 15 | sops.secrets."spotify/secret" = { 16 | owner = config.systemd.services.navidrome.serviceConfig.User; 17 | restartUnits = [ "navidrome.service" ]; 18 | }; 19 | sops.templates."navidrome-config.toml" = { 20 | content = '' 21 | MusicFolder = "/music" 22 | Address = "192.168.3.14" 23 | LastFM.Enabled = true 24 | LastFM.ApiKey = "${config.sops.placeholder."lastfm/key"}" 25 | LastFM.Secret = "${config.sops.placeholder."lastfm/secret"}" 26 | Spotify.ID = "${config.sops.placeholder."spotify/id"}" 27 | Spotify.Secret = "${config.sops.placeholder."spotify/secret"}" 28 | EnableSharing = true 29 | EnableExternalServices = true 30 | Scanner.GroupAlbumReleases = true 31 | ''; 32 | owner = config.users.users.navidrome.name; 33 | }; 34 | 35 | services.navidrome = { 36 | enable = true; 37 | openFirewall = true; 38 | # unused but required by nixos module 39 | settings = { 40 | MusicFolder = "/music"; 41 | Address = "192.168.1.14"; 42 | }; 43 | }; 44 | 45 | systemd.services.navidrome = { 46 | after = lib.mkForce [ "network.target" "sops-nix.service" ]; 47 | 48 | serviceConfig.BindReadOnlyPaths = [ 49 | # navidrome uses online services to download additional album metadata / covers 50 | "${config.environment.etc."ssl/certs/ca-certificates.crt".source}:/etc/ssl/certs/ca-certificates.crt" 51 | builtins.storeDir 52 | "/etc" 53 | "/music" 54 | "/run/secrets/rendered" 55 | ]; 56 | serviceConfig.DynamicUser = lib.mkForce false; 57 | serviceConfig.User = config.users.users.navidrome.name; 58 | serviceConfig.ExecStart = lib.mkForce "${pkgs.navidrome}/bin/navidrome --configfile ${config.sops.templates."navidrome-config.toml".path}"; 59 | }; 60 | 61 | users.users.navidrome = { 62 | name = "navidrome"; 63 | home = "/var/lib/navidrome"; 64 | homeMode = "777"; 65 | createHome = true; 66 | isSystemUser = true; 67 | group = "navidrome"; 68 | extraGroups = [ "wheel" "users" ]; 69 | }; 70 | users.groups.navidrome = {}; 71 | } 72 | -------------------------------------------------------------------------------- /systems/modules/niri.nix: -------------------------------------------------------------------------------- 1 | { 2 | inputs, 3 | pkgs, 4 | ... 5 | }: { 6 | nixpkgs.overlays = [inputs.niri.overlays.niri]; 7 | imports = [inputs.niri.nixosModules.niri]; 8 | 9 | programs.niri = { 10 | enable = true; 11 | package = pkgs.niri-unstable; 12 | }; 13 | systemd.user.services.niri-flake-polkit.enable = false; 14 | services.gnome.sushi.enable = true; 15 | } 16 | -------------------------------------------------------------------------------- /systems/modules/nix.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Suya1671/commafiles/386603e0af2253d673f5299952eeaee37493b644/systems/modules/nix.png -------------------------------------------------------------------------------- /systems/modules/nvidia.nix: -------------------------------------------------------------------------------- 1 | { 2 | config, 3 | pkgs, 4 | ... 5 | }: { 6 | hardware.nvidia = { 7 | modesetting.enable = true; 8 | open = false; 9 | powerManagement.enable = true; 10 | nvidiaSettings = true; 11 | package = config.boot.kernelPackages.nvidiaPackages.beta; 12 | }; 13 | 14 | hardware.graphics = { 15 | enable = true; 16 | package = config.boot.kernelPackages.nvidiaPackages.beta; 17 | extraPackages = [ pkgs.libvdpau-va-gl pkgs.mesa pkgs.mesa.drivers ]; 18 | }; 19 | 20 | boot.kernelModules = ["nvidia" "i915" "nvidia_modeset" "nvidia_drm"]; 21 | services.xserver.videoDrivers = ["nvidia"]; 22 | } 23 | -------------------------------------------------------------------------------- /systems/modules/openrgb/default.nix: -------------------------------------------------------------------------------- 1 | {pkgs, ...}: { 2 | services.hardware.openrgb = { 3 | enable = true; 4 | package = pkgs.openrgb-with-all-plugins; 5 | }; 6 | } 7 | -------------------------------------------------------------------------------- /systems/modules/printing.nix: -------------------------------------------------------------------------------- 1 | {pkgs, ...}: { 2 | services.printing = { 3 | enable = true; 4 | # https://github.com/NixOS/nixpkgs/pull/369304 5 | # drivers = [pkgs.epson-escpr]; 6 | }; 7 | 8 | hardware.sane.enable = true; 9 | hardware.sane.extraBackends = [pkgs.sane-airscan]; 10 | } 11 | -------------------------------------------------------------------------------- /systems/modules/sops.nix: -------------------------------------------------------------------------------- 1 | { inputs, secrets, config, ... }: { 2 | imports = [ 3 | inputs.sops-nix.nixosModules.sops 4 | ]; 5 | sops = { 6 | defaultSopsFile = "${secrets}/secrets.json"; 7 | age = { 8 | sshKeyPaths = [ "/etc/ssh/ssh_host_ed25519_key" ]; 9 | keyFile = "/var/lib/sops-nix/key.txt"; 10 | }; 11 | }; 12 | } 13 | -------------------------------------------------------------------------------- /systems/modules/steam.nix: -------------------------------------------------------------------------------- 1 | { pkgs, ... }: { 2 | programs.gamescope = { 3 | enable = true; 4 | capSysNice = true; 5 | }; 6 | 7 | programs.steam = { 8 | enable = true; 9 | package = pkgs.steam.override { 10 | extraPkgs = pkgs: 11 | with pkgs; [ 12 | xorg.libXcursor 13 | xorg.libXi 14 | xorg.libXinerama 15 | xorg.libXScrnSaver 16 | libpng 17 | libpulseaudio 18 | libvorbis 19 | stdenv.cc.cc.lib 20 | libkrb5 21 | keyutils 22 | gamescope 23 | ]; 24 | }; 25 | remotePlay.openFirewall = true; # Open ports in the firewall for Steam Remote Play 26 | dedicatedServer.openFirewall = true; # Open ports in the firewall for Source Dedicated Server 27 | localNetworkGameTransfers.openFirewall = true; # Open ports in the firewall for Steam Local Network Game Transfers 28 | gamescopeSession.enable = true; 29 | }; 30 | } 31 | -------------------------------------------------------------------------------- /systems/modules/sunshine.nix: -------------------------------------------------------------------------------- 1 | { pkgs, ... }: { 2 | services.sunshine = { 3 | enable = true; 4 | autoStart = true; 5 | capSysAdmin = true; 6 | openFirewall = true; 7 | }; 8 | 9 | services.avahi.publish.enable = true; 10 | services.avahi.publish.userServices = true; 11 | } 12 | -------------------------------------------------------------------------------- /systems/modules/tablet.nix: -------------------------------------------------------------------------------- 1 | { ... }: { 2 | hardware.opentabletdriver.enable = true; 3 | } 4 | 5 | -------------------------------------------------------------------------------- /systems/modules/teamviewer.nix: -------------------------------------------------------------------------------- 1 | {...}: { 2 | services.teamviewer.enable = true; 3 | } 4 | -------------------------------------------------------------------------------- /systems/modules/theme.nix: -------------------------------------------------------------------------------- 1 | # Theme options 2 | { 3 | lib, 4 | config, 5 | wallpapers, 6 | pkgs, 7 | ... 8 | }: let 9 | theme = config.tntman.theme; 10 | monoFont = config.tntman.monospaceFont; 11 | in { 12 | options.tntman = { 13 | theme = lib.mkOption { 14 | type = lib.types.attrs; 15 | description = "Theme options"; 16 | }; 17 | 18 | monospaceFont = lib.mkOption { 19 | type = lib.types.str; 20 | default = "ComicCodeLigatures Nerd Font"; 21 | description = "Monospace font"; 22 | }; 23 | }; 24 | 25 | config.stylix = { 26 | enable = true; 27 | polarity = "dark"; 28 | base16Scheme = theme.base16; 29 | 30 | fonts = { 31 | serif = { 32 | package = pkgs.stix-two; 33 | name = "Stix Two Text"; 34 | }; 35 | 36 | sansSerif = { 37 | package = pkgs.recursive; 38 | name = "Recursive Sans Linear Static"; 39 | }; 40 | 41 | monospace = { 42 | package = pkgs.nerd-fonts.jetbrains-mono; 43 | name = monoFont; 44 | }; 45 | 46 | emoji = { 47 | package = pkgs.noto-fonts-emoji; 48 | name = "Noto Color Emoji"; 49 | }; 50 | 51 | sizes = { 52 | applications = 13; 53 | desktop = 12; 54 | }; 55 | }; 56 | 57 | # opacity = { 58 | # desktop = 0.6; 59 | # terminal = 0.6; 60 | # applications = 0.6; 61 | # }; 62 | 63 | targets = { 64 | plymouth.logo = ./nix.png; 65 | }; 66 | 67 | image = "${wallpapers}/Orbit.png"; 68 | 69 | cursor = { 70 | package = pkgs.catppuccin-cursors.mochaLavender; 71 | name = "Catppuccin-Mocha-Lavender-Cursors"; 72 | size = 16; 73 | }; 74 | }; 75 | } 76 | -------------------------------------------------------------------------------- /systems/modules/vaultwarden.nix: -------------------------------------------------------------------------------- 1 | { ... }: { 2 | services.vaultwarden = { 3 | enable = true; 4 | config = { 5 | ROCKET_PORT = 8080; 6 | }; 7 | }; 8 | } 9 | -------------------------------------------------------------------------------- /systems/modules/wayland.nix: -------------------------------------------------------------------------------- 1 | {pkgs, ...}: { 2 | environment = { 3 | variables = { 4 | NIXOS_OZONE_WL = "1"; 5 | __GL_GSYNC_ALLOWED = "0"; 6 | __GL_VRR_ALLOWED = "0"; 7 | DISABLE_QT5_COMPAT = "0"; 8 | ANKI_WAYLAND = "1"; 9 | DIRENV_LOG_FORMAT = ""; 10 | WLR_DRM_NO_ATOMIC = "1"; 11 | QT_WAYLAND_DISABLE_WINDOWDECORATION = "1"; 12 | QT_QPA_PLATFORMTHEME = "qt5ct"; 13 | QT_STYLE_OVERRIDE = "kvantum"; 14 | MOZ_ENABLE_WAYLAND = "1"; 15 | WLR_BACKEND = "vulkan"; 16 | WLR_NO_HARDWARE_CURSORS = "1"; 17 | XDG_SESSION_TYPE = "wayland"; 18 | CLUTTER_BACKEND = "wayland"; 19 | WLR_DRM_DEVICES = "/dev/dri/card1:/dev/dri/card0"; 20 | }; 21 | loginShellInit = '' 22 | eval $(ssh-agent) 23 | export GPG_TTY=$TTY 24 | ''; 25 | systemPackages = [ 26 | pkgs.libsForQt5.qt5.qtwayland 27 | pkgs.qt6.qtwayland 28 | ]; 29 | }; 30 | 31 | xdg.portal = { 32 | enable = true; 33 | }; 34 | 35 | security = { 36 | # allow wayland lockers to unlock the screen 37 | pam.services.swaylock.text = "auth include login"; 38 | }; 39 | } 40 | -------------------------------------------------------------------------------- /systems/tau/config.nix: -------------------------------------------------------------------------------- 1 | {pkgs, config, ...}: { 2 | time.timeZone = "Africa/Johannesburg"; 3 | i18n.defaultLocale = "en_ZA.UTF-8"; 4 | sdImage.compressImage = false; 5 | console.keyMap = "us"; 6 | nixpkgs.config.allowUnsupportedSystem = true; 7 | nixpkgs.hostPlatform = "aarch64-linux"; 8 | 9 | networking.hostName = "tau"; 10 | networking.wireless.enable = false; 11 | 12 | users.users.tau = { 13 | isNormalUser = true; 14 | description = "The superior pi"; 15 | extraGroups = ["networkmanager" "wheel" "scanner" "lp" "gpio"]; 16 | initialPassword = "password"; # Change this with passwd 17 | openssh.authorizedKeys.keys = [ 18 | "ssh-ed25519 AAAAC3NzaC1lZDI1NTE5AAAAIBzVQvEJjRAY51R49ytUC7RstLEWNELtlniyXXb7wZQe Suyashtnt@gmail.com" 19 | ]; 20 | shell = pkgs.nushell; 21 | }; 22 | 23 | # Create gpio group 24 | users.groups.gpio = {}; 25 | 26 | # Change permissions gpio devices 27 | services.udev.extraRules = '' 28 | SUBSYSTEM=="bcm2835-gpiomem", KERNEL=="gpiomem", GROUP="gpio",MODE="0660" 29 | SUBSYSTEM=="gpio", KERNEL=="gpiochip*", ACTION=="add", RUN+="${pkgs.bash}/bin/bash -c 'chown root:gpio /sys/class/gpio/export /sys/class/gpio/unexport ; chmod 220 /sys/class/gpio/export /sys/class/gpio/unexport'" 30 | SUBSYSTEM=="gpio", KERNEL=="gpio*", ACTION=="add",RUN+="${pkgs.bash}/bin/bash -c 'chown root:gpio /sys%p/active_low /sys%p/direction /sys%p/edge /sys%p/value ; chmod 660 /sys%p/active_low /sys%p/direction /sys%p/edge /sys%p/value'" 31 | ''; 32 | 33 | services.udev.packages = [ 34 | pkgs.openocd 35 | ]; 36 | 37 | # systemd.services.btattach = { 38 | # before = ["bluetooth.service"]; 39 | # after = ["dev-ttyAMA0.device"]; 40 | # wantedBy = ["multi-user.target"]; 41 | # serviceConfig = { 42 | # ExecStart = "${pkgs.bluez}/bin/btattach -B /dev/ttyAMA0 -P bcm -S 3000000"; 43 | # }; 44 | # }; 45 | 46 | programs.dconf.enable = true; 47 | 48 | system = { 49 | stateVersion = "24.05"; 50 | }; 51 | 52 | services.openssh.enable = true; 53 | 54 | environment.systemPackages = with pkgs; [ 55 | libraspberrypi 56 | raspberrypi-eeprom 57 | helix 58 | ]; 59 | 60 | boot = { 61 | initrd.availableKernelModules = [ 62 | "usbhid" 63 | "usb_storage" 64 | "vc4" 65 | "pcie_brcmstb" # required for the pcie bus to work 66 | "reset-raspberrypi" # required for vl805 firmware to load 67 | ]; 68 | 69 | loader = { 70 | grub.enable = false; 71 | generic-extlinux-compatible.enable = true; 72 | }; 73 | }; 74 | 75 | # Required for the Wireless firmware 76 | # cloudflared 77 | services.cloudflared = { 78 | enable = true; 79 | 80 | package = pkgs.cloudflared.overrideAttrs (final: prev: { 81 | doCheck = false; 82 | }); 83 | 84 | tunnels = { 85 | "d9b6c172-5236-4cfe-b441-10f2e83e5eb4" = { 86 | credentialsFile = "${config.sops.secrets."cloudflared/tau".path}"; 87 | default = "http_status:404"; 88 | }; 89 | }; 90 | }; 91 | 92 | sops.secrets."cloudflared/tau" = { 93 | # Both are "cloudflared" by default 94 | owner = config.services.cloudflared.user; 95 | group = config.services.cloudflared.group; 96 | }; 97 | } 98 | -------------------------------------------------------------------------------- /systems/tau/default.nix: -------------------------------------------------------------------------------- 1 | { 2 | ezModules, 3 | inputs, 4 | ... 5 | }: { 6 | imports = [ 7 | ./config.nix 8 | ./hardware.nix 9 | 10 | ../modules/core/nix.nix 11 | ../modules/core/network.nix 12 | ../modules/core/security.nix 13 | ../modules/core/home-manager.nix 14 | ../modules/core/sound.nix 15 | 16 | ezModules.navidrome 17 | ezModules.vaultwarden 18 | ezModules.sops 19 | 20 | "${inputs.nixpkgs}/nixos/modules/installer/sd-card/sd-image-aarch64-installer.nix" 21 | ]; 22 | } 23 | -------------------------------------------------------------------------------- /systems/tau/hardware.nix: -------------------------------------------------------------------------------- 1 | {lib, ...}: { 2 | boot = { 3 | initrd.availableKernelModules = ["xhci_pci" "usbhid" "usb_storage"]; 4 | loader = { 5 | grub.enable = false; 6 | generic-extlinux-compatible.enable = true; 7 | efi.canTouchEfiVariables = true; 8 | }; 9 | }; 10 | 11 | hardware = { 12 | # raspberry-pi."4" = { 13 | # fkms-3d.enable = true; 14 | # apply-overlays-dtmerge.enable = true; 15 | # }; 16 | deviceTree = { 17 | enable = true; 18 | filter = lib.mkForce "*rpi-4-*.dtb"; 19 | }; 20 | enableRedistributableFirmware = true; 21 | }; 22 | 23 | fileSystems = { 24 | "/" = { 25 | device = "/dev/disk/by-label/NIXOS_SD"; 26 | fsType = "ext4"; 27 | options = ["noatime"]; 28 | }; 29 | }; 30 | 31 | # Enables DHCP on each ethernet and wireless interface. In case of scripted networking 32 | # (the default) this is the recommended approach. When using systemd-networkd it's 33 | # still possible to use this option, but it's recommended to use it in conjunction 34 | # with explicit per-interface declarations with `networking.interfaces..useDHCP`. 35 | networking.useDHCP = lib.mkDefault true; 36 | } 37 | -------------------------------------------------------------------------------- /users/default.nix: -------------------------------------------------------------------------------- 1 | {...}: { 2 | ezConfigs = { 3 | home = { 4 | modulesDirectory = ./modules; 5 | configurationsDirectory = ./.; 6 | }; 7 | }; 8 | } 9 | -------------------------------------------------------------------------------- /users/modules/dunst.nix: -------------------------------------------------------------------------------- 1 | {...}: { 2 | services.dunst = { 3 | enable = true; 4 | iconTheme = { 5 | name = "Papirus-Dark"; 6 | size = "32x32"; 7 | }; 8 | settings = { 9 | global = { 10 | frame_color = "#89B4FA"; 11 | separator_color = "frame"; 12 | corner_radius = 12; 13 | }; 14 | 15 | urgency_low = { 16 | background = "#1E1E2E"; 17 | foreground = "#CDD6F4"; 18 | }; 19 | 20 | urgency_normal = { 21 | background = "#1E1E2E"; 22 | foreground = "#CDD6F4"; 23 | }; 24 | 25 | urgency_critical = { 26 | background = "#1E1E2E"; 27 | foreground = "#CDD6F4"; 28 | frame_color = "#FAB387"; 29 | }; 30 | }; 31 | }; 32 | } 33 | -------------------------------------------------------------------------------- /users/modules/editor.nix: -------------------------------------------------------------------------------- 1 | # common cross-editor config 2 | {lib, config, ...}: 3 | let 4 | cfg = config.tntman.home.editor; 5 | in 6 | { 7 | options.tntman.home.editor = { 8 | executable = lib.mkOption { 9 | type = lib.types.str; 10 | example = "\${pkgs.neovim}/bin/nvim"; 11 | description = "The editor program."; 12 | }; 13 | 14 | name = lib.mkOption { 15 | type = lib.types.str; 16 | example = "NeoVim"; 17 | description = "The name of the editor."; 18 | }; 19 | }; 20 | } 21 | -------------------------------------------------------------------------------- /users/modules/electron/config/electron-flags.conf: -------------------------------------------------------------------------------- 1 | --enable-features=UseOzonePlatform 2 | --ozone-platform=wayland 3 | -------------------------------------------------------------------------------- /users/modules/electron/default.nix: -------------------------------------------------------------------------------- 1 | {...}: { 2 | xdg.configFile."electron-flags.conf".source = ./config/electron-flags.conf; 3 | } 4 | -------------------------------------------------------------------------------- /users/modules/emacs/default.nix: -------------------------------------------------------------------------------- 1 | { 2 | pkgs, 3 | inputs, 4 | config, 5 | lib, 6 | ... 7 | }: let 8 | emc = pkgs.writeShellScriptBin "em" '' 9 | #!/bin/sh 10 | emacsclient -nc $@ 11 | ''; 12 | in { 13 | home = { 14 | packages = [ 15 | emc 16 | pkgs.fd 17 | pkgs.emacs-all-the-icons-fonts 18 | ]; 19 | 20 | sessionPath = ["${config.xdg.configHome}/emacs/bin"]; 21 | sessionVariables = { 22 | DOOMDIR = "${config.xdg.configHome}/.doom.d"; 23 | DOOMLOCALDIR = "${config.xdg.configHome}/doom-local"; 24 | }; 25 | 26 | activation.syncDoomEmacs = lib.hm.dag.entryAfter ["installPackages"] '' 27 | queryEmacsVersion() { 28 | local emacs="$1" 29 | "$emacs" --batch --eval '(princ (format "%d\n" emacs-major-version))' 30 | } 31 | 32 | syncDoomEmacs() { 33 | local oldEmacs newEmacs 34 | oldEmacs="$(readlink -m "$oldGenPath/home-path/bin/emacs")" 35 | newEmacs="$(readlink -m "$newGenPath/home-path/bin/emacs")" 36 | 37 | export DOOMDIR="${config.home.sessionVariables.DOOMDIR}" 38 | export DOOMLOCALDIR="${config.home.sessionVariables.DOOMLOCALDIR}" 39 | 40 | if [[ -x "${config.xdg.configHome}/emacs/bin/doom" ]]; then 41 | noteEcho 'This may take a while...' 42 | 43 | local maxfiles 44 | maxfiles="$(ulimit -n)" 45 | ulimit -n hard 46 | 47 | PATH="$newGenPath/home-path/bin:${pkgs.git}/bin:$PATH" \ 48 | $DRY_RUN_CMD "${config.xdg.configHome}/emacs/bin/doom" \ 49 | ''${VERBOSE:+-d} sync -e 50 | 51 | oldVersion="$(queryEmacsVersion "$oldEmacs")" 52 | newVersion="$(queryEmacsVersion "$newEmacs")" 53 | if (( oldVersion != newVersion )); then 54 | PATH="$newGenPath/home-path/bin:$PATH" \ 55 | $DRY_RUN_CMD "${config.xdg.configHome}/emacs/bin/doom" \ 56 | ''${VERBOSE:+-d} build 57 | fi 58 | 59 | ulimit -n "$maxfiles" 60 | fi 61 | } 62 | 63 | syncDoomEmacs 64 | systemctl --user restart emacs.service 65 | ''; 66 | }; 67 | 68 | programs.emacs = { 69 | enable = true; 70 | package = pkgs.emacs-unstable-pgtk; 71 | extraConfig = '' 72 | (setq dired-use-ls-dired t 73 | insert-directory-program "${pkgs.coreutils}/bin/ls" 74 | treemacs-python-executable "${pkgs.python3}/bin/python") 75 | 76 | (setq copilot-node-executable "${pkgs.nodejs}") 77 | ''; 78 | extraPackages = epkgs: 79 | with epkgs; [ 80 | # include Doom Emacs dependencies that tries to build native C code 81 | emacsql 82 | emacsql-sqlite 83 | pdf-tools 84 | vterm 85 | ]; 86 | }; 87 | 88 | xdg.configFile.".doom.d".source = ./doom.d; 89 | xdg.configFile."emacs".source = inputs.doom-emacs; 90 | 91 | services.emacs.enable = true; 92 | } 93 | -------------------------------------------------------------------------------- /users/modules/emacs/doom.d/config.el: -------------------------------------------------------------------------------- 1 | ;;; Doom.d --- my doom config 2 | 3 | ;;; Commentary: 4 | ;;; I have no idea what I'm doing. Any advice welcome! 5 | 6 | ;;; $DOOMDIR/config.el -*- lexical-binding: t; -*- 7 | 8 | 9 | ;;; Code: 10 | (setq user-full-name "Suyashtnt" 11 | user-mail-address "suyashtnt@gmail.com") 12 | 13 | ;; Doom exposes five (optional) variables for controlling fonts in Doom: 14 | ;; 15 | ;; - `doom-font' -- the primary font to use 16 | ;; - `doom-variable-pitch-font' -- a non-monospace font (where applicable) 17 | ;; - `doom-big-font' -- used for `doom-big-font-mode'; use this for 18 | ;; presentations or streaming. 19 | ;; - `doom-unicode-font' -- for unicode glyphs 20 | ;; - `doom-serif-font' -- for the `fixed-pitch-serif' face 21 | ;; 22 | ;; See 'C-h v doom-font' for documentation and more examples of what they 23 | ;; accept. For example: 24 | (setq doom-font (font-spec :family "ComicCodeLigatures Nerd Font" :size 12 :weight 'semi-light) 25 | doom-variable-pitch-font (font-spec :family "Inter" :size 13)) 26 | 27 | (setq doom-theme 'catppuccin) 28 | (setq catppuccin-flavor 'mocha) 29 | (setq custom-safe-themes 't) 30 | 31 | (setq display-line-numbers-type 'relative) 32 | 33 | ;; Makes sure that if there is a massive mouse movement, it recenters. 34 | (setq mouse-wheel-scroll-amount '(1 ((shift) . 3) ((control))) 35 | scroll-conservatively 3 36 | scroll-margin 3 37 | maximum-scroll-margin 0.2) 38 | 39 | ;; smooth scrolling stuff 40 | (setq pixel-scroll-precision-large-scroll-height 40.0) 41 | (setq-hook! 'term-mode-hook scroll-margin 0) 42 | (setq mouse-wheel-scroll-amount '(1 ((shift) . 1))) 43 | (setq mouse-wheel-progressive-speed nil) 44 | (setq mouse-wheel-follow-mouse 't) 45 | (setq scroll-step 1) 46 | (add-hook 'text-mode-hook 'pixel-scroll-precision-mode) 47 | 48 | (setq fancy-splash-image (expand-file-name "splash.svg" doom-user-dir)) 49 | 50 | (set-frame-parameter nil 'alpha-background 40) 51 | (add-to-list 'default-frame-alist '(alpha-background . 40)) 52 | 53 | ;; Whenever you reconfigure a package, make sure to wrap your config in an 54 | ;; `after!' block, otherwise Doom's defaults may override your settings. E.g. 55 | ;; 56 | ;; (after! PACKAGE 57 | ;; (setq x y)) 58 | ;; 59 | ;; The exceptions to this rule: 60 | ;; 61 | ;; - Setting file/directory variables (like `org-directory') 62 | ;; - Setting variables which explicitly tell you to set them before their 63 | ;; package is loaded (see 'C-h v VARIABLE' to look up their documentation). 64 | ;; - Setting doom variables (which start with 'doom-' or '+'). 65 | ;; 66 | ;; Here are some additional functions/macros that will help you configure Doom. 67 | ;; 68 | ;; - `load!' for loading external *.el files relative to this one 69 | ;; - `use-package!' for configuring packages 70 | ;; - `after!' for running code after a package has loaded 71 | ;; - `add-load-path!' for adding directories to the `load-path', relative to 72 | ;; this file. Emacs searches the `load-path' when you load packages with 73 | ;; `require' or `use-package'. 74 | ;; - `map!' for binding new keys 75 | ;; 76 | ;; To get information about any of these functions/macros, move the cursor over 77 | ;; the highlighted symbol at press 'K' (non-evil users must press 'C-c c k'). 78 | ;; This will open documentation for it, including demos of how they are used. 79 | ;; Alternatively, use `C-h o' to look up a symbol (functions, variables, faces, 80 | ;; etc). 81 | ;; 82 | ;; You can also try 'gd' (or 'C-c c d') to jump to their definition and see how 83 | ;; they are implemented. 84 | 85 | (after! lsp-mode 86 | (add-to-list 'lsp-language-id-configuration 87 | '("\\.typ$" . "typst")) 88 | 89 | (lsp-register-client 90 | (make-lsp-client :new-connection (lsp-stdio-connection "typst-lsp") 91 | :activation-fn (lsp-activate-on "typst") 92 | :environment-fn (lambda () 93 | '(("RUST_BACKTRACE" . lsp-typst-enable-backtrace))) 94 | :server-id 'typst-lsp))) 95 | 96 | (defun scroll-down-and-recenter () 97 | "Scrolls down and recenters the screen." 98 | (interactive) 99 | (evil-scroll-down 0)) 100 | 101 | (defun scroll-up-and-recenter () 102 | "Scrolls up and recenters the screen." 103 | (interactive) 104 | (evil-scroll-up 0)) 105 | 106 | (map! 107 | :after evil 108 | :n "C-d" 'scroll-down-and-recenter 109 | :n "C-u" 'scroll-up-and-recenter) 110 | 111 | (setq lsp-typst-enable-backtrace "1") 112 | 113 | (after! lsp-ui 114 | (setq lsp-ui-doc-enable t) 115 | (setq lsp-ui-doc-position 'at-point)) 116 | 117 | (after! centaur-tabs (centaur-tabs-group-by-projectile-project)) 118 | 119 | (use-package! lsp-nix 120 | :ensure lsp-mode 121 | :after (lsp-mode) 122 | :demand t 123 | :custom 124 | (lsp-nix-nil-formatter ["nixpkgs-fmt"])) 125 | 126 | (use-package! nix-mode 127 | :hook (nix-mode . lsp-deferred) 128 | :ensure t) 129 | 130 | (use-package! good-scroll 131 | :hook (doom-first-input . good-scroll-mode) 132 | :config 133 | (defun good-scroll--convert-line-to-step (line) 134 | (cl-typecase line 135 | (integer (* line (line-pixel-height))) 136 | ((or null (member -)) 137 | (- (good-scroll--window-usable-height) 138 | (* next-screen-context-lines (line-pixel-height)))) 139 | (t (line-pixel-height)))) 140 | 141 | (defadvice! good-scroll--scroll-up (&optional arg) 142 | :override 'scroll-up 143 | (good-scroll-move (good-scroll--convert-line-to-step arg))) 144 | 145 | (defadvice! good-scroll--scroll-down (&optional arg) 146 | :override 'scroll-down 147 | (good-scroll-move (- (good-scroll--convert-line-to-step arg))))) 148 | 149 | (use-package! typst-mode) 150 | 151 | ;; accept completion from copilot and fallback to company 152 | (use-package! copilot 153 | :hook (prog-mode . copilot-mode) 154 | :bind (:map copilot-completion-map 155 | ("" . 'copilot-accept-completion) 156 | ("TAB" . 'copilot-accept-completion) 157 | ("C-TAB" . 'copilot-accept-completion-by-word) 158 | ("C-" . 'copilot-accept-completion-by-word))) 159 | 160 | (add-hook 'nix-mode-local-vars-hook #'lsp!) 161 | (add-hook 'typst-mode-local-vars-hook #'lsp!) 162 | (add-hook 'typst--markup-mode-local-vars-hook #'lsp!) 163 | (add-hook 'typst--code-mode-local-vars-hook #'lsp!) 164 | 165 | ;; tree sitter enabled packages 166 | (global-tree-sitter-mode) 167 | (add-hook 'tree-sitter-after-on-hook #'tree-sitter-hl-mode) 168 | 169 | ;;; config.el ends here 170 | -------------------------------------------------------------------------------- /users/modules/emacs/doom.d/init.el: -------------------------------------------------------------------------------- 1 | ;;; init.el -*- lexical-binding: t; -*- 2 | 3 | ;; This file controls what Doom modules are enabled and what order they load 4 | ;; in. Remember to run 'doom sync' after modifying it! 5 | 6 | ;; NOTE Press 'SPC h d h' (or 'C-h d h' for non-vim users) to access Doom's 7 | ;; documentation. There you'll find a link to Doom's Module Index where all 8 | ;; of our modules are listed, including what flags they support. 9 | 10 | ;; NOTE Move your cursor over a module's name (or its flags) and press 'K' (or 11 | ;; 'C-c c k' for non-vim users) to view its documentation. This works on 12 | ;; flags as well (those symbols that start with a plus). 13 | ;; 14 | ;; Alternatively, press 'gd' (or 'C-c c d') on a module to browse its 15 | ;; directory (for easy access to its source code). 16 | 17 | (doom! :input 18 | ;;bidi ; (tfel ot) thgir etirw uoy gnipleh 19 | ;;chinese 20 | ;;japanese 21 | ;;layout ; auie,ctsrnm is the superior home row 22 | 23 | :completion 24 | (company +childframe) ; the ultimate code completion backend 25 | (helm +icons +childframe) ; the *other* search engine for love and life 26 | ;;ido ; the other *other* search engine... 27 | ;;ivy ; a search engine for love and life 28 | ;;vertico ; the search engine of the future 29 | 30 | :ui 31 | ;;deft ; notational velocity for Emacs 32 | doom ; what makes DOOM look the way it does 33 | doom-dashboard ; a nifty splash screen for Emacs 34 | doom-quit ; DOOM quit-message prompts when you quit Emacs 35 | (emoji +unicode +github) ; 🙂 36 | hl-todo ; highlight TODO/FIXME/NOTE/DEPRECATED/HACK/REVIEW 37 | hydra 38 | indent-guides ; highlighted indent columns 39 | (ligatures +extra) ; ligatures and symbols to make your code pretty again 40 | ;;minimap ; show a map of the code on the side 41 | modeline ; snazzy, Atom-inspired modeline, plus API 42 | nav-flash ; blink cursor line after big motions 43 | ;;neotree ; a project drawer, like NERDTree for vim 44 | ophints ; highlight the region an operation acts on 45 | (popup +defaults) ; tame sudden yet inevitable temporary windows 46 | tabs ; a tab bar for Emacs 47 | (treemacs +lsp) ; a project drawer, like neotree but cooler 48 | ;;unicode ; extended unicode support for various languages 49 | (vc-gutter +pretty) ; vcs diff in the fringe 50 | vi-tilde-fringe ; fringe tildes to mark beyond EOB 51 | ;;window-select ; visually switch windows 52 | workspaces ; tab emulation, persistence & separate workspaces 53 | ;;zen ; distraction-free coding or writing 54 | 55 | :editor 56 | (evil +everywhere); come to the dark side, we have cookies 57 | file-templates ; auto-snippets for empty files 58 | fold ; (nigh) universal code folding 59 | (format +onsave) ; automated prettiness 60 | ;;god ; run Emacs commands without modifier keys 61 | ;;lispy ; vim for lisp, for people who don't like vim 62 | ;;multiple-cursors ; editing in many places at once 63 | ;;objed ; text object editing for the innocent 64 | parinfer ; turn lisp into python, sort of 65 | ;;rotate-text ; cycle region at point between text candidates 66 | snippets ; my elves. They type so I don't have to 67 | ;;word-wrap ; soft wrapping with language-aware indent 68 | 69 | :emacs 70 | (dired +icons) ; making dired pretty [functional] 71 | electric ; smarter, keyword-based electric-indent 72 | ;;ibuffer ; interactive buffer management 73 | (undo +tree) ; persistent, smarter undo for your inevitable mistakes 74 | vc ; version-control and Emacs, sitting in a tree 75 | 76 | :term 77 | ;;eshell ; the elisp shell that works everywhere 78 | ;;shell ; simple shell REPL for Emacs 79 | ;;term ; basic terminal emulator for Emacs 80 | vterm ; the best terminal emulation in Emacs 81 | 82 | :checkers 83 | syntax ; tasing you for every semicolon you forget 84 | (spell +flyspell) ; tasing you for misspelling mispelling 85 | grammar ; tasing grammar mistake every you make 86 | 87 | :tools 88 | ;;ansible 89 | ;;biblio ; Writes a PhD for you (citation needed) 90 | ;;debugger ; FIXME stepping through code, to help you add bugs 91 | direnv 92 | ;;docker 93 | editorconfig ; let someone else argue about tabs vs spaces 94 | ;;ein ; tame Jupyter notebooks with emacs 95 | (eval +overlay) ; run code, run (also, repls) 96 | ;;gist ; interacting with github gists 97 | (lookup +dictionary +offline) ; navigate your code and its documentation 98 | (lsp +eglot +peek) ; M-x vscode 99 | magit ; a git porcelain for Emacs 100 | ;;make ; run make tasks from Emacs 101 | ;;pass ; password manager for nerds 102 | pdf ; pdf enhancements 103 | ;;prodigy ; FIXME managing external services & code builders 104 | rgb ; creating color strings 105 | ;;taskrunner ; taskrunner for all your projects 106 | ;;terraform ; infrastructure as code 107 | ;;tmux ; an API for interacting with tmux 108 | tree-sitter ; syntax and parsing, sitting in a tree... 109 | ;;upload ; map local to remote projects via ssh/ftp 110 | 111 | :os 112 | (:if IS-MAC macos) ; improve compatibility with macOS 113 | ;;tty ; improve the terminal Emacs experience 114 | 115 | :lang 116 | ;;agda ; types of types of types of types... 117 | ;;beancount ; mind the GAAP 118 | ;;(cc +lsp) ; C > C++ == 1 119 | ;;clojure ; java with a lisp 120 | ;;common-lisp ; if you've seen one lisp, you've seen them all 121 | ;;coq ; proofs-as-programs 122 | ;;crystal ; ruby at the speed of c 123 | ;;csharp ; unity, .NET, and mono shenanigans 124 | ;;data ; config/data formats 125 | ;;(dart +flutter) ; paint ui and not much else 126 | ;;dhall 127 | ;;elixir ; erlang done right 128 | ;;elm ; care for a cup of TEA? 129 | emacs-lisp ; drown in parentheses 130 | ;;erlang ; an elegant language for a more civilized age 131 | ;;ess ; emacs speaks statistics 132 | ;;factor 133 | ;;faust ; dsp, but you get to keep your soul 134 | ;;fortran ; in FORTRAN, GOD is REAL (unless declared INTEGER) 135 | ;;fsharp ; ML stands for Microsoft's Language 136 | ;;fstar ; (dependent) types and (monadic) effects and Z3 137 | ;;gdscript ; the language you waited for 138 | ;;(go +lsp) ; the hipster dialect 139 | ;;(graphql +lsp) ; Give queries a REST 140 | (haskell +lsp) ; a language that's lazier than I am 141 | ;;hy ; readability of scheme w/ speed of python 142 | ;;idris ; a language you can depend on 143 | (json +lsp) ; At least it ain't XML 144 | ;;(java +lsp) ; the poster child for carpal tunnel syndrome 145 | (javascript +lsp) ; all(hope(abandon(ye(who(enter(here)))))) 146 | ;;julia ; a better, faster MATLAB 147 | ;;kotlin ; a better, slicker Java(Script) 148 | ;;latex ; writing papers in Emacs has never been so fun 149 | ;;lean ; for folks with too much to prove 150 | ;;ledger ; be audit you can be 151 | (lua +lsp +fennel) ; one-based indices? one-based indices 152 | (markdown +grip) ; writing docs for people to ignore 153 | ;;nim ; python + lisp at the speed of c 154 | nix ; I hereby declare "nix geht mehr!" lsp is handled by custom code (nil LSP) 155 | ;;ocaml ; an objective camel 156 | ;;org ; organize your plain life in plain text 157 | ;;php ; perl's insecure younger brother 158 | ;;plantuml ; diagrams for confusing people more 159 | ;;purescript ; javascript, but functional 160 | ;;python ; beautiful is better than ugly 161 | ;;qt ; the 'cutest' gui framework ever 162 | ;;racket ; a DSL for DSLs 163 | ;;raku ; the artist formerly known as perl6 164 | rest ; Emacs as a REST client 165 | ;;rst ; ReST in peace 166 | ;;(ruby +rails) ; 1.step {|i| p "Ruby is #{i.even? ? 'love' : 'life'}"} 167 | (rust +lsp) ; Fe2O3.unwrap().unwrap().unwrap().unwrap() 168 | ;;scala ; java, but good 169 | ;;(scheme +guile) ; a fully conniving family of lisps 170 | sh ; she sells {ba,z,fi}sh shells on the C xor 171 | ;;sml 172 | ;;solidity ; do you need a blockchain? No. 173 | ;;swift ; who asked for emoji variables? 174 | ;;terra ; Earth and Moon in alignment for performance. 175 | (web +html +css +lsp) ; the tubes 176 | ;;yaml ; JSON, but readable 177 | ;;zig ; C, but simpler 178 | 179 | :email 180 | ;;(mu4e +org +gmail) 181 | ;;notmuch 182 | ;;(wanderlust +gmail) 183 | 184 | :app 185 | ;;calendar 186 | ;;emms 187 | ;;everywhere ; *leave* Emacs!? You must be joking 188 | ;;irc ; how neckbeards socialize 189 | ;;(rss +org) ; emacs as an RSS reader 190 | ;;twitter ; twitter client https://twitter.com/vnought 191 | 192 | :config 193 | ;;literate 194 | (default +bindings +smartparens)) 195 | -------------------------------------------------------------------------------- /users/modules/emacs/doom.d/packages.el: -------------------------------------------------------------------------------- 1 | ;;; Packages --- any custom packages my config requires 2 | ;; no-byte-compile: t; -*- 3 | 4 | ;;; Commentary: 5 | ;;; I have no idea what I'm doing again. I'm usually just following docs here 6 | 7 | ;;; Code: 8 | 9 | (when (package! polymode) 10 | (package! typst-mode 11 | :recipe (:type git :host github :repo "Ziqi-Yang/typst-mode.el"))) 12 | 13 | (package! catppuccin-theme) 14 | (package! rainbow-mode) 15 | (package! good-scroll) 16 | 17 | ;; s, editorconfig, and dash 18 | (when (package! editorconfig) 19 | (package! copilot 20 | :recipe (:host github :repo "zerolfx/copilot.el" :files ("*.el" "dist")))) 21 | 22 | ;; non-unpinned breaks 23 | (unpin! tree-sitter) 24 | (unpin! tree-sitter-langs) 25 | 26 | ;;; packages.el ends here 27 | -------------------------------------------------------------------------------- /users/modules/eww/config/eww.scss: -------------------------------------------------------------------------------- 1 | $mocha: ( 2 | "rosewater": #f5e0dc, 3 | "flamingo": #f2cdcd, 4 | "pink": #f5c2e7, 5 | "mauve": #cba6f7, 6 | "red": #f38ba8, 7 | "maroon": #eba0ac, 8 | "peach": #fab387, 9 | "yellow": #f9e2af, 10 | "green": #a6e3a1, 11 | "teal": #94e2d5, 12 | "sky": #89dceb, 13 | "sapphire": #74c7ec, 14 | "blue": #89b4fa, 15 | "lavender": #b4befe, 16 | "text": #cdd6f4, 17 | "subtext1": #bac2de, 18 | "subtext0": #a6adc8, 19 | "overlay2": #9399b2, 20 | "overlay1": #7f849c, 21 | "overlay0": #6c7086, 22 | "surface2": #585b70, 23 | "surface1": #45475a, 24 | "surface0": #313244, 25 | "base": #1e1e2e, 26 | "mantle": #181825, 27 | "crust": #11111b, 28 | ); 29 | 30 | $sizedProperties: ( 31 | "rounded": "border-radius", 32 | "p": "padding", 33 | "m": "margin", 34 | "text": "font-size", 35 | ); 36 | $sizes: ( 37 | "none": 0px, 38 | "sm": 0.5rem, 39 | "smd": 0.75rem, 40 | "md": 1rem, 41 | "lg": 1.5rem, 42 | "xl": 2rem, 43 | ); 44 | 45 | @each $name, $property in $sizedProperties { 46 | @each $size, $value in $sizes { 47 | .#{$name}-#{$size} { 48 | #{$property}: $value; 49 | } 50 | } 51 | } 52 | 53 | @each $size, $value in $sizes { 54 | .pl-#{$size} { 55 | padding-left: $value; 56 | } 57 | 58 | .pr-#{$size} { 59 | padding-right: $value; 60 | } 61 | 62 | .pt-#{$size} { 63 | padding-top: $value; 64 | } 65 | 66 | .pb-#{$size} { 67 | padding-bottom: $value; 68 | } 69 | 70 | .px-#{$size} { 71 | padding-left: $value; 72 | padding-right: $value; 73 | } 74 | 75 | .py-#{$size} { 76 | padding-top: $value; 77 | padding-bottom: $value; 78 | } 79 | 80 | .ml-#{$size} { 81 | margin-left: $value; 82 | } 83 | 84 | .mr-#{$size} { 85 | margin-right: $value; 86 | } 87 | 88 | .mt-#{$size} { 89 | margin-top: $value; 90 | } 91 | 92 | .mb-#{$size} { 93 | margin-bottom: $value; 94 | } 95 | 96 | .mx-#{$size} { 97 | margin-left: $value; 98 | margin-right: $value; 99 | } 100 | 101 | .my-#{$size} { 102 | margin-top: $value; 103 | margin-bottom: $value; 104 | } 105 | } 106 | 107 | @each $name, $value in $mocha { 108 | .bg-#{$name} { 109 | background-color: $value; 110 | } 111 | .#{$name} { 112 | color: $value; 113 | } 114 | } 115 | 116 | .bg-none { 117 | background-color: transparent; 118 | } 119 | 120 | .systemStats, 121 | .bgSel, 122 | .powerModeLeft, 123 | .powerModeRight, 124 | .powerModeTop, 125 | .powerModeBottom { 126 | background-color: transparent; 127 | } 128 | 129 | .pmt { 130 | border-radius: 0 0 1.5rem 1.5rem; 131 | } 132 | 133 | .pmr { 134 | border-radius: 1.5rem 0 0 1.5rem; 135 | } 136 | 137 | .pml { 138 | border-radius: 0 1.5rem 1.5rem 0; 139 | } 140 | 141 | .pmb { 142 | border-radius: 1.5rem 1.5rem 0 0; 143 | } 144 | 145 | .cmicon { 146 | font-size: 3rem; 147 | } 148 | 149 | .metric { 150 | scale trough highlight { 151 | all: unset; 152 | background-color: map-get($mocha, "sapphire"); 153 | color: #000000; 154 | border-radius: 10px; 155 | } 156 | 157 | scale trough { 158 | all: unset; 159 | background-color: map-get($mocha, "surface0"); 160 | border-radius: 2rem; 161 | min-height: 12px; 162 | } 163 | } 164 | -------------------------------------------------------------------------------- /users/modules/eww/config/eww.yuck: -------------------------------------------------------------------------------- 1 | (include "./powermode/top.yuck") 2 | (include "./powermode/bottom.yuck") 3 | (include "./powermode/left.yuck") 4 | (include "./powermode/right.yuck") 5 | 6 | (include "./systemStats.yuck") 7 | 8 | (include "./polls.yuck") 9 | -------------------------------------------------------------------------------- /users/modules/eww/config/polls.yuck: -------------------------------------------------------------------------------- 1 | (defpoll time :interval "1s" "date '+%H:%M:%S'") 2 | 3 | (defpoll volume :interval "1s" "scripts/getvol") 4 | 5 | (defpoll clients :interval "1s" "hyprctl clients -j") 6 | 7 | ;; music related 8 | (defpoll songArt 9 | :interval "1s" 10 | :initial "" 11 | "scripts/getcoverArt") 12 | 13 | ;; this command stupidly long but it works 14 | (defpoll queue 15 | :interval "1s" 16 | :initial '[]' 17 | "nu -c 'spotify_player get key queue | from json | get queue | each { get name artists } | each { |it| $it | update 1 ($it | get 1 | each { get name }) } | each { |it| { name: ($it | get 0), artists: ($it | get 1) } } | to json'") 18 | 19 | (defpoll songName 20 | :interval "1s" 21 | :initial "" 22 | "playerctl metadata xesam:title") 23 | 24 | (defpoll songArtist 25 | :interval "1s" 26 | :initial "" 27 | "playerctl metadata xesam:artist") 28 | 29 | (defpoll songStatus 30 | :interval "1s" 31 | :initial "" 32 | "playerctl status") 33 | 34 | (defpoll progress 35 | :interval "1s" 36 | :initial 0 37 | "playerctl position") 38 | 39 | (defpoll duration 40 | :interval "1s" 41 | :initial 0 42 | "playerctl metadata mpris:length | awk '{print $1/1000000}'") 43 | -------------------------------------------------------------------------------- /users/modules/eww/config/powermode/bottom.yuck: -------------------------------------------------------------------------------- 1 | (defwidget circularMetric [name icon value color] 2 | (box :orientation "h" :space-evenly true 3 | (circular-progress :class "${color}" :height 75 :width 75 :value value :thickness 10 :start-at 76 (label :text icon :class "cmicon")) 4 | (label :text "${name} ${round(value, 0)}%" :class "text-xl"))) 5 | 6 | (defwindow powerModeBottom 7 | :monitor 0 8 | :geometry (geometry :height "9%" 9 | :width "98%" 10 | :anchor "bottom center") 11 | :exclusive true 12 | (box :class "bg-mantle pmb p-md" 13 | (box :orientation "h" :spacing 50 14 | (circularMetric 15 | :name "CPU" 16 | :icon "﬙" 17 | :value {EWW_CPU.avg} 18 | :color "blue") 19 | (circularMetric 20 | :name "RAM" 21 | :icon "" 22 | :value {EWW_RAM.used_mem_perc} 23 | :color "green") 24 | (circularMetric 25 | :name "DISK" 26 | :icon "" 27 | :value {EWW_DISK["/"].used_perc} 28 | :color "sapphire") 29 | (label :class "text-xl" :text " ${EWW_NET["eno1"].NET_UP}  ${EWW_NET["eno1"].NET_DOWN}")))) 30 | -------------------------------------------------------------------------------- /users/modules/eww/config/powermode/left.yuck: -------------------------------------------------------------------------------- 1 | (defwidget bgSelImg [path name] 2 | (button 3 | :class "bg-surface0 rounded-lg p-md m-lg" 4 | :onclick "swww img -t wave --transition-angle 30 --transition-bezier 0.41,0.26,0.98,1 --transition-step 180 --transition-fps 60 --transition-duration 1.2 ${path}" 5 | :timeout "10s" 6 | (box 7 | :orientation "v" 8 | :space-evenly false 9 | :spacing 10 10 | (image 11 | :path path 12 | :image-height 200 13 | :class "rounded-md") 14 | name))) 15 | 16 | 17 | (defwindow powerModeLeft 18 | :monitor 0 19 | :geometry (geometry :height "80%" 20 | :width "18%" 21 | :anchor "left center") 22 | :exclusive true 23 | (box :orientation "v" :space-evenly false :spacing 20 :class "bg-mantle pml p-md" 24 | (calendar :class "rounded-lg") 25 | (scroll :hscroll false :height 530 26 | (box 27 | :orientation "v" 28 | :space-evenly false 29 | (bgSelImg :path "/home/tntman/commafiles/wallpapers/theAlmightyHexagon.png" :name "The almighty shape") 30 | (bgSelImg :path "/home/tntman/commafiles/wallpapers/justAReallyCoolArtwork.png" :name "I don't know how to describe this") 31 | (bgSelImg :path "/home/tntman/commafiles/wallpapers/Particles.png" :name "Particle system (OC!)") 32 | (bgSelImg :path "/home/tntman/commafiles/wallpapers/linox.png" :name "Linox"))))) 33 | -------------------------------------------------------------------------------- /users/modules/eww/config/powermode/right.yuck: -------------------------------------------------------------------------------- 1 | (defwidget music [] 2 | (box 3 | :orientation "v" 4 | :class "bg-surface0 rounded-lg p-sm" 5 | :style "background-image: linear-gradient(0deg, rgba(1,1,1,1) 0%, rgba(51,51,51,0.2) 40%, rgba(77,77,77,0.7) 75%, rgba(51,51,51,0.8) 90%, rgba(0,0,0,0.8) 100%), url('${songArt}'); background-size: cover; background-repeat: no-repeat; background-position: center;" 6 | :height 500 7 | (box 8 | :orientation "v" 9 | :space-evenly false 10 | :spacing 5 11 | (label :class "text-lg" :text "${songName}") 12 | (label :class "text-md" :text "${songArtist}")) 13 | (box 14 | :orientation "v" 15 | :class "mx-md" 16 | (progress 17 | :orientation "h" 18 | :value "${progress / duration * 100}") 19 | (box 20 | :orientation "h" 21 | :valign "center" 22 | :class "" 23 | :space-evenly true 24 | :spacing 15 25 | (button :class "bg-transparent rounded-sm" :timeout "100s" :onclick "playerctl previous" (label :class "text-xl" :text "")) 26 | (button :class "bg-transparent rounded-sm" :timeout "100s" :onclick "playerctl play-pause" 27 | (label :class "text-xl" :text "${songStatus == 'Playing' ? '' : ''}")) 28 | (button :class "bg-transparent rounded-sm" :timeout "100s" :onclick "playerctl next" (label :class "text-xl" :text "")))))) 29 | 30 | (defwindow powerModeRight 31 | :monitor 0 32 | :geometry (geometry :height "80%" 33 | :width "18%" 34 | :anchor "right center") 35 | :exclusive true 36 | (box :class "bg-mantle pmr p-md" :orientation "v" :space-evenly false :spacing 15 37 | (label :class "text-xl" :text time) 38 | (music) 39 | (label :class "text-xl" :text "Queue") 40 | (scroll :hscroll false :height 300 41 | (box 42 | :orientation "v" 43 | :space-evenly false 44 | :spacing 10 45 | (for item in queue 46 | (box 47 | :class "bg-base rounded-xl py-sm" 48 | (label :class "text-lmg" :text "${item.name} - ${jq(item.artists, 'join(\", \")')}"))))))) 49 | -------------------------------------------------------------------------------- /users/modules/eww/config/powermode/top.yuck: -------------------------------------------------------------------------------- 1 | (defwindow powerModeTop 2 | :monitor 0 3 | :geometry (geometry :x "0%" 4 | :height "9%" 5 | :width "98%" 6 | :anchor "top center") 7 | :exclusive true 8 | (box :class "bg-mantle pmt p-md" "sample text")) 9 | -------------------------------------------------------------------------------- /users/modules/eww/config/scripts/getcoverArt: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | # Get the current song art url from playerctl 4 | art=$(playerctl metadata mpris:artUrl) 5 | 6 | # extract the filename from the url 7 | filename=$(basename $art) 8 | 9 | # check if the image is already downloaded, if so, print the path and exit 10 | if [ -f ~/Pictures/$filename ]; then 11 | echo ~/Pictures/$filename 12 | exit 13 | fi 14 | 15 | # download the image from the url, saving it to ~/Pictures/{filename} 16 | curl -s $art -o ~/Pictures/$filename 17 | 18 | # print the final path to the image 19 | echo ~/Pictures/$filename 20 | -------------------------------------------------------------------------------- /users/modules/eww/config/scripts/getvol: -------------------------------------------------------------------------------- 1 | #!/bin/sh 2 | 3 | amixer sget Master | rg 'Left:' | awk -F'[][]' '{ print $2 }' | tr -d '%' | head -1 4 | -------------------------------------------------------------------------------- /users/modules/eww/config/systemStats.yuck: -------------------------------------------------------------------------------- 1 | (defwindow systemStats 2 | :monitor 0 3 | :geometry (geometry :x "1%" 4 | :y "4%" 5 | :anchor "top right") 6 | :stacking "bottom" 7 | (box 8 | :orientation "v" 9 | :class "rounded-xl bg-mantle p-xl" 10 | :space-evenly false 11 | (label :class "text-xl" :text time) 12 | (metric :name "🔊" 13 | :onchange "amixer sset Master {}%" 14 | :value volume) 15 | (metric :name "﬙" 16 | :onchange "" 17 | :value {EWW_CPU.avg}) 18 | (metric :name "" 19 | :onchange "" 20 | :value {EWW_RAM.used_mem_perc}) 21 | (metric :name "💾" 22 | :onchange "" 23 | :value {EWW_DISK["/"].used_perc}))) 24 | 25 | (defwidget metric [name value onchange] 26 | (box :orientation "h" 27 | :class "metric mx-md" 28 | :space-evenly false 29 | (label :class "text-xl icon" :text name) 30 | (scale :min 0 31 | :max 101 32 | :width 200 33 | :onchange onchange 34 | :active {onchange != ""} 35 | :value value))) 36 | -------------------------------------------------------------------------------- /users/modules/eww/default.nix: -------------------------------------------------------------------------------- 1 | {pkgs, ...}: { 2 | home.packages = with pkgs; [ 3 | alsa-utils 4 | ]; 5 | 6 | programs.eww = { 7 | enable = true; 8 | package = pkgs.eww-wayland; 9 | configDir = ./config; 10 | }; 11 | } 12 | -------------------------------------------------------------------------------- /users/modules/fastfetch/config/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "$schema": "https://github.com/fastfetch-cli/fastfetch/raw/dev/doc/json_schema.json", 3 | "logo": { 4 | "source": "~/commafiles/users/modules/fastfetch/config/nix.png", 5 | "type": "kitty-direct" 6 | }, 7 | "modules": [ 8 | "title", 9 | "separator", 10 | "os", 11 | "board", 12 | "cpu", 13 | "gpu", 14 | "memory", 15 | "kernel", 16 | "uptime", 17 | "separator", 18 | "wm", 19 | "theme", 20 | "icons", 21 | "separator", 22 | "shell", 23 | "terminal", 24 | "packages", 25 | "terminaltheme", 26 | "colors" 27 | ] 28 | } 29 | -------------------------------------------------------------------------------- /users/modules/fastfetch/config/nix.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Suya1671/commafiles/386603e0af2253d673f5299952eeaee37493b644/users/modules/fastfetch/config/nix.png -------------------------------------------------------------------------------- /users/modules/fastfetch/default.nix: -------------------------------------------------------------------------------- 1 | {pkgs, ...}: { 2 | programs.fastfetch = { 3 | enable = true; 4 | settings = builtins.fromJSON (builtins.readFile ./config/config.json); 5 | }; 6 | } 7 | -------------------------------------------------------------------------------- /users/modules/firefox/default.nix: -------------------------------------------------------------------------------- 1 | {pkgs, ...}: { 2 | home.file.".mozilla/firefox/tntman/chrome/img" = { 3 | source = ./images; 4 | recursive = true; 5 | }; 6 | 7 | # home.packages = [ 8 | # pkgs.firefox-pwa # PWAs go brrr 9 | # ]; 10 | # programs.firefox.nativeMessagingHosts.packages = [ pkgs.firefox-pwa ]; 11 | 12 | programs.firefox = { 13 | enable = true; 14 | package = pkgs.firefox; 15 | profiles = { 16 | tntman = { 17 | id = 0; 18 | settings = { 19 | "general.smoothScroll" = true; 20 | }; 21 | userChrome = 22 | import ./userChrome.nix {}; 23 | extraConfig = '' 24 | user_pref("toolkit.legacyUserProfileCustomizations.stylesheets", true); 25 | user_pref("full-screen-api.ignore-widgets", true); 26 | user_pref("media.ffmpeg.vaapi.enabled", true); 27 | user_pref("media.rdd-vpx.enabled", true); 28 | ''; 29 | }; 30 | }; 31 | }; 32 | } 33 | -------------------------------------------------------------------------------- /users/modules/firefox/images/back.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /users/modules/firefox/images/bookmarks.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /users/modules/firefox/images/downloads.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /users/modules/firefox/images/forward.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /users/modules/firefox/images/history.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /users/modules/firefox/images/menu.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /users/modules/firefox/images/overflow.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /users/modules/firefox/images/reload.svg: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | -------------------------------------------------------------------------------- /users/modules/fish/default.nix: -------------------------------------------------------------------------------- 1 | {pkgs, ...}: { 2 | home.packages = with pkgs; [ 3 | inshellisense # carapace completer support 4 | zsh # carapace completer support 5 | grc # grc command-line colorizer 6 | ]; 7 | 8 | tntman.home.shell.executable = "${pkgs.fish}/bin/fish"; 9 | 10 | programs = { 11 | fish = { 12 | enable = true; 13 | interactiveShellInit = '' 14 | set fish_greeting # Disable greeting 15 | set -Ux CARAPACE_BRIDGES 'clap,inshellisense,fish,zsh,bash' 16 | ''; 17 | plugins = [ 18 | { name = "grc"; src = pkgs.fishPlugins.grc.src; } 19 | # { name = "wakatime"; src = pkgs.fishPlugins.wakatime-fish.src; } 20 | { name = "forgit"; src = pkgs.fishPlugins.forgit.src; } 21 | { name = "done"; src = pkgs.fishPlugins.done.src; } 22 | { name = "fzf-fish"; src = pkgs.fishPlugins.fzf-fish.src; } 23 | { name = "pisces"; src = pkgs.fishPlugins.pisces.src; } 24 | { 25 | name = "zoxide"; 26 | src = pkgs.fetchFromGitHub { 27 | owner = "icezyclon"; 28 | repo = "zoxide.fish"; 29 | rev = "main"; 30 | hash = "sha256-OjrX0d8VjDMxiI5JlJPyu/scTs/fS/f5ehVyhAA/KDM="; 31 | }; 32 | } 33 | { 34 | name = "fish-eza"; 35 | src = pkgs.fetchFromGitHub { 36 | owner = "scaryrawr"; 37 | repo = "fish-eza"; 38 | rev = "75b3253ac6317a1a8bda538ae50c44b0c7965093"; 39 | hash = "sha256-QsNZTidMdXXZMnTMLsHfDa/XUGzo+muzTw7Yc55svoU="; 40 | }; 41 | } 42 | ]; 43 | }; 44 | 45 | nix-your-shell = { 46 | enable = true; 47 | enableFishIntegration = true; 48 | }; 49 | 50 | pay-respects = { 51 | enable = true; 52 | enableFishIntegration = true; 53 | }; 54 | 55 | direnv = { 56 | enable = true; 57 | nix-direnv.enable = true; 58 | # enableFishIntegration = true; 59 | }; 60 | 61 | atuin = { 62 | enable = true; 63 | enableFishIntegration = true; 64 | }; 65 | 66 | zoxide = { 67 | enable = true; 68 | enableFishIntegration = true; 69 | }; 70 | 71 | carapace = { 72 | enable = true; 73 | enableFishIntegration = false; 74 | }; 75 | 76 | eza = { 77 | enable = true; 78 | enableFishIntegration = true; 79 | colors = "auto"; 80 | git = true; 81 | icons = "auto"; 82 | }; 83 | 84 | fzf = { 85 | enable = true; 86 | enableFishIntegration = true; 87 | }; 88 | 89 | starship = { 90 | enable = true; 91 | enableNushellIntegration = true; 92 | settings = builtins.fromTOML (builtins.readFile ../nushell/config/starship.toml); 93 | }; 94 | }; 95 | } 96 | -------------------------------------------------------------------------------- /users/modules/gammastep.nix: -------------------------------------------------------------------------------- 1 | {...}: { 2 | services.gammastep = { 3 | enable = true; 4 | provider = "geoclue2"; 5 | }; 6 | } 7 | -------------------------------------------------------------------------------- /users/modules/git.nix: -------------------------------------------------------------------------------- 1 | {pkgs, ...}: { 2 | home.packages = with pkgs; [ 3 | openssl 4 | gitui 5 | gh 6 | jujutsu 7 | ]; 8 | 9 | programs.git = { 10 | enable = true; 11 | userName = "Suyashtnt"; 12 | userEmail = "suyashtnt@gmail.com"; 13 | package = pkgs.gitFull; 14 | extraConfig = { 15 | init = {defaultBranch = "main";}; 16 | 17 | difftool = { prompt = false; tool = "difftastic"; }; 18 | "difftool \"difftastic\"" = { 19 | cmd = ''difft "$LOCAL" "$REMOTE"''; 20 | }; 21 | 22 | credential = { 23 | credentialStore = "secretservice"; 24 | helper = "${pkgs.git-credential-manager}/bin/git-credential-manager"; 25 | }; 26 | 27 | # Sign commits 28 | commit.gpgsign = true; 29 | gpg.format = "ssh"; 30 | gpg.ssh.allowedSignersFile = "~/.ssh/allowed_signers"; 31 | user.signingkey = "~/.ssh/id_ed25519.pub"; 32 | }; 33 | lfs.enable = true; 34 | difftastic = { 35 | enable = true; 36 | background = "dark"; 37 | }; 38 | }; 39 | 40 | programs.gpg.enable = true; 41 | 42 | services = { 43 | gpg-agent = { 44 | enable = true; 45 | pinentryPackage = pkgs.pinentry-gnome3; 46 | defaultCacheTtl = 1800; 47 | maxCacheTtl = 7200; 48 | }; 49 | }; 50 | } 51 | -------------------------------------------------------------------------------- /users/modules/gtk.nix: -------------------------------------------------------------------------------- 1 | {pkgs, ...}: { 2 | gtk = { 3 | enable = true; 4 | iconTheme.name = "Papirus-Dark"; 5 | iconTheme.package = pkgs.papirus-icon-theme; 6 | 7 | gtk4.extraConfig = { 8 | gtk-xft-antialias = 1; 9 | gtk-xft-hinting = 1; 10 | gtk-xft-hintstyle = "hintslight"; 11 | gtk-xft-rgba = "rgb"; 12 | }; 13 | gtk3.extraConfig = { 14 | gtk-xft-antialias = 1; 15 | gtk-xft-hinting = 1; 16 | gtk-xft-hintstyle = "hintslight"; 17 | gtk-xft-rgba = "rgb"; 18 | }; 19 | gtk2.extraConfig = '' 20 | gtk-xft-antialias=1 21 | gtk-xft-hinting=1 22 | gtk-xft-hintstyle="hintslight" 23 | gtk-xft-rgba="rgb" 24 | ''; 25 | }; 26 | 27 | qt = { 28 | enable = true; 29 | style.package = with pkgs; [ 30 | libsForQt5.qtstyleplugin-kvantum 31 | qt6Packages.qtstyleplugin-kvantum 32 | ]; 33 | }; 34 | } 35 | -------------------------------------------------------------------------------- /users/modules/helix/config/helix.scm: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Suya1671/commafiles/386603e0af2253d673f5299952eeaee37493b644/users/modules/helix/config/helix.scm -------------------------------------------------------------------------------- /users/modules/helix/default.nix: -------------------------------------------------------------------------------- 1 | {lib, config, pkgs, ... }: { 2 | tntman.home.editor = { 3 | executable = "${pkgs.helix}/bin/hx"; 4 | name = "Helix"; 5 | }; 6 | 7 | programs.helix = { 8 | enable = true; 9 | defaultEditor = true; 10 | # languages = { 11 | # language-server.copilot = { 12 | # command = "${pkgs.helix-gpt}/bin/helix-gpt --handler copilot --copilotKey $(cat /run/secrets/copilot/key)"; 13 | # }; 14 | 15 | # language = [ 16 | # { 17 | # name = "rust"; 18 | # language-servers = [ 19 | # "rust-analyzer" 20 | # "copilot" 21 | # ]; 22 | # } 23 | # { 24 | # name = "typescript"; 25 | # language-servers = [ 26 | # "typescript-language-server" 27 | # "copilot" 28 | # ]; 29 | # } 30 | # ]; 31 | # }; 32 | settings = { 33 | theme = lib.mkForce "kleur"; 34 | editor = { 35 | bufferline = "multiple"; 36 | cursorline = true; 37 | line-number = "relative"; 38 | true-color = true; 39 | 40 | cursor-shape = { 41 | insert = "bar"; 42 | normal = "block"; 43 | select = "underline"; 44 | }; 45 | 46 | lsp = { 47 | display-messages = true; 48 | display-inlay-hints = true; 49 | }; 50 | 51 | indent-guides = { 52 | character = "╎"; 53 | render = true; 54 | }; 55 | }; 56 | keys = { 57 | normal = { 58 | "A-<" = "goto_previous_buffer"; 59 | "A->" = "goto_next_buffer"; 60 | "A-w" = ":buffer-close"; 61 | "A-/" = "repeat_last_motion"; 62 | X = ["extend_line_up" "extend_to_line_bounds"]; 63 | "A-x" = "extend_to_line_bounds"; 64 | # move 6 down 65 | J = ["move_visual_line_down" "move_visual_line_down" "move_visual_line_down" "move_visual_line_down" "move_visual_line_down" "move_visual_line_down" ]; 66 | # ditto 67 | K = ["move_visual_line_up" "move_visual_line_up" "move_visual_line_up" "move_visual_line_up" "move_visual_line_up" "move_visual_line_up" ]; 68 | } // lib.optionalAttrs (config.programs.yazi.enable) { 69 | # edit file opener 70 | "space"."e" = ":run-shell-command zellij run -fc -- yazi --chooser-file /tmp/yazi-chooser-file"; 71 | # open file 72 | "space"."o" = let 73 | yazi-chooser = pkgs.writeShellScriptBin "yazi-chooser" '' 74 | TEMP="/tmp/yazi-chooser-file" 75 | 76 | echo >> $TEMP 77 | while read -r line 78 | do 79 | echo "$line" 80 | done < "$TEMP" 81 | ''; 82 | in [":new" ":insert-output ${yazi-chooser}/bin/yazi-chooser" "split_selection_on_newline" "goto_file" "goto_last_modification" "goto_last_modified_file" ":buffer-close!"]; 83 | }; 84 | 85 | select = { 86 | X = ["extend_line_up" "extend_to_line_bounds"]; 87 | "A-x" = "extend_to_line_bounds"; 88 | }; 89 | }; 90 | }; 91 | }; 92 | } 93 | 94 | -------------------------------------------------------------------------------- /users/modules/hyprland/default.nix: -------------------------------------------------------------------------------- 1 | { 2 | pkgs, 3 | lib, 4 | ... 5 | }@args: 6 | with lib; let 7 | mkService = lib.recursiveUpdate { 8 | Unit.PartOf = ["graphical-session.target"]; 9 | Unit.After = ["graphical-session.target"]; 10 | Install.WantedBy = ["graphical-session.target"]; 11 | }; 12 | 13 | ocr = pkgs.writeShellScriptBin "ocr" '' 14 | #!/bin/bash 15 | grim -g "$(slurp -w 0 -b eebebed2)" /tmp/ocr.png && tesseract /tmp/ocr.png /tmp/ocr-output && wl-copy < /tmp/ocr-output.txt && notify-send "OCR" "Text copied!" && rm /tmp/ocr-output.txt -f 16 | ''; 17 | 18 | screenshot = pkgs.writeShellScriptBin "screenshot" '' 19 | #!/bin/bash 20 | hyprctl keyword animation "fadeOut,0,8,slow" && ${pkgs.grim}/bin/grim -g "$(${pkgs.slurp}/bin/slurp -w 0 -b 5e81acd2)" - | pngquant -q 75 | ${pkgs.wl-clipboard}/bin/wl-copy --type image/png; hyprctl keyword animation "fadeOut,1,8,slow" 21 | ''; 22 | in { 23 | home.packages = with pkgs; [ 24 | xdg-desktop-portal-hyprland 25 | libnotify 26 | brightnessctl 27 | pamixer 28 | python39Packages.requests 29 | slurp 30 | tesseract5 31 | ocr 32 | grim 33 | screenshot 34 | wl-clipboard 35 | pngquant 36 | swww 37 | libsForQt5.qt5.qtwayland 38 | ]; 39 | 40 | wayland.windowManager.hyprland = { 41 | enable = true; 42 | package = pkgs.hyprland; 43 | 44 | xwayland.enable = true; 45 | systemd.enable = true; 46 | 47 | extraConfig = import ./hyprland.conf.nix args; 48 | }; 49 | 50 | systemd.user.services.swww = mkService { 51 | Unit.Description = "Wallpaper chooser"; 52 | Service.ExecStart = "${pkgs.swww}/bin/swww init --no-daemon"; 53 | }; 54 | } 55 | -------------------------------------------------------------------------------- /users/modules/hyprland/hyprland.conf.nix: -------------------------------------------------------------------------------- 1 | { config, ... }: let 2 | theme = config.lib.stylix.colors; 3 | in '' 4 | monitor=HDMI-A-3,preferred,0x0,1 5 | monitor=HDMI-A-2,preferred,1920x0,1 6 | 7 | workspace=HDMI-A-3,1 8 | 9 | input { 10 | kb_file= 11 | kb_layout= 12 | kb_variant= 13 | kb_model= 14 | kb_options= 15 | kb_rules= 16 | 17 | follow_mouse=1 18 | 19 | touchpad { 20 | natural_scroll=no 21 | } 22 | 23 | sensitivity=0 # -1.0 - 1.0, 0 means no modification. 24 | } 25 | 26 | general { 27 | gaps_in=5 28 | gaps_out=10 29 | border_size=3 30 | col.active_border=0xff${theme.base0D} 0xff${theme.base08} 0xff${theme.base0A} 60deg 31 | col.inactive_border=0x00${theme.base02} 32 | apply_sens_to_raw=0 # whether to apply the sensitivity to raw input (e.g. used by games where you aim using your mouse) 33 | } 34 | 35 | decoration { 36 | rounding=16 37 | 38 | blur { 39 | enabled=1 40 | size = 8 41 | passes = 4 42 | } 43 | 44 | drop_shadow=0 45 | shadow_range=12 46 | shadow_render_power=2 47 | col.shadow=0xff${theme.base0E} 48 | col.shadow_inactive=0xff${theme.base03} 49 | } 50 | 51 | bezier=OverShot,0.47,0.4,0.1,1.8 52 | bezier=MaterialStandard,0.2, 0.0, 0, 1.0 53 | bezier=MaterialEmphasizedDecelerate,0.05, 0.7, 0.1, 1.0 54 | bezier=MaterialEmphasizedAccelerate,0.3f, 0f, 0.8f, 0.15f 55 | 56 | animations { 57 | enabled=1 58 | 59 | animation=windowsIn,1,4,MaterialEmphasizedDecelerate,slide 60 | animation=windowsOut,1,3,MaterialEmphasizedAccelerate,slide 61 | animation=windowsMove,1,3,MaterialStandard,slide 62 | 63 | animation=border,1,2,MaterialStandard 64 | animation=fade,1,2,MaterialStandard 65 | animation=workspaces,1,5,OverShot,slide 66 | } 67 | 68 | dwindle { 69 | pseudotile=1 # enable pseudotiling on dwindle 70 | preserve_split=1 71 | } 72 | 73 | windowrule = opacity 0.99, obsidian 74 | 75 | exec-once=swww init 76 | exec-once=ags 77 | exec-once=swww img -t wipe --transition-angle 30 --transition-bezier 0.41,0.26,0.98,1 --transition-ttep 20 --transition-fps 60 --transition-duration 0.6 /home/tntman/commafiles/wallpapers/Particles.png 78 | exec=dbus-update-activation-environment --systemd WAYLAND_DISPLAY XDG_CURRENT_DESKTOP=Hyprland 79 | 80 | # some nice mouse binds 81 | bindm=SUPER,mouse:272,movewindow 82 | bindm=SUPER,mouse:273,resizewindow 83 | 84 | # window management 85 | bind=SUPERSHIFT,C,killactive, 86 | bind=SUPER,V,togglefloating, 87 | bind=SUPERSHIFT,F,fullscreen,0 88 | 89 | # layout 90 | bind=SUPER,T,togglegroup 91 | bind=SUPER,H,changegroupactive,b 92 | bind=SUPER,L,changegroupactive,f 93 | bind=SUPER,F,togglesplit 94 | 95 | # utils 96 | bind=SUPER,Q,exec, [float;tile] ${config.tntman.home.terminal.executable} 97 | bind=SUPERSHIFT,L,exec,swaylock 98 | bind=SUPERSHIFT,P,exec,nu -c 'spotify_player get key playback | from json | get item.external_urls.spotify | wl-copy; notify-send "copied current song to clipboard!"' 99 | 100 | # screenshot 101 | bind=SUPER,S,exec,screenshot 102 | bind=SUPERCTRL,S,exec,ocr 103 | bind=SUPERSHIFT,S,exec,grim - | wl-copy -t image/png && notify-send "Screenshot copied to clipboard!" 104 | 105 | # ags 106 | bind=SUPER,w,exec,ags -r 'togglePowerMode();' 107 | bind=SUPER,p,exec,ags -r 'toggleMusicOnly();' 108 | bind=SUPER,d,exec,ags -r 'toggleAppLauncher();' 109 | 110 | layerrule = blur, powermode-.* 111 | layerrule = blur, applauncher 112 | layerrule = blur, lyrics-terminal 113 | layerrule = ignorealpha 0.4, powermode-.* 114 | layerrule = ignorealpha 0.4, applauncher 115 | layerrule = ignorealpha 0.4, lyrics-terminal 116 | 117 | bind=SUPER,left,movefocus,l 118 | bind=SUPER,right,movefocus,r 119 | bind=SUPER,up,movefocus,u 120 | bind=SUPER,down,movefocus,d 121 | 122 | bind=SUPER,1,workspace,1 123 | bind=SUPER,2,workspace,2 124 | bind=SUPER,3,workspace,3 125 | bind=SUPER,4,workspace,4 126 | bind=SUPER,5,workspace,5 127 | bind=SUPER,6,workspace,6 128 | bind=SUPER,7,workspace,7 129 | bind=SUPER,8,workspace,8 130 | bind=SUPER,9,workspace,9 131 | bind=SUPER,0,workspace,10 132 | 133 | bind=SUPERSHIFT,1,movetoworkspace,1 134 | bind=SUPERSHIFT,2,movetoworkspace,2 135 | bind=SUPERSHIFT,3,movetoworkspace,3 136 | bind=SUPERSHIFT,4,movetoworkspace,4 137 | bind=SUPERSHIFT,5,movetoworkspace,5 138 | bind=SUPERSHIFT,6,movetoworkspace,6 139 | bind=SUPERSHIFT,7,movetoworkspace,7 140 | bind=SUPERSHIFT,8,movetoworkspace,8 141 | bind=SUPERSHIFT,9,movetoworkspace,9 142 | bind=SUPERSHIFT,0,movetoworkspace,10 143 | 144 | bind=SUPER,mouse_down,workspace,e+1 145 | bind=SUPER,mouse_up,workspace,e-1 146 | '' 147 | -------------------------------------------------------------------------------- /users/modules/keyring.nix: -------------------------------------------------------------------------------- 1 | { ... }: { 2 | services.gnome-keyring.enable = true; 3 | } 4 | -------------------------------------------------------------------------------- /users/modules/kitty/default.nix: -------------------------------------------------------------------------------- 1 | {config, ...}: { 2 | programs.kitty = { 3 | enable = true; 4 | extraConfig = builtins.readFile ./kitty.conf; 5 | }; 6 | 7 | tntman.home.terminal = { 8 | executable = "${config.programs.kitty.package}/bin/kitty"; 9 | name = "kitty"; 10 | }; 11 | } 12 | -------------------------------------------------------------------------------- /users/modules/kitty/kitty.conf: -------------------------------------------------------------------------------- 1 | # vim:ft=kitty 2 | 3 | # The basic colors 4 | foreground #dadbf8 5 | background #09081b 6 | selection_foreground #141327 7 | selection_background #e7e8ff 8 | 9 | dynamic_background_opacity yes 10 | background_opacity 0.6 11 | 12 | # Cursor colors 13 | cursor #acaaff 14 | cursor_text_color #09081b 15 | 16 | # URL underline color when hovering with mouse 17 | url_color #44a8e7 18 | 19 | # Kitty window border colors 20 | active_border_color #acaaff 21 | inactive_border_color #45455d 22 | bell_border_color #ea9d00 23 | 24 | # OS Window titlebar colors 25 | wayland_titlebar_color system 26 | macos_titlebar_color system 27 | 28 | # Tab bar colors 29 | active_tab_foreground #433889 30 | active_tab_background #acaaff 31 | inactive_tab_foreground #adaeca 32 | inactive_tab_background #45455d 33 | tab_bar_background #060516 34 | 35 | # Colors for marks (marked text in the terminal) 36 | mark1_foreground #09081b 37 | mark1_background #acaaff 38 | mark2_foreground #09081b 39 | mark2_background #ab8be3 40 | mark3_foreground #09081b 41 | mark3_background #44a8e7 42 | 43 | # The 16 terminal colors 44 | 45 | # black 46 | color0 #2b2b41 47 | color8 #60607a 48 | 49 | # red 50 | color1 #ff5d66 51 | color9 #ff5d66 52 | 53 | # green 54 | color2 #27b892 55 | color10 #27b892 56 | 57 | # yellow 58 | color3 #ea9d00 59 | color11 #ea9d00 60 | 61 | # blue 62 | color4 #44a8e7 63 | color12 #44a8e7 64 | 65 | # magenta 66 | color5 #acaaff 67 | color13 #acaaff 68 | 69 | # cyan 70 | color6 #00c2ba 71 | color14 #00c2ba 72 | 73 | # white 74 | color7 #e7e8ff 75 | color15 #dadbf8 76 | 77 | window_margin_width 0 78 | tab_bar_min_tabs 1 79 | tab_bar_edge bottom 80 | tab_bar_style hidden 81 | tab_powerline_style slanted 82 | tab_title_template {title}{' :{}:'.format(num_windows) if num_windows > 1 else ''} 83 | -------------------------------------------------------------------------------- /users/modules/kleur.nix: -------------------------------------------------------------------------------- 1 | {inputs, pkgs, lib, ...}: let 2 | path = inputs.kleur.themes.${pkgs.system}.dark; 3 | in { 4 | xdg.configFile = { 5 | "gtk-3.0/gtk.css".source = lib.mkForce "${path.build}/gtk-3.css"; 6 | "gtk-4.0/gtk.css".source = lib.mkForce "${path.build}/gtk-4.css"; 7 | "zed/themes/kleur.json".source = inputs.kleur.themes.${pkgs.system}.zed; 8 | "helix/themes/kleur.toml".source = "${path.build}/helix.toml"; 9 | }; 10 | } 11 | -------------------------------------------------------------------------------- /users/modules/laptop.nix: -------------------------------------------------------------------------------- 1 | { ... }: { 2 | services = { 3 | batsignal = { 4 | enable = true; 5 | extraArgs = "-c 10 -w 35 -f 95"; 6 | }; 7 | 8 | mpris-proxy.enable = true; 9 | }; 10 | } 11 | -------------------------------------------------------------------------------- /users/modules/neovim/config/fnl/config.fnl: -------------------------------------------------------------------------------- 1 | (tset vim.wo :relativenumber true) 2 | (tset vim.wo :number true) 3 | (tset vim.opt :guifont 4 | "Comic Code Ligatures,ComicCodeLigatures Nerd Font,JetBrainsMono Nerd Font Mono:h13") 5 | 6 | (tset vim.opt :mouse :a) 7 | (tset vim.opt :clipboard :unnamedplus) 8 | (tset vim.opt :linespace 1) 9 | 10 | ;; for nvim-ufo 11 | (tset vim.o :foldcolumn :1) 12 | (tset vim.o :foldlevel 99) 13 | (tset vim.o :foldlevelstart 99) 14 | (tset vim.o :foldenable true) 15 | 16 | (tset vim.g :maplocalleader " m") 17 | (tset vim.g :mapleader " ") 18 | 19 | (tset vim.g :coq_settings {:auto_start :shut-up}) 20 | 21 | ;; https://github.com/neovide/neovide/pull/1870 60 for wayland, else it breaks 22 | (tset vim.g :neovide_refresh_rate 60) 23 | (tset vim.g :neovide_transparency 0.6) 24 | 25 | (tset vim.g :neovide_padding_top 0) 26 | (tset vim.g :neovide_padding_bottom 0) 27 | (tset vim.g :neovide_padding_left 0) 28 | (tset vim.g :neovide_padding_right 0) 29 | 30 | (tset vim.g :neovide_floating_blur_amount_x 10) 31 | (tset vim.g :neovide_floating_blur_amount_y 10) 32 | 33 | (local plugins (require :plugins)) 34 | (local plugins-folder (.. (vim.fn.stdpath :config) :/fnl/plugins)) 35 | 36 | (when (vim.loop.fs_stat plugins-folder) 37 | (each [file (vim.fs.dir plugins-folder)] 38 | (set-forcibly! file (file:match "^(.*)%.fnl$")) 39 | (let [plugin-spec (require (.. :plugins. file))] 40 | (each [_ spec (ipairs plugin-spec)] 41 | (table.insert plugins spec))))) 42 | 43 | (fn wrap-init [current-init wkeys] 44 | (if current-init 45 | (current-init)) 46 | (let [which-key (require :which-key) 47 | wkeys (if (= (type wkeys) :function) 48 | (wkeys) 49 | wkeys)] 50 | (if wkeys 51 | (which-key.register wkeys)))) 52 | 53 | (fn wrap-wk [specs] 54 | (each [_ spec (ipairs specs)] 55 | (if spec.wkeys 56 | (let [current-init spec.init] 57 | (tset spec :init #(wrap-init current-init spec.wkeys))))) 58 | specs) 59 | 60 | (local lazy (require :lazy)) 61 | (lazy.setup (wrap-wk plugins)) 62 | -------------------------------------------------------------------------------- /users/modules/neovim/config/fnl/macros.fnl: -------------------------------------------------------------------------------- 1 | ;; fennel-ls: macro-file 2 | 3 | (fn plugin! [name options] 4 | (tset options 1 name) 5 | options) 6 | 7 | {: plugin!} 8 | 9 | -------------------------------------------------------------------------------- /users/modules/neovim/config/fnl/plugins.fnl: -------------------------------------------------------------------------------- 1 | [:rktjmp/hotpot.nvim 2 | :editorconfig/editorconfig-vim 3 | :kaarmu/typst.vim 4 | :wakatime/vim-wakatime 5 | 6 | {1 :eraserhd/parinfer-rust 7 | :build "nix-shell --run \"cargo build --release \""} 8 | 9 | {1 :numToStr/Comment.nvim :config #((. (require :Comment) :setup))} 10 | 11 | {1 :mrjones2014/smart-splits.nvim 12 | :config #((. (require :smart-splits) :setup))} 13 | 14 | {1 :s1n7ax/nvim-window-picker 15 | :name :window-picker 16 | :event :VeryLazy 17 | :version :2.* 18 | :config #((. (require :window-picker) :setup))}] 19 | 20 | 21 | -------------------------------------------------------------------------------- /users/modules/neovim/config/fnl/plugins/colourscheme.fnl: -------------------------------------------------------------------------------- 1 | (fn config [] 2 | (let [catppuccin (require :catppuccin) 3 | integrations {:fidget true 4 | :leap true 5 | :lsp_saga true 6 | :neotree true 7 | :notify true 8 | :treesitter_context true 9 | :treesitter true 10 | :ts_rainbow2 true 11 | :harpoon true 12 | :which_key true}] 13 | (catppuccin.setup {: integrations :term_colors true}) 14 | (vim.api.nvim_cmd {:cmd :colorscheme :args [:catppuccin]} {}))) 15 | 16 | [{1 :catppuccin/nvim :name :catppuccin : config :priority 1000}] 17 | -------------------------------------------------------------------------------- /users/modules/neovim/config/fnl/plugins/flash.fnl: -------------------------------------------------------------------------------- 1 | (local wkeys #(let [flash (require :flash)] 2 | {:s [#(flash.jump) "Flash Jump"]})) 3 | 4 | [;; Folke you absolute madlad for creating lazy, which-key, trouble, AND this 5 | {1 :folke/flash.nvim 6 | ;; @type Flash.Config 7 | :opts {} 8 | :event :VeryLazy 9 | : wkeys}] 10 | -------------------------------------------------------------------------------- /users/modules/neovim/config/fnl/plugins/focus.fnl: -------------------------------------------------------------------------------- 1 | (local wkeys 2 | {: {:r [:FocusToggle "Toggle automatic split resizing"] 3 | :s [:FocusSplitNicely 4 | "Split window based on golden ratio"]}}) 5 | 6 | [{1 :nvim-focus/focus.nvim :version "*" :opts {:enable true} : wkeys}] 7 | -------------------------------------------------------------------------------- /users/modules/neovim/config/fnl/plugins/harpoon.fnl: -------------------------------------------------------------------------------- 1 | (fn config [] 2 | (let [telescope (require :telescope) 3 | harpoon (require :harpoon)] 4 | (harpoon.setup {:tabline true}) 5 | (telescope.load_extension :harpoon))) 6 | 7 | (local wkeys #(let [harpoon (require :harpoon) 8 | list #(harpoon:list) 9 | ui harpoon.ui 10 | select (fn [n] (: (list) :select n))] 11 | {:m {:name :+harpoon 12 | :a [#(: (list) :append) "Add file"] 13 | :m [#(ui:toggle_quick_menu (list)) 14 | "Toggle quick menu"] 15 | :1 [#(select 1) "Goto file 1"] 16 | :2 [#(select 2) "Goto file 2"] 17 | :3 [#(select 3) "Goto file 3"] 18 | :4 [#(select 4) "Goto file 4"] 19 | :5 [#(select 5) "Goto file 5"] 20 | :f ["Telescope harpoon marks" 21 | "Harpoon marks"]}})) 22 | 23 | [{1 :ThePrimeagen/harpoon 24 | :dependencies [:nvim-lua/plenary.nvim] 25 | :branch :harpoon2 26 | : config 27 | : wkeys}] 28 | -------------------------------------------------------------------------------- /users/modules/neovim/config/fnl/plugins/keymap.fnl: -------------------------------------------------------------------------------- 1 | (local wkeys {:k [:Legendary "Keybind explorer"] 2 | :k [:gk "Go up"] 3 | :j [:gj "Go down"] 4 | : {1 "" 2 "Exit terminal mode" :mode :t} 5 | : [:zz "Half page down"] 6 | : [:zz "Half page up"]}) 7 | 8 | [{1 :mrjones2014/legendary.nvim 9 | :priority 100000 10 | :opts {:extensions {:lazy_nvim {:enable true :auto_register true} 11 | :smart_splits {:enable true} 12 | :which_key {:auto_register true}}} 13 | :lazy false 14 | : wkeys} 15 | {1 :folke/which-key.nvim 16 | :dependencies [:mrjones2014/smart-splits.nvim] 17 | :opts {:plugins {:spelling {:enabled true}} :ignore_missing true}}] 18 | -------------------------------------------------------------------------------- /users/modules/neovim/config/fnl/plugins/lsp.fnl: -------------------------------------------------------------------------------- 1 | (fn config [] 2 | (let [;; imports 3 | lspconfig (require :lspconfig) 4 | coq (require :coq) 5 | coq_3p (require :coq_3p) 6 | inc_rename (require :inc_rename) 7 | lsp-format (require :lsp-format) 8 | rust-tools (require :rust-tools) 9 | crates (require :crates) ;; server setup \/ 10 | servers [:tsserver 11 | :svelte 12 | :unocss 13 | :nil_ls 14 | :fennel_ls 15 | :lua_ls 16 | :typst_lsp 17 | :hls 18 | :marksman] 19 | settings {:typst_lsp {:exportPdf :onType}} 20 | capabilities (vim.lsp.protocol.make_client_capabilities)] 21 | 22 | (fn on-attach [client _bufnr] 23 | (lsp-format.on_attach client)) 24 | 25 | (set capabilities.textDocument.foldingRange 26 | {:dynamicRegistration false :lineFoldingOnly true}) 27 | (each [_ lsp (ipairs servers)] 28 | (let [settings (if (not= (. settings lsp) nil) (. settings lsp) {}) 29 | server (. lspconfig lsp)] 30 | (server.setup (coq.lsp_ensure_capabilities {: on-attach 31 | : settings 32 | : capabilities})))) 33 | (rust-tools.setup {:server (coq.lsp_ensure_capabilities {:on_attach on-attach 34 | :settings {:rust-analyzer {:checkOnSave {:command :clippy} 35 | :cargo {:sysroot :discover}}} 36 | : capabilities})}) 37 | ;; extra 38 | (inc_rename.setup) 39 | (lsp-format.setup) 40 | (coq_3p [{:src :copilot :short_name :COP :accept_key :}]) 41 | (crates.setup {:src {:coq {:enabled true :name :crates}}}))) 42 | 43 | (local wkeys {:r {1 #(.. ":IncRename " (vim.fn.expand :)) 44 | 2 "LSP Code Action" 45 | :expr true}}) 46 | 47 | [{1 :neovim/nvim-lspconfig 48 | :dependencies [:ms-jpq/coq_nvim 49 | :ms-jpq/coq.artifacts 50 | :ms-jpq/coq.thirdparty 51 | :github/copilot.vim 52 | :saecki/crates.nvim 53 | :simrat39/rust-tools.nvim 54 | :jose-elias-alvarez/null-ls.nvim 55 | :nvim-tree/nvim-web-devicons 56 | :nvim-treesitter/nvim-treesitter 57 | :smjonas/inc-rename.nvim 58 | :lukas-reineke/lsp-format.nvim 59 | :kevinhwang91/promise-async] 60 | : config 61 | : wkeys} 62 | {1 :j-hui/fidget.nvim 63 | :opts {:notification {:override_vim_notify true 64 | :window {:winblend 90 :border :rounded}}}}] 65 | -------------------------------------------------------------------------------- /users/modules/neovim/config/fnl/plugins/lspsaga.fnl: -------------------------------------------------------------------------------- 1 | (fn config [] 2 | (let [lspsaga (require :lspsaga)] 3 | (lspsaga.setup {:ui {:kind ((. (require :catppuccin.groups.integrations.lsp_saga) 4 | :custom_kind)) 5 | :border :rounded}}))) 6 | 7 | (local wkeys {: {1 "Lspsaga term_toggle" 8 | 2 "Toggle terminal" 9 | :mode [:n :t]} 10 | :g {:name :+LSP 11 | :r ["Lspsaga finder" "LSP Finder"] 12 | :d ["Lspsaga peek_definition" 13 | "LSP Preview Definition"] 14 | :D ["Lspsaga goto_definition" 15 | "LSP Go To Definition"] 16 | :t ["Lspsaga peek_type_definition" 17 | "LSP Preview Type"] 18 | :T ["Lspsaga goto_type_definition" "LSP Go To Type"]} 19 | :K ["Lspsaga hover_doc" "LSP Hover Doc"] 20 | :a ["Lspsaga code_action" "LSP Code Action"] 21 | "]e" ["Lspsaga diagnostic_jump_next" 22 | "LSP Next Diagnostic"] 23 | "[e" ["Lspsaga diagnostic_jump_prev" 24 | "LSP Prev Diagnostic"]}) 25 | 26 | [{1 :nvimdev/lspsaga.nvim : config : wkeys :event :VeryLazy}] 27 | -------------------------------------------------------------------------------- /users/modules/neovim/config/fnl/plugins/neotree.fnl: -------------------------------------------------------------------------------- 1 | (fn config [] 2 | (let [neo-tree (require :neo-tree)] 3 | (vim.cmd "let g:neo_tree_remove_legacy_commands = 1") 4 | (neo-tree.setup {:popup_border_style :rounded}))) 5 | 6 | (local wkeys {:p ["Neotree toggle position=float" 7 | "File explorer"]}) 8 | 9 | [{1 :nvim-neo-tree/neo-tree.nvim 10 | :branch :v3.x 11 | :dependencies [:nvim-tree/nvim-web-devicons 12 | :nvim-lua/plenary.nvim 13 | :MunifTanjim/nui.nvim] 14 | : config 15 | : wkeys}] 16 | -------------------------------------------------------------------------------- /users/modules/neovim/config/fnl/plugins/noice.fnl: -------------------------------------------------------------------------------- 1 | (local views {:cmdline_popup {:position {:col "50%" :row 5} :size {:height :auto :width 60}} 2 | :popupmenu {:border {:padding [0 1] :style :rounded} 3 | :position {:col "50%" :row 8} 4 | :relative :editor 5 | :size {:height 10 :width 60} 6 | :win_options {:winhighlight {:FloatBorder :DiagnosticInfo 7 | :Normal :Normal}}}}) 8 | 9 | [{1 :folke/noice.nvim 10 | :dependencies [:MunifTanjim/nui.nvim] 11 | :event :VeryLazy 12 | :opts {:lsp {:override {:cmp.entry.get_documentation true 13 | :vim.lsp.util.convert_input_to_markdown_lines true 14 | :vim.lsp.util.stylize_markdown true} 15 | :progress {:enabled false} 16 | :message {:enabled false}} 17 | : views 18 | :notify {:enabled false} 19 | :messages {:enabled false} 20 | :presets {:bottom_search true 21 | :command_palette true 22 | :inc_rename true 23 | :long_message_to_split true 24 | :lsp_doc_border true}}}] 25 | -------------------------------------------------------------------------------- /users/modules/neovim/config/fnl/plugins/rzip.fnl: -------------------------------------------------------------------------------- 1 | [{1 :lbrayner/vim-rzip :event :VeryLazy}] 2 | -------------------------------------------------------------------------------- /users/modules/neovim/config/fnl/plugins/statusline.fnl: -------------------------------------------------------------------------------- 1 | (fn config [] 2 | (let [gitsigns (require :gitsigns) 3 | statusline (require :evil_line_2)] 4 | 5 | ;; git intergration 6 | (gitsigns.setup) 7 | 8 | ;; global statusline 9 | (tset vim.opt :laststatus 3) 10 | ;; remove the line below 11 | (tset vim.opt :cmdheight 0) 12 | 13 | ;; basic statusline 14 | (local mocha ((. (require :catppuccin.palettes) :get_palette) :mocha)) 15 | (statusline.setup mocha))) 16 | 17 | [{ 1 :windwp/windline.nvim 18 | :dependencies [:lewis6991/gitsigns.nvim] 19 | :config config}] 20 | -------------------------------------------------------------------------------- /users/modules/neovim/config/fnl/plugins/telescope.fnl: -------------------------------------------------------------------------------- 1 | (local wkeys 2 | {: {: ["Telescope find_files" "Find File"] 3 | :b ["Telescope buffers" "Find Buffer"]} 4 | :f { 5 | :name "file" 6 | :f ["Telescope find_files" "Find File"] 7 | :r ["Telescope oldfiles" "Recent Files"] 8 | :g ["Telescope live_grep" "Grep"] 9 | :m ["Telescope harpoon marks" "Harpoon marks"] 10 | :b ["Telescope buffers" "Buffers"]}}) 11 | 12 | [{1 :nvim-telescope/telescope.nvim 13 | :dependencies [:nvim-lua/plenary.nvim] 14 | :opts {} 15 | :event :VeryLazy 16 | : wkeys}] 17 | -------------------------------------------------------------------------------- /users/modules/neovim/config/fnl/plugins/treesitter.fnl: -------------------------------------------------------------------------------- 1 | (fn config [] 2 | (let [treesitter (require :nvim-treesitter.configs) ;; imports 3 | context (require :treesitter-context) 4 | rainbow (require :rainbow-delimiters) 5 | rainbow-setup (require :rainbow-delimiters.setup) ;; config 6 | highlight {:enable true :additional_vim_regex_highlighting true} 7 | textobjects {:move {:enable true 8 | :set_jumps true 9 | :goto_next_start {"]m" "@function.outer" 10 | "]]" {:query "@indent.begin" 11 | :query_group :indents}} 12 | :goto_next_end {"]M" "@function.outer" 13 | "][" {:query "@indent.begin" 14 | :query_group :indents}} 15 | :goto_previous_start {"[m" "@function.outer" 16 | "[[" {:query "@indent.begin" 17 | :query_group :indents}} 18 | :goto_previous_end {"[M" "@function.outer" 19 | "][" {:query "@indent.begin" 20 | :query_group :indents}}}} 21 | textsubject-keymaps {: :textsubjects-smart 22 | ";" :textsubjects-container-outer 23 | "," :textsubjects-container-inner} 24 | textsubjects {:enable true :keymaps textsubject-keymaps} 25 | strat {"" rainbow.strategy.global :html rainbow.strategy.local}] 26 | ;; config 27 | (treesitter.setup {: highlight : textobjects : textsubjects}) 28 | (context.setup) 29 | (rainbow-setup {:strategy strat}))) 30 | 31 | [{1 :nvim-treesitter/nvim-treesitter 32 | :event :VeryLazy 33 | :dependencies [:nvim-treesitter/nvim-treesitter-context 34 | :HiPhish/rainbow-delimiters.nvim 35 | :nvim-treesitter/nvim-treesitter-textobjects 36 | :RRethy/nvim-treesitter-textsubjects] 37 | : config}] 38 | -------------------------------------------------------------------------------- /users/modules/neovim/config/fnl/plugins/ufo.fnl: -------------------------------------------------------------------------------- 1 | (fn config [] 2 | (let [ufo (require :ufo)] 3 | (fn handler [virt-text lnum end-lnum width truncate] 4 | (let [new-virt-text {}] 5 | (var suffix (: "  %d " :format (- end-lnum lnum))) 6 | (local suf-width (vim.fn.strdisplaywidth suffix)) 7 | (local target-width (- width suf-width)) 8 | (var cur-width 0) 9 | (each [_ chunk (ipairs virt-text)] 10 | (var chunk-text (. chunk 1)) 11 | (var chunk-width (vim.fn.strdisplaywidth chunk-text)) 12 | (if (> target-width (+ cur-width chunk-width)) 13 | (table.insert new-virt-text chunk) 14 | (do 15 | (set chunk-text 16 | (truncate chunk-text (- target-width cur-width))) 17 | (local hl-group (. chunk 2)) 18 | (table.insert new-virt-text [chunk-text hl-group]) 19 | (set chunk-width (vim.fn.strdisplaywidth chunk-text)) 20 | (when (< (+ cur-width chunk-width) target-width) 21 | (set suffix 22 | (.. suffix 23 | (: " " :rep 24 | (- (- target-width cur-width) chunk-width))))) 25 | (lua :break))) 26 | (set cur-width (+ cur-width chunk-width))) 27 | (table.insert new-virt-text [suffix :MoreMsg]) 28 | new-virt-text)) 29 | 30 | (ufo.setup {:fold_virt_text_handler handler}))) 31 | 32 | (local wkeys #(let [ufo (require :ufo)] 33 | {:zR [#(ufo.openAllFolds) "Open all folds"] 34 | :zM [#(ufo.closeAllFolds) "Close all folds"]})) 35 | 36 | [{1 :kevinhwang91/nvim-ufo : config : wkeys :event :VeryLazy}] 37 | -------------------------------------------------------------------------------- /users/modules/neovim/config/init.lua: -------------------------------------------------------------------------------- 1 | local plugins_path = vim.fn.stdpath("data") .. "/lazy" 2 | 3 | -- bootstrap lazy 4 | local lazy_path = plugins_path .. "/lazy.nvim" 5 | if not vim.loop.fs_stat(lazy_path) then 6 | vim.notify("Bootstrapping lazy.nvim...", vim.log.levels.INFO) 7 | vim.fn.system({ 8 | "git", 9 | "clone", 10 | "--filter=blob:none", 11 | "https://github.com/folke/lazy.nvim.git", 12 | "--branch=stable", -- latest stable release 13 | lazy_path, 14 | }) 15 | end 16 | 17 | -- bootstrap hotpot 18 | local hotpot_path = plugins_path .. "/hotpot.nvim" 19 | 20 | if vim.fn.empty(vim.fn.glob(hotpot_path)) > 0 then 21 | vim.notify("Bootstrapping hotpot.nvim...", vim.log.levels.INFO) 22 | vim.fn.system({ 'git', 'clone', 23 | 'https://github.com/rktjmp/hotpot.nvim', hotpot_path }) 24 | vim.cmd("helptags " .. hotpot_path .. "/doc") 25 | end 26 | 27 | vim.opt.runtimepath:prepend(lazy_path) 28 | vim.opt.runtimepath:prepend(hotpot_path) 29 | 30 | -- Enable fnl/ support 31 | require("hotpot").setup({ 32 | provide_require_fennel = true, 33 | compiler = { 34 | modules = { 35 | correlate = true, 36 | }, 37 | }, 38 | }) 39 | 40 | 41 | -- load config 42 | require("config") 43 | -------------------------------------------------------------------------------- /users/modules/neovim/config/lua/evil_line_2.lua: -------------------------------------------------------------------------------- 1 | -- I am too lazy to rewrite this in fennel rn 2 | -- TODO: rewrite in fennel when not lazy 3 | 4 | local windline = require('windline') 5 | local helper = require('windline.helpers') 6 | local b_components = require('windline.components.basic') 7 | 8 | local state = _G.WindLine.state 9 | local sep = helper.separators 10 | 11 | local lsp_comps = require('windline.components.lsp') 12 | local git_comps = require('windline.components.git') 13 | 14 | local hl_list = { 15 | Black = { 'white', 'black' }, 16 | White = { 'black', 'white' }, 17 | Inactive = { 'InactiveFg', 'InactiveBg' }, 18 | Active = { 'ActiveFg', 'ActiveBg' }, 19 | } 20 | local basic = {} 21 | 22 | local breakpoint_width = 90 23 | basic.divider = { b_components.divider, '' } 24 | basic.bg = { ' ', 'StatusLine' } 25 | 26 | local colors_mode = { 27 | Normal = { 'black', 'red', 'bold' }, 28 | Insert = { 'black', 'green', 'bold' }, 29 | Visual = { 'black', 'yellow', 'bold' }, 30 | Replace = { 'black', 'blue_light', 'bold' }, 31 | Command = { 'black', 'magenta', 'bold' }, 32 | NormalBefore = { 'red', 'black' }, 33 | InsertBefore = { 'green', 'black' }, 34 | VisualBefore = { 'yellow', 'black' }, 35 | ReplaceBefore = { 'blue_light', 'black' }, 36 | CommandBefore = { 'magenta', 'black' }, 37 | NormalAfter = { 'lavender', 'red' }, 38 | InsertAfter = { 'lavender', 'green' }, 39 | VisualAfter = { 'lavender', 'yellow' }, 40 | ReplaceAfter = { 'lavender', 'blue_light' }, 41 | CommandAfter = { 'lavender', 'magenta' }, 42 | } 43 | 44 | basic.vi_mode = { 45 | name = 'vi_mode', 46 | hl_colors = colors_mode, 47 | text = function() 48 | return { 49 | { sep.left_rounded, state.mode[2] .. "Before" }, 50 | { '  ', state.mode[2] }, 51 | { sep.left_rounded, state.mode[2] .. "After" }, 52 | } 53 | end, 54 | } 55 | 56 | basic.lsp_diagnos = { 57 | name = 'diagnostic', 58 | hl_colors = { 59 | red = { 'red', 'black' }, 60 | yellow = { 'yellow', 'black' }, 61 | blue = { 'blue', 'black' }, 62 | }, 63 | width = breakpoint_width, 64 | text = function(bufnr) 65 | if lsp_comps.check_lsp(bufnr) then 66 | return { 67 | { sep.left_rounded, { 'black', 'lavender' } }, 68 | { lsp_comps.lsp_error({ format = ' %s', show_zero = true }), 'red' }, 69 | { lsp_comps.lsp_warning({ format = '  %s', show_zero = true }), 'yellow' }, 70 | { lsp_comps.lsp_hint({ format = ' 󰋼 %s', show_zero = true }), 'blue' }, 71 | { sep.right_rounded, { 'black', 'lavender' } }, 72 | } 73 | end 74 | return '' 75 | end, 76 | } 77 | 78 | basic.file = { 79 | name = 'file', 80 | hl_colors = { 81 | default = { 'black', 'lavender' }, 82 | lavender = { 'black', 'lavender' }, 83 | }, 84 | text = function(_, _, width) 85 | return { 86 | { b_components.cache_file_name('[No Name]', 'unique'), 'lavender' }, 87 | { b_components.file_modified(' '), 'lavender' }, 88 | } 89 | end, 90 | } 91 | 92 | basic.git = { 93 | name = 'git', 94 | hl_colors = { 95 | green = { 'green', 'black_light' }, 96 | red = { 'red', 'black_light' }, 97 | blue = { 'blue', 'black_light' }, 98 | }, 99 | width = breakpoint_width, 100 | text = function(bufnr) 101 | if git_comps.is_git(bufnr) then 102 | return { 103 | { git_comps.diff_added({ format = '  %s', show_zero = true }), 'green' }, 104 | { git_comps.diff_removed({ format = '  %s', show_zero = true }), 'red' }, 105 | { git_comps.diff_changed({ format = ' 󰿠 %s', show_zero = true }), 'blue' }, 106 | } 107 | end 108 | return '' 109 | end, 110 | } 111 | 112 | basic.lsp_name = { 113 | width = breakpoint_width, 114 | name = 'lsp_name', 115 | hl_colors = { 116 | magenta = { 'magenta', 'black_light' }, 117 | }, 118 | text = function(bufnr) 119 | if lsp_comps.check_lsp(bufnr) then 120 | return { 121 | { lsp_comps.lsp_name(), 'magenta' }, 122 | } 123 | end 124 | return { 125 | { b_components.cache_file_type({icon = true}), 'magenta' }, 126 | } 127 | end, 128 | } 129 | 130 | local default = { 131 | filetypes = { 'default' }, 132 | active = { 133 | { ' ', hl_list.Black }, 134 | basic.vi_mode, 135 | basic.file, 136 | basic.lsp_diagnos, 137 | basic.divider, 138 | { sep.left_rounded, { 'black_light', 'lavender' } }, 139 | basic.lsp_name, 140 | basic.git, 141 | { git_comps.git_branch(), { 'magenta', 'black_light' }, breakpoint_width }, 142 | { sep.right_rounded, { 'black_light', 'black' } }, 143 | { ' ', hl_list.Black }, 144 | }, 145 | inactive = { 146 | { b_components.full_file_name, hl_list.Inactive }, 147 | basic.file_name_inactive, 148 | basic.divider, 149 | basic.divider, 150 | { b_components.line_col, hl_list.Inactive }, 151 | { b_components.progress, hl_list.Inactive }, 152 | }, 153 | } 154 | 155 | local M = {} 156 | 157 | function M.setup(catppuccin_mocha) 158 | windline.setup({ 159 | colors_name = function(colors) 160 | for key, value in pairs(catppuccin_mocha) do 161 | colors[key] = value 162 | local new_key = key .. '_light' 163 | colors[new_key] = value 164 | end 165 | 166 | colors.black = catppuccin_mocha.crust 167 | colors.black_light = catppuccin_mocha.mantle 168 | 169 | colors.NormalFg = catppuccin_mocha.text 170 | colors.NormalBg = catppuccin_mocha.mantle 171 | colors.InactiveFg = catppuccin_mocha.overlay1 172 | colors.InactiveBg = catppuccin_mocha.crust 173 | colors.ActiveFg = catppuccin_mocha.text 174 | colors.ActiveBg = catppuccin_mocha.overlay0 175 | 176 | colors.TabSelectionBg= "#b8bb26" 177 | colors.TabSelectionFg= "#282828" 178 | 179 | return colors 180 | end, 181 | statuslines = { 182 | default 183 | }, 184 | }) 185 | end 186 | 187 | return M 188 | -------------------------------------------------------------------------------- /users/modules/neovim/default.nix: -------------------------------------------------------------------------------- 1 | { 2 | inputs, 3 | pkgs, 4 | lib, 5 | ... 6 | }: let 7 | custom-neovide-name = pkgs.craneLib.crateNameFromCargoToml { 8 | cargoToml = "${inputs.neovide-src}/Cargo.toml"; 9 | }; 10 | 11 | SKIA_SOURCE_DIR = let 12 | repo = pkgs.fetchFromGitHub { 13 | owner = "rust-skia"; 14 | repo = "skia"; 15 | # see rust-skia:skia-bindings/Cargo.toml#package.metadata.skia when updating 16 | rev = "m119-0.67.3"; 17 | sha256 = "sha256-U75NuJnQa5+SNlOrsBmdlvflGdjo3el63EeIsbnE7ms="; 18 | }; 19 | # The externals for skia are taken from skia/DEPS 20 | externals = pkgs.linkFarm "skia-externals" (lib.mapAttrsToList 21 | (name: value: { 22 | inherit name; 23 | path = pkgs.fetchgit value; 24 | }) 25 | (lib.importJSON ./skia-externals.json)); 26 | in 27 | pkgs.runCommand "source" {} '' 28 | cp -R ${repo} $out 29 | chmod -R +w $out 30 | ln -s ${externals} $out/third_party/externals 31 | ''; 32 | 33 | custom-neovide-deps = pkgs.craneLib.vendorCargoDeps { 34 | stdenv = pkgs.clangStdenv; 35 | src = inputs.neovide-src; 36 | 37 | cargoExtraArgs = "--locked"; 38 | 39 | inherit SKIA_SOURCE_DIR; 40 | SKIA_GN_COMMAND = "${pkgs.gn}/bin/gn"; 41 | SKIA_NINJA_COMMAND = "${pkgs.ninja}/bin/ninja"; 42 | 43 | buildInputs = with pkgs; 44 | [ 45 | SDL2 46 | fontconfig 47 | rustPlatform.bindgenHook 48 | ] 49 | ++ lib.optionals stdenv.isDarwin [ 50 | darwin.apple_sdk.frameworks.AppKit 51 | ]; 52 | }; 53 | 54 | custom-neovide = pkgs.clangStdenv.mkDerivation (rec { 55 | stdenv = pkgs.clangStdenv; 56 | src = inputs.neovide-src; 57 | 58 | nativeBuildInputs = with pkgs; 59 | [ 60 | makeWrapper 61 | pkg-config 62 | python3 # skia 63 | removeReferencesTo 64 | cargo 65 | rustc 66 | ] 67 | ++ lib.optionals stdenv.isDarwin [xcbuild]; 68 | 69 | inherit SKIA_SOURCE_DIR; 70 | SKIA_GN_COMMAND = "${pkgs.gn}/bin/gn"; 71 | SKIA_NINJA_COMMAND = "${pkgs.ninja}/bin/ninja"; 72 | 73 | buildInputs = with pkgs; 74 | [ 75 | SDL2 76 | fontconfig 77 | rustPlatform.bindgenHook 78 | ] 79 | ++ lib.optionals stdenv.isDarwin [ 80 | darwin.apple_sdk.frameworks.AppKit 81 | ]; 82 | 83 | buildPhase = '' 84 | mkdir -p .cargo 85 | cp ${custom-neovide-deps}/config.toml .cargo/config.toml 86 | cargo build --release --locked 87 | ''; 88 | 89 | installPhase = '' 90 | mkdir -p $out/bin 91 | cp target/release/neovide $out/bin/neovide 92 | ''; 93 | 94 | postFixup = let 95 | libPath = lib.makeLibraryPath (with pkgs; [ 96 | libglvnd 97 | libxkbcommon 98 | xorg.libXcursor 99 | xorg.libXext 100 | xorg.libXrandr 101 | xorg.libXi 102 | wayland 103 | ]); 104 | in '' 105 | # library skia embeds the path to its sources 106 | remove-references-to -t "$SKIA_SOURCE_DIR" \ 107 | $out/bin/neovide 108 | 109 | wrapProgram $out/bin/neovide \ 110 | --prefix LD_LIBRARY_PATH : ${libPath} 111 | ''; 112 | 113 | postInstall = '' 114 | for n in 16x16 32x32 48x48 256x256; do 115 | install -m444 -D "assets/neovide-$n.png" \ 116 | "$out/share/icons/hicolor/$n/apps/neovide.png" 117 | done 118 | install -m444 -Dt $out/share/icons/hicolor/scalable/apps assets/neovide.svg 119 | install -m444 -Dt $out/share/applications assets/neovide.desktop 120 | ''; 121 | 122 | disallowedReferences = [SKIA_SOURCE_DIR]; 123 | } 124 | // custom-neovide-name); 125 | in { 126 | home.packages = [ 127 | custom-neovide 128 | ]; 129 | 130 | programs.neovim = { 131 | enable = true; 132 | package = pkgs.neovim-nightly; 133 | extraPackages = with pkgs; [tree-sitter nodejs ripgrep fd unzip zig universal-ctags]; 134 | extraLuaConfig = builtins.readFile ./config/init.lua; 135 | }; 136 | 137 | xdg.configFile."nvim/lua".source = ./config/lua; 138 | xdg.configFile."nvim/fnl".source = ./config/fnl; 139 | } 140 | -------------------------------------------------------------------------------- /users/modules/neovim/skia-externals.json: -------------------------------------------------------------------------------- 1 | { 2 | "brotli": { 3 | "url": "https://skia.googlesource.com/external/github.com/google/brotli.git", 4 | "rev": "6d03dfbedda1615c4cba1211f8d81735575209c8", 5 | "sha256": "sha256-wnHEQY/NYS48sMPElUWSeLsETyQbWw2sMScc4geaPFA=" 6 | }, 7 | "d3d12allocator": { 8 | "url": "https://skia.googlesource.com/external/github.com/GPUOpen-LibrariesAndSDKs/D3D12MemoryAllocator.git", 9 | "rev": "169895d529dfce00390a20e69c2f516066fe7a3b", 10 | "sha256": "sha256-5DbR/3Lb0eMBpHNf7MtZOb1C0QrNlx/ZvPVbCxxF9eQ=" 11 | }, 12 | "expat": { 13 | "url": "https://chromium.googlesource.com/external/github.com/libexpat/libexpat.git", 14 | "rev": "441f98d02deafd9b090aea568282b28f66a50e36", 15 | "sha256": "sha256-FXTDGAK03jc2wvazhRKqtsFRKZUYS/9HLpZNp4JfZJI=" 16 | }, 17 | "freetype": { 18 | "url": "https://chromium.googlesource.com/chromium/src/third_party/freetype2.git", 19 | "rev": "45903920b984540bb629bc89f4c010159c23a89a", 20 | "sha256": "sha256-J3zPyZKJuwEzpVDkKehE05WbVqYw10NUVi7pBnIrudU=" 21 | }, 22 | "harfbuzz": { 23 | "url": "https://chromium.googlesource.com/external/github.com/harfbuzz/harfbuzz.git", 24 | "rev": "4cfc6d8e173e800df086d7be078da2e8c5cfca19", 25 | "sha256": "sha256-rrstyAz7Eb8ZgFJZKUASY8nU4YFZAptd5VS9B2cs2Yg=" 26 | }, 27 | "icu": { 28 | "url": "https://chromium.googlesource.com/chromium/deps/icu.git", 29 | "rev": "a0718d4f121727e30b8d52c7a189ebf5ab52421f", 30 | "sha256": "sha256-BI3f/gf9GNDvSfXWeRHKBvznSz4mjXY8rM24kK7QvOM=" 31 | }, 32 | "libjpeg-turbo": { 33 | "url": "https://chromium.googlesource.com/chromium/deps/libjpeg_turbo.git", 34 | "rev": "ed683925e4897a84b3bffc5c1414c85b97a129a3", 35 | "sha256": "sha256-DYJP3phe4OzCtRN2pMc07ITTWR8MuIlOWWg9PBsQAVw=" 36 | }, 37 | "libpng": { 38 | "url": "https://skia.googlesource.com/third_party/libpng.git", 39 | "rev": "386707c6d19b974ca2e3db7f5c61873813c6fe44", 40 | "sha256": "sha256-67kf5MBsnBBi0bOfX/RKL52xpaCWm/ampltAI+EeQ+c=" 41 | }, 42 | "libwebp": { 43 | "url": "https://chromium.googlesource.com/webm/libwebp.git", 44 | "rev": "2af26267cdfcb63a88e5c74a85927a12d6ca1d76", 45 | "sha256": "sha256-bFRgxLX7mWHH5oYSUWi3Rj0bxkgBSFirNZYEZrfZUHU=" 46 | }, 47 | "vulkanmemoryallocator": { 48 | "url": "https://chromium.googlesource.com/external/github.com/GPUOpen-LibrariesAndSDKs/VulkanMemoryAllocator.git", 49 | "rev": "a6bfc237255a6bac1513f7c1ebde6d8aed6b5191", 50 | "sha256": "sha256-urUebQaPTgCECmm4Espri1HqYGy0ueAqTBu/VSiX/8I=" 51 | }, 52 | "spirv-cross": { 53 | "url": "https://chromium.googlesource.com/external/github.com/KhronosGroup/SPIRV-Cross.git", 54 | "rev": "6e1fb9b09efadee38748e0fd0e6210d329087e89", 55 | "sha256": "sha256-tNOhQBMZMSVIUiznO1YGUwmFZFe/AFWCrsRw426tPAs=" 56 | }, 57 | "wuffs": { 58 | "url": "https://skia.googlesource.com/external/github.com/google/wuffs-mirror-release-c.git", 59 | "rev": "e3f919ccfe3ef542cfc983a82146070258fb57f8", 60 | "sha256": "sha256-373d2F/STcgCHEq+PO+SCHrKVOo6uO1rqqwRN5eeBCw=" 61 | }, 62 | "zlib": { 63 | "url": "https://chromium.googlesource.com/chromium/src/third_party/zlib.git", 64 | "rev": "c876c8f87101c5a75f6014b0f832499afeb65b73", 65 | "sha256": "sha256-mwozVo8ymyrYN4tw+/ZnSI+xogSTZQ6PUBba/jQqRkE=" 66 | } 67 | } -------------------------------------------------------------------------------- /users/modules/niri.nix: -------------------------------------------------------------------------------- 1 | { 2 | config, 3 | pkgs, 4 | inputs, 5 | ... 6 | }: let 7 | theme = config.lib.stylix.colors; 8 | in { 9 | xdg.portal.extraPortals = [pkgs.xdg-desktop-portal-gtk pkgs.xdg-desktop-portal-gnome pkgs.gnome-keyring]; 10 | home.packages = [pkgs.swww pkgs.brightnessctl pkgs.wl-clipboard inputs.astal.packages.${pkgs.system}.default]; 11 | programs.niri.settings = { 12 | binds = with config.lib.niri.actions; let 13 | sh = spawn "sh" "-c"; 14 | in { 15 | "Mod+Shift+Slash".action = show-hotkey-overlay; 16 | 17 | "Mod+Q".action = spawn "wezterm"; 18 | "Mod+D".action = sh "astal launcher"; 19 | "Mod+W".action = sh "astal toggle all"; 20 | "Mod+P".action = sh "astal toggle right"; 21 | 22 | "Mod+F".action = fullscreen-window; 23 | "Mod+V".action = toggle-window-floating; 24 | 25 | "Mod+H".action = focus-column-left; 26 | "Mod+J".action = focus-window-or-workspace-down; 27 | "Mod+K".action = focus-window-or-workspace-up; 28 | "Mod+L".action = focus-column-right; 29 | 30 | "Mod+Shift+H".action = move-column-left; 31 | "Mod+Shift+J".action = move-window-down-or-to-workspace-down; 32 | "Mod+Shift+K".action = move-window-up-or-to-workspace-up; 33 | "Mod+Shift+L".action = move-column-right; 34 | 35 | "Mod+Left".action = focus-column-left; 36 | "Mod+Down".action = focus-window-or-workspace-down; 37 | "Mod+Up".action = focus-window-or-workspace-up; 38 | "Mod+Right".action = focus-column-right; 39 | 40 | "Mod+Shift+Left".action = move-column-left; 41 | "Mod+Shift+Down".action = move-window-down-or-to-workspace-down; 42 | "Mod+Shift+Up".action = move-window-up-or-to-workspace-up; 43 | "Mod+Shift+Right".action = move-column-right; 44 | 45 | "Mod+Minus".action = set-column-width "-10%"; 46 | "Mod+Shift+Equal".action = set-column-width "+10%"; 47 | 48 | "Mod+Ctrl+Minus".action = set-window-height "-10%"; 49 | "Mod+Ctrl+Shift+Equal".action = set-window-height "+10%"; 50 | 51 | "Mod+S".action = screenshot; 52 | "Mod+Shift+S".action = screenshot-screen; 53 | 54 | "Mod+WheelScrollDown" = { 55 | cooldown-ms = 150; 56 | action = focus-workspace-down; 57 | }; 58 | 59 | "Mod+WheelScrollUp" = { 60 | cooldown-ms = 150; 61 | action = focus-workspace-up; 62 | }; 63 | 64 | "Mod+Shift+WheelScrollDown".action = focus-column-right; 65 | "Mod+Shift+WheelScrollUp".action = focus-column-left; 66 | 67 | "Mod+Shift+C".action = close-window; 68 | "Mod+Ctrl+Shift+C".action = quit; 69 | 70 | "Mod+Comma".action = consume-window-into-column; 71 | "Mod+Period".action = expel-window-from-column; 72 | 73 | "XF86AudioRaiseVolume".action = sh "wpctl set-volume @DEFAULT_AUDIO_SINK@ 0.1+"; 74 | "XF86AudioLowerVolume".action = sh "wpctl set-volume @DEFAULT_AUDIO_SINK@ 0.1-"; 75 | "XF86AudioMute".action = sh "wpctl set-mute @DEFAULT_AUDIO_SINK@ toggle"; 76 | 77 | "XF86MonBrightnessUp".action = sh "brightnessctl set 5%+"; 78 | "XF86MonBrightnessDown".action = sh "brightnessctl set 5%-"; 79 | "XF86Calculator".action = sh "${pkgs.qalculate-gtk}/bin/qalculate-gtk"; 80 | 81 | "Mod+1".action = focus-workspace 1; 82 | "Mod+2".action = focus-workspace 2; 83 | "Mod+3".action = focus-workspace 3; 84 | "Mod+4".action = focus-workspace 4; 85 | "Mod+5".action = focus-workspace 5; 86 | "Mod+6".action = focus-workspace 6; 87 | "Mod+7".action = focus-workspace 7; 88 | "Mod+8".action = focus-workspace 8; 89 | "Mod+9".action = focus-workspace 9; 90 | 91 | "Mod+Shift+1".action = move-column-to-workspace 1; 92 | "Mod+Shift+2".action = move-column-to-workspace 2; 93 | "Mod+Shift+3".action = move-column-to-workspace 3; 94 | "Mod+Shift+4".action = move-column-to-workspace 4; 95 | "Mod+Shift+5".action = move-column-to-workspace 5; 96 | "Mod+Shift+6".action = move-column-to-workspace 6; 97 | "Mod+Shift+7".action = move-column-to-workspace 7; 98 | "Mod+Shift+8".action = move-column-to-workspace 8; 99 | "Mod+Shift+9".action = move-column-to-workspace 9; 100 | }; 101 | 102 | environment = { 103 | DISPLAY = ":0"; # xwayland-satellite 104 | }; 105 | 106 | outputs."eDP-1" = { 107 | variable-refresh-rate = true; 108 | }; 109 | 110 | spawn-at-startup = [ 111 | { 112 | command = ["ags"]; 113 | } 114 | { 115 | command = ["swww-daemon"]; 116 | } 117 | { 118 | command = ["dbus-update-activation-environment" "--all" "--systemd"]; 119 | } 120 | { 121 | command = ["${pkgs.polkit_gnome}/libexec/polkit-gnome-authentication-agent-1"]; 122 | } 123 | { 124 | command = [ 125 | "sh" 126 | "-c" 127 | '' 128 | eval $(gnome-keyring-daemon -s --components=pkcs11,secrets,ssh -f); 129 | export SSH_AUTH_SOCK; 130 | '' 131 | ]; 132 | } 133 | { 134 | command = ["${pkgs.xwayland-satellite}/bin/xwayland-satellite"]; 135 | } 136 | ]; 137 | 138 | layout = { 139 | border = { 140 | active = { 141 | gradient = { 142 | angle = 130; 143 | relative-to = "workspace-view"; 144 | from = "#${theme.base0D}"; 145 | to = "#${theme.base0E}"; 146 | }; 147 | }; 148 | inactive = { 149 | gradient = { 150 | angle = 130; 151 | relative-to = "workspace-view"; 152 | from = "#${theme.base0D}90"; 153 | to = "#${theme.base0E}90"; 154 | }; 155 | }; 156 | }; 157 | }; 158 | 159 | input = { 160 | focus-follows-mouse.enable = true; 161 | touchpad.click-method = "clickfinger"; 162 | }; 163 | 164 | animations = let 165 | movement-conf = { 166 | spring = { 167 | damping-ratio = 0.760000; 168 | epsilon = 0.000100; 169 | stiffness = 700; 170 | }; 171 | }; 172 | in { 173 | horizontal-view-movement = movement-conf; 174 | window-movement = movement-conf; 175 | workspace-switch = movement-conf; 176 | }; 177 | 178 | window-rules = [ 179 | { 180 | matches = [ 181 | { 182 | app-id = "^org.wezfurlong.wezterm$"; 183 | } 184 | ]; 185 | default-column-width = {}; 186 | } 187 | 188 | { 189 | geometry-corner-radius = { 190 | bottom-left = 12.0; 191 | bottom-right = 12.0; 192 | top-left = 12.0; 193 | top-right = 12.0; 194 | }; 195 | clip-to-geometry = true; 196 | } 197 | ]; 198 | }; 199 | } 200 | -------------------------------------------------------------------------------- /users/modules/nushell/config/config.nu: -------------------------------------------------------------------------------- 1 | module completions { 2 | } 3 | 4 | # Get just the extern definitions without the custom completion commands 5 | use completions * 6 | 7 | let stheme = { 8 | "base": { 9 | "background": "#060516", 10 | "foreground": "#d4d5f2" 11 | }, 12 | "base00": "#060516", 13 | "base01": "#09081b", 14 | "base02": "#141327", 15 | "base03": "#2b2b41", 16 | "base04": "#60607a", 17 | "base05": "#dadbf8", 18 | "base06": "#e7e8ff", 19 | "base07": "#aaa8ff", 20 | "base08": "#ab8be3", 21 | "base09": "#ea9d00", 22 | "base0A": "#ff5d66", 23 | "base0B": "#27b892", 24 | "base0C": "#00c2ba", 25 | "base0D": "#acaaff", 26 | "base0E": "#44a8e7", 27 | "base0F": "#45455d", 28 | "overlay": { 29 | "background": "#141327", 30 | "foreground": "#e7e8ff" 31 | }, 32 | "primary": { 33 | "background": "#433889", 34 | "foreground": "#acaaff" 35 | }, 36 | "secondary": { 37 | "background": "#004d85", 38 | "foreground": "#44a8e7" 39 | }, 40 | "surface": { 41 | "background": "#09081b", 42 | "foreground": "#dadbf8" 43 | }, 44 | "green": "#27b892", 45 | "mauve": "#ab8be3", 46 | "orange": "#ea9d00", 47 | "red": "#ff5d66", 48 | "subtle": "#45455d", 49 | "teal": "#00c2ba" 50 | } 51 | 52 | # The default config record. This is where much of your global configuration is setup. 53 | $env.config = { 54 | ls: { 55 | use_ls_colors: true # use the LS_COLORS environment variable to colorize output 56 | clickable_links: true # enable or disable clickable links. Your terminal has to support links. 57 | } 58 | rm: { 59 | always_trash: false # always act as if -t was given. Can be overridden with -p 60 | } 61 | table: { 62 | mode: rounded # basic, compact, compact_double, light, thin, with_love, rounded, reinforced, heavy, none, other 63 | index_mode: always # "always" show indexes, "never" show indexes, "auto" = show indexes when a table has "index" column 64 | header_on_separator: true 65 | trim: { 66 | methodology: wrapping # wrapping or truncating 67 | wrapping_try_keep_words: true # A strategy used by the 'wrapping' methodology 68 | truncating_suffix: "..." # A suffix used by the 'truncating' methodology 69 | } 70 | } 71 | 72 | explore: { 73 | help_banner: true 74 | exit_esc: true 75 | 76 | command_bar_text: '#C4C9C6' 77 | status_bar_background: {fg: '#1D1F21' bg: '#C4C9C6' } 78 | 79 | highlight: {bg: $stheme.orange fg: $stheme.base.background } 80 | 81 | table: { 82 | split_line: '#404040' 83 | 84 | cursor: true 85 | 86 | line_index: true 87 | line_shift: true 88 | line_head_top: true 89 | line_head_bottom: true 90 | 91 | show_head: true 92 | show_index: true 93 | } 94 | } 95 | 96 | history: { 97 | max_size: 10000 # Session has to be reloaded for this to take effect 98 | sync_on_enter: true # Enable to share history between multiple sessions, else you have to close the session to write history to file 99 | file_format: "plaintext" # "sqlite" or "plaintext" 100 | } 101 | completions: { 102 | case_sensitive: false # set to true to enable case-sensitive completions 103 | quick: true # set this to false to prevent auto-selecting completions when only one remains 104 | partial: true # set this to false to prevent partial filling of the prompt 105 | algorithm: "fuzzy" # prefix or fuzzy 106 | } 107 | filesize: { 108 | unit: "metric" # b, kb, kib, mb, mib, gb, gib, tb, tib, pb, pib, eb, eib, zb, zib, auto 109 | } 110 | footer_mode: 25 # always, never, number_of_rows, auto 111 | float_precision: 2 112 | buffer_editor: "hx" # command that will be used to edit the current line buffer with ctrl+o, if unset fallback to $env.EDITOR and $env.VISUAL 113 | use_ansi_coloring: true 114 | edit_mode: vi # emacs, vi 115 | shell_integration: { 116 | # osc2 abbreviates the path if in the home_dir, sets the tab/window title, shows the running command in the tab/window title 117 | osc2: true 118 | # osc7 is a way to communicate the path to the terminal, this is helpful for spawning new tabs in the same directory 119 | osc7: true 120 | # osc8 is also implemented as the deprecated setting ls.show_clickable_links, it shows clickable links in ls output if your terminal supports it. show_clickable_links is deprecated in favor of osc8 121 | osc8: true 122 | # osc9_9 is from ConEmu and is starting to get wider support. It's similar to osc7 in that it communicates the path to the terminal 123 | osc9_9: false 124 | # osc133 is several escapes invented by Final Term which include the supported ones below. 125 | # 133;A - Mark prompt start 126 | # 133;B - Mark prompt end 127 | # 133;C - Mark pre-execution 128 | # 133;D;exit - Mark execution finished with exit code 129 | # This is used to enable terminals to know where the prompt is, the command is, where the command finishes, and where the output of the command is 130 | osc133: true 131 | # osc633 is closely related to osc133 but only exists in visual studio code (vscode) and supports their shell integration features 132 | # 633;A - Mark prompt start 133 | # 633;B - Mark prompt end 134 | # 633;C - Mark pre-execution 135 | # 633;D;exit - Mark execution finished with exit code 136 | # 633;E - NOT IMPLEMENTED - Explicitly set the command line with an optional nonce 137 | # 633;P;Cwd= - Mark the current working directory and communicate it to the terminal 138 | # and also helps with the run recent menu in vscode 139 | osc633: true 140 | # reset_application_mode is escape \x1b[?1l and was added to help ssh work better 141 | reset_application_mode: true 142 | } 143 | show_banner: false # true or false to enable or disable the banner 144 | render_right_prompt_on_last_line: false # true or false to enable or disable right prompt to be rendered on last line of the prompt. 145 | 146 | hooks: { 147 | pre_prompt: [{ || 148 | null 149 | }] 150 | pre_execution: [{ || 151 | null # replace with source code to run before the repl input is run 152 | }] 153 | env_change: { 154 | PWD: [{|before, after| 155 | if $before != $after { zoxide add -- $after } else { null } 156 | }] 157 | } 158 | display_output: { || 159 | if (term size).columns >= 100 { table -e } else { table } 160 | } 161 | } 162 | 163 | menus: [ 164 | # Configuration for default nushell menus 165 | # Note the lack of souce parameter 166 | { 167 | name: completion_menu 168 | only_buffer_difference: false 169 | marker: "| " 170 | type: { 171 | layout: columnar 172 | columns: 4 173 | col_width: 20 # Optional value. If missing all the screen width is used to calculate column width 174 | col_padding: 2 175 | } 176 | style: { 177 | text: green 178 | selected_text: green_reverse 179 | description_text: yellow 180 | } 181 | } 182 | { 183 | name: ide_completion_menu 184 | only_buffer_difference: false 185 | marker: "| " 186 | type: { 187 | layout: ide 188 | min_completion_width: 0, 189 | max_completion_width: 50, 190 | max_completion_height: 10, # will be limited by the available lines in the terminal 191 | padding: 0, 192 | border: true, 193 | cursor_offset: 0, 194 | description_mode: "prefer_right" 195 | min_description_width: 0 196 | max_description_width: 50 197 | max_description_height: 10 198 | description_offset: 1 199 | # If true, the cursor pos will be corrected, so the suggestions match up with the typed text 200 | # 201 | # C:\> str 202 | # str join 203 | # str trim 204 | # str split 205 | correct_cursor_pos: false 206 | } 207 | style: { 208 | text: green 209 | selected_text: { attr: r } 210 | description_text: yellow 211 | match_text: { attr: u } 212 | selected_match_text: { attr: ur } 213 | } 214 | } 215 | { 216 | name: history_menu 217 | only_buffer_difference: true 218 | marker: "? " 219 | type: { 220 | layout: list 221 | page_size: 10 222 | } 223 | style: { 224 | text: green 225 | selected_text: green_reverse 226 | description_text: yellow 227 | } 228 | } 229 | # { 230 | # name: ide_completion_menu 231 | # modifier: control 232 | # keycode: char_n 233 | # mode: [emacs vi_normal vi_insert] 234 | # event: { 235 | # until: [ 236 | # { send: menu name: ide_completion_menu } 237 | # { send: menunext } 238 | # { edit: complete } 239 | # ] 240 | # } 241 | # } 242 | { 243 | name: help_menu 244 | only_buffer_difference: true 245 | marker: "? " 246 | type: { 247 | layout: description 248 | columns: 4 249 | col_width: 20 # Optional value. If missing all the screen width is used to calculate column width 250 | col_padding: 2 251 | selection_rows: 4 252 | description_rows: 10 253 | } 254 | style: { 255 | text: green 256 | selected_text: green_reverse 257 | description_text: yellow 258 | } 259 | } 260 | # Example of extra menus created using a nushell source 261 | # Use the source field to create a list of records that populates 262 | # the menu 263 | { 264 | name: commands_menu 265 | only_buffer_difference: false 266 | marker: "# " 267 | type: { 268 | layout: columnar 269 | columns: 4 270 | col_width: 20 271 | col_padding: 2 272 | } 273 | style: { 274 | text: green 275 | selected_text: green_reverse 276 | description_text: yellow 277 | } 278 | source: { |buffer, position| 279 | $nu.scope.commands 280 | | where name =~ $buffer 281 | | each { |it| {value: $it.name description: $it.usage} } 282 | } 283 | } 284 | { 285 | name: vars_menu 286 | only_buffer_difference: true 287 | marker: "# " 288 | type: { 289 | layout: list 290 | page_size: 10 291 | } 292 | style: { 293 | text: green 294 | selected_text: green_reverse 295 | description_text: yellow 296 | } 297 | source: { |buffer, position| 298 | $nu.scope.vars 299 | | where name =~ $buffer 300 | | sort-by name 301 | | each { |it| {value: $it.name description: $it.type} } 302 | } 303 | } 304 | { 305 | name: commands_with_description 306 | only_buffer_difference: true 307 | marker: "# " 308 | type: { 309 | layout: description 310 | columns: 4 311 | col_width: 20 312 | col_padding: 2 313 | selection_rows: 4 314 | description_rows: 10 315 | } 316 | style: { 317 | text: green 318 | selected_text: green_reverse 319 | description_text: yellow 320 | } 321 | source: { |buffer, position| 322 | $nu.scope.commands 323 | | where name =~ $buffer 324 | | each { |it| {value: $it.name description: $it.usage} } 325 | } 326 | } 327 | ] 328 | keybindings: [ 329 | { 330 | name: ide_completion_menu 331 | modifier: none 332 | keycode: tab 333 | mode: [emacs vi_normal vi_insert] 334 | event: { 335 | until: [ 336 | { send: menu name: ide_completion_menu } 337 | { send: menunext } 338 | { edit: complete } 339 | ] 340 | } 341 | } 342 | # { 343 | # name: completion_menu 344 | # modifier: none 345 | # keycode: tab 346 | # mode: [emacs vi_normal vi_insert] 347 | # event: { 348 | # until: [ 349 | # { send: menu name: completion_menu } 350 | # { send: menunext } 351 | # ] 352 | # } 353 | # } 354 | { 355 | name: completion_previous 356 | modifier: shift 357 | keycode: backtab 358 | mode: [emacs, vi_normal, vi_insert] # Note: You can add the same keybinding to all modes by using a list 359 | event: { send: menuprevious } 360 | } 361 | { 362 | name: history_menu 363 | modifier: control 364 | keycode: char_r 365 | mode: emacs 366 | event: { send: menu name: history_menu } 367 | } 368 | { 369 | name: next_page 370 | modifier: control 371 | keycode: char_x 372 | mode: emacs 373 | event: { send: menupagenext } 374 | } 375 | { 376 | name: undo_or_previous_page 377 | modifier: control 378 | keycode: char_z 379 | mode: emacs 380 | event: { 381 | until: [ 382 | { send: menupageprevious } 383 | { edit: undo } 384 | ] 385 | } 386 | } 387 | { 388 | name: yank 389 | modifier: control 390 | keycode: char_y 391 | mode: emacs 392 | event: { 393 | until: [ 394 | {edit: pastecutbufferafter} 395 | ] 396 | } 397 | } 398 | { 399 | name: unix-line-discard 400 | modifier: control 401 | keycode: char_u 402 | mode: [emacs, vi_normal, vi_insert] 403 | event: { 404 | until: [ 405 | {edit: cutfromlinestart} 406 | ] 407 | } 408 | } 409 | { 410 | name: kill-line 411 | modifier: control 412 | keycode: char_k 413 | mode: [emacs, vi_normal, vi_insert] 414 | event: { 415 | until: [ 416 | {edit: cuttolineend} 417 | ] 418 | } 419 | } 420 | # Keybindings used to trigger the user defined menus 421 | { 422 | name: commands_menu 423 | modifier: control 424 | keycode: char_t 425 | mode: [emacs, vi_normal, vi_insert] 426 | event: { send: menu name: commands_menu } 427 | } 428 | { 429 | name: vars_menu 430 | modifier: alt 431 | keycode: char_o 432 | mode: [emacs, vi_normal, vi_insert] 433 | event: { send: menu name: vars_menu } 434 | } 435 | { 436 | name: commands_with_description 437 | modifier: control 438 | keycode: char_s 439 | mode: [emacs, vi_normal, vi_insert] 440 | event: { send: menu name: commands_with_description } 441 | } 442 | ] 443 | } 444 | 445 | def --env get-env [name] { $env | get $name } 446 | def --env set-env [name, value] { load-env { $name: $value } } 447 | def --env unset-env [name] { hide-env $name } 448 | 449 | let null_completer = {|spans: list| null } 450 | 451 | let zoxide_completer = {|spans: list| 452 | $spans | skip 1 | zoxide query -l ...$in | lines | where {|x| $x != $env.PWD } | if ($in | default [] | is-empty) { null } else { $in } 453 | } 454 | 455 | let fish_completer = {|spans: list| 456 | fish --command $'complete "--do-complete=($spans | str join " ")"' 457 | | $"value(char tab)description(char newline)" + $in 458 | | from tsv --flexible --no-infer 459 | | if ($in | default [] | is-empty) { null } else { $in } 460 | } 461 | 462 | let carapace_completer = {|spans: list| 463 | carapace $spans.0 nushell ...$spans | from json | if ($in | default [] | is-empty) { null } else { $in } 464 | } 465 | 466 | let specialized_completer = {|spans: list| 467 | match $spans.0 { 468 | __zoxide_z => $zoxide_completer 469 | __zoxide_zi => $zoxide_completer 470 | _ => $null_completer 471 | } | do $in $spans 472 | } 473 | 474 | def multiple_completers [spans: list] { 475 | let expanded_alias = (scope aliases | where name == $spans.0 | get -i 0 | get -i expansion) 476 | 477 | let spans = if $expanded_alias != null { 478 | $spans 479 | | skip 1 480 | | prepend ($expanded_alias | split row ' ') 481 | } else { 482 | $spans 483 | } 484 | 485 | let specialized_completer_result = do $specialized_completer $spans 486 | if $specialized_completer_result != null { 487 | return $specialized_completer_result 488 | } 489 | 490 | let carapace_completer_result = do $carapace_completer $spans 491 | if $carapace_completer_result != null { 492 | return $carapace_completer_result 493 | } 494 | 495 | let fish_completer_result = do $fish_completer $spans 496 | if $fish_completer_result != null { 497 | return $fish_completer_result 498 | } 499 | 500 | $null_completer 501 | } 502 | 503 | let completer = {|spans: list| multiple_completers $spans } 504 | 505 | $env.config.completions.external = { 506 | enable: true 507 | max_results: 100 508 | completer: $completer 509 | } 510 | 511 | let cachixExists = ("/etc/cachix-agent.token" | path exists) 512 | 513 | $env.SSH_AUTH_SOCK = "/run/user/1000/keyring/ssh" 514 | 515 | if $cachixExists { 516 | open /etc/cachix-agent.token | lines | parse "{name}={value}" | reduce -f {} { |it, acc| $acc | upsert $it.name $it.value } | load-env 517 | } 518 | -------------------------------------------------------------------------------- /users/modules/nushell/config/env.nu: -------------------------------------------------------------------------------- 1 | # Specifies how environment variables are: 2 | # - converted from a string to a value on Nushell startup (from_string) 3 | # - converted from a value back to a string when running external commands (to_string) 4 | # Note: The conversions happen *after* config.nu is loaded 5 | $env.ENV_CONVERSIONS = { 6 | "PATH": { 7 | from_string: { |s| $s | split row (char esep) | path expand -n } 8 | to_string: { |v| $v | path expand -n | str join (char esep) } 9 | } 10 | "Path": { 11 | from_string: { |s| $s | split row (char esep) | path expand -n } 12 | to_string: { |v| $v | path expand -n | str join (char esep) } 13 | } 14 | } 15 | 16 | # Directories to search for scripts when calling source or use 17 | # 18 | # By default, /scripts is added 19 | $env.NU_LIB_DIRS = [ 20 | ($nu.config-path | path dirname | path join 'scripts') 21 | ] 22 | 23 | # Directories to search for plugin binaries when calling register 24 | # 25 | # By default, /plugins is added 26 | $env.NU_PLUGIN_DIRS = [ 27 | ($nu.config-path | path dirname | path join 'plugins') 28 | ] 29 | 30 | $env.WLR_NO_HARDWARE_CURSORS = 1 31 | $env.LIBVA_DRIVER_NAME = 'nvidia' 32 | 33 | $env.__zoxide_hooked = true 34 | $env.CARAPACE_BRIDGES = 'fish,zsh,inshellisense,bash' 35 | 36 | ## Temporary fix for Nushell deprecating --redirect-stderr 37 | # mkdir ~/.local/share/atuin/ 38 | # atuin init nu | save -f ~/.local/share/atuin/init.nu 39 | # ## https://github.com/atuinsh/atuin/pull/1913/commits/4c564aca2f385d38f26c13f5b4aeeee318dce0d4 40 | # open ~/.local/share/atuin/init.nu | str replace --all 'run-external --redirect-stderr atuin search' 'run-external atuin search' | save -f ~/.local/share/atuin/init.nu; 41 | # open ~/.local/share/atuin/init.nu | str replace --all '| complete | $in.stderr | str substring ..-1)' 'e>| str trim)' | save -f ~/.local/share/atuin/init.nu; 42 | -------------------------------------------------------------------------------- /users/modules/nushell/config/ls-colors: -------------------------------------------------------------------------------- 1 | *~=0;38;2;88;91;112:bd=0;38;2;116;199;236;48;2;49;50;68:ca=0:cd=0;38;2;245;194;231;48;2;49;50;68:di=0;38;2;137;180;250:do=0;38;2;17;17;27;48;2;245;194;231:ex=1;38;2;243;139;168:fi=0:ln=0;38;2;245;194;231:mh=0:mi=0;38;2;17;17;27;48;2;243;139;168:no=0:or=0;38;2;17;17;27;48;2;243;139;168:ow=0:pi=0;38;2;17;17;27;48;2;137;180;250:rs=0:sg=0:so=0;38;2;17;17;27;48;2;245;194;231:st=0:su=0:tw=0:*.a=1;38;2;243;139;168:*.c=0;38;2;166;227;161:*.d=0;38;2;166;227;161:*.h=0;38;2;166;227;161:*.m=0;38;2;166;227;161:*.o=0;38;2;88;91;112:*.p=0;38;2;166;227;161:*.r=0;38;2;166;227;161:*.t=0;38;2;166;227;161:*.z=4;38;2;116;199;236:*.7z=4;38;2;116;199;236:*.as=0;38;2;166;227;161:*.bc=0;38;2;88;91;112:*.bz=4;38;2;116;199;236:*.cc=0;38;2;166;227;161:*.cp=0;38;2;166;227;161:*.cr=0;38;2;166;227;161:*.cs=0;38;2;166;227;161:*.di=0;38;2;166;227;161:*.el=0;38;2;166;227;161:*.ex=0;38;2;166;227;161:*.fs=0;38;2;166;227;161:*.go=0;38;2;166;227;161:*.gv=0;38;2;166;227;161:*.gz=4;38;2;116;199;236:*.hh=0;38;2;166;227;161:*.hi=0;38;2;88;91;112:*.hs=0;38;2;166;227;161:*.jl=0;38;2;166;227;161:*.js=0;38;2;166;227;161:*.ko=1;38;2;243;139;168:*.kt=0;38;2;166;227;161:*.la=0;38;2;88;91;112:*.ll=0;38;2;166;227;161:*.lo=0;38;2;88;91;112:*.md=0;38;2;249;226;175:*.ml=0;38;2;166;227;161:*.mn=0;38;2;166;227;161:*.nb=0;38;2;166;227;161:*.pl=0;38;2;166;227;161:*.pm=0;38;2;166;227;161:*.pp=0;38;2;166;227;161:*.ps=0;38;2;243;139;168:*.py=0;38;2;166;227;161:*.rb=0;38;2;166;227;161:*.rm=0;38;2;242;205;205:*.rs=0;38;2;166;227;161:*.sh=0;38;2;166;227;161:*.so=1;38;2;243;139;168:*.td=0;38;2;166;227;161:*.ts=0;38;2;166;227;161:*.ui=0;38;2;249;226;175:*.vb=0;38;2;166;227;161:*.wv=0;38;2;242;205;205:*.xz=4;38;2;116;199;236:*.aif=0;38;2;242;205;205:*.ape=0;38;2;242;205;205:*.apk=4;38;2;116;199;236:*.arj=4;38;2;116;199;236:*.asa=0;38;2;166;227;161:*.aux=0;38;2;88;91;112:*.avi=0;38;2;242;205;205:*.awk=0;38;2;166;227;161:*.bag=4;38;2;116;199;236:*.bak=0;38;2;88;91;112:*.bat=1;38;2;243;139;168:*.bbl=0;38;2;88;91;112:*.bcf=0;38;2;88;91;112:*.bib=0;38;2;249;226;175:*.bin=4;38;2;116;199;236:*.blg=0;38;2;88;91;112:*.bmp=0;38;2;242;205;205:*.bsh=0;38;2;166;227;161:*.bst=0;38;2;249;226;175:*.bz2=4;38;2;116;199;236:*.c++=0;38;2;166;227;161:*.cfg=0;38;2;249;226;175:*.cgi=0;38;2;166;227;161:*.clj=0;38;2;166;227;161:*.com=1;38;2;243;139;168:*.cpp=0;38;2;166;227;161:*.css=0;38;2;166;227;161:*.csv=0;38;2;249;226;175:*.csx=0;38;2;166;227;161:*.cxx=0;38;2;166;227;161:*.deb=4;38;2;116;199;236:*.def=0;38;2;166;227;161:*.dll=1;38;2;243;139;168:*.dmg=4;38;2;116;199;236:*.doc=0;38;2;243;139;168:*.dot=0;38;2;166;227;161:*.dox=0;38;2;148;226;213:*.dpr=0;38;2;166;227;161:*.elc=0;38;2;166;227;161:*.elm=0;38;2;166;227;161:*.epp=0;38;2;166;227;161:*.eps=0;38;2;242;205;205:*.erl=0;38;2;166;227;161:*.exe=1;38;2;243;139;168:*.exs=0;38;2;166;227;161:*.fls=0;38;2;88;91;112:*.flv=0;38;2;242;205;205:*.fnt=0;38;2;242;205;205:*.fon=0;38;2;242;205;205:*.fsi=0;38;2;166;227;161:*.fsx=0;38;2;166;227;161:*.gif=0;38;2;242;205;205:*.git=0;38;2;88;91;112:*.gvy=0;38;2;166;227;161:*.h++=0;38;2;166;227;161:*.hpp=0;38;2;166;227;161:*.htc=0;38;2;166;227;161:*.htm=0;38;2;249;226;175:*.hxx=0;38;2;166;227;161:*.ico=0;38;2;242;205;205:*.ics=0;38;2;243;139;168:*.idx=0;38;2;88;91;112:*.ilg=0;38;2;88;91;112:*.img=4;38;2;116;199;236:*.inc=0;38;2;166;227;161:*.ind=0;38;2;88;91;112:*.ini=0;38;2;249;226;175:*.inl=0;38;2;166;227;161:*.ipp=0;38;2;166;227;161:*.iso=4;38;2;116;199;236:*.jar=4;38;2;116;199;236:*.jpg=0;38;2;242;205;205:*.kex=0;38;2;243;139;168:*.kts=0;38;2;166;227;161:*.log=0;38;2;88;91;112:*.ltx=0;38;2;166;227;161:*.lua=0;38;2;166;227;161:*.m3u=0;38;2;242;205;205:*.m4a=0;38;2;242;205;205:*.m4v=0;38;2;242;205;205:*.mid=0;38;2;242;205;205:*.mir=0;38;2;166;227;161:*.mkv=0;38;2;242;205;205:*.mli=0;38;2;166;227;161:*.mov=0;38;2;242;205;205:*.mp3=0;38;2;242;205;205:*.mp4=0;38;2;242;205;205:*.mpg=0;38;2;242;205;205:*.nix=0;38;2;249;226;175:*.odp=0;38;2;243;139;168:*.ods=0;38;2;243;139;168:*.odt=0;38;2;243;139;168:*.ogg=0;38;2;242;205;205:*.org=0;38;2;249;226;175:*.otf=0;38;2;242;205;205:*.out=0;38;2;88;91;112:*.pas=0;38;2;166;227;161:*.pbm=0;38;2;242;205;205:*.pdf=0;38;2;243;139;168:*.pgm=0;38;2;242;205;205:*.php=0;38;2;166;227;161:*.pid=0;38;2;88;91;112:*.pkg=4;38;2;116;199;236:*.png=0;38;2;242;205;205:*.pod=0;38;2;166;227;161:*.ppm=0;38;2;242;205;205:*.pps=0;38;2;243;139;168:*.ppt=0;38;2;243;139;168:*.pro=0;38;2;148;226;213:*.ps1=0;38;2;166;227;161:*.psd=0;38;2;242;205;205:*.pyc=0;38;2;88;91;112:*.pyd=0;38;2;88;91;112:*.pyo=0;38;2;88;91;112:*.rar=4;38;2;116;199;236:*.rpm=4;38;2;116;199;236:*.rst=0;38;2;249;226;175:*.rtf=0;38;2;243;139;168:*.sbt=0;38;2;166;227;161:*.sql=0;38;2;166;227;161:*.sty=0;38;2;88;91;112:*.svg=0;38;2;242;205;205:*.swf=0;38;2;242;205;205:*.swp=0;38;2;88;91;112:*.sxi=0;38;2;243;139;168:*.sxw=0;38;2;243;139;168:*.tar=4;38;2;116;199;236:*.tbz=4;38;2;116;199;236:*.tcl=0;38;2;166;227;161:*.tex=0;38;2;166;227;161:*.tgz=4;38;2;116;199;236:*.tif=0;38;2;242;205;205:*.tml=0;38;2;249;226;175:*.tmp=0;38;2;88;91;112:*.toc=0;38;2;88;91;112:*.tsx=0;38;2;166;227;161:*.ttf=0;38;2;242;205;205:*.txt=0;38;2;249;226;175:*.vcd=4;38;2;116;199;236:*.vim=0;38;2;166;227;161:*.vob=0;38;2;242;205;205:*.wav=0;38;2;242;205;205:*.wma=0;38;2;242;205;205:*.wmv=0;38;2;242;205;205:*.xcf=0;38;2;242;205;205:*.xlr=0;38;2;243;139;168:*.xls=0;38;2;243;139;168:*.xml=0;38;2;249;226;175:*.xmp=0;38;2;249;226;175:*.yml=0;38;2;249;226;175:*.zip=4;38;2;116;199;236:*.zsh=0;38;2;166;227;161:*.zst=4;38;2;116;199;236:*TODO=1:*hgrc=0;38;2;148;226;213:*.bash=0;38;2;166;227;161:*.conf=0;38;2;249;226;175:*.dart=0;38;2;166;227;161:*.diff=0;38;2;166;227;161:*.docx=0;38;2;243;139;168:*.epub=0;38;2;243;139;168:*.fish=0;38;2;166;227;161:*.flac=0;38;2;242;205;205:*.h264=0;38;2;242;205;205:*.hgrc=0;38;2;148;226;213:*.html=0;38;2;249;226;175:*.java=0;38;2;166;227;161:*.jpeg=0;38;2;242;205;205:*.json=0;38;2;249;226;175:*.less=0;38;2;166;227;161:*.lisp=0;38;2;166;227;161:*.lock=0;38;2;88;91;112:*.make=0;38;2;148;226;213:*.mpeg=0;38;2;242;205;205:*.opus=0;38;2;242;205;205:*.orig=0;38;2;88;91;112:*.pptx=0;38;2;243;139;168:*.psd1=0;38;2;166;227;161:*.psm1=0;38;2;166;227;161:*.purs=0;38;2;166;227;161:*.rlib=0;38;2;88;91;112:*.sass=0;38;2;166;227;161:*.scss=0;38;2;166;227;161:*.tbz2=4;38;2;116;199;236:*.tiff=0;38;2;242;205;205:*.toml=0;38;2;249;226;175:*.webm=0;38;2;242;205;205:*.webp=0;38;2;242;205;205:*.woff=0;38;2;242;205;205:*.xbps=4;38;2;116;199;236:*.xlsx=0;38;2;243;139;168:*.yaml=0;38;2;249;226;175:*.cabal=0;38;2;166;227;161:*.cache=0;38;2;88;91;112:*.class=0;38;2;88;91;112:*.cmake=0;38;2;148;226;213:*.dyn_o=0;38;2;88;91;112:*.ipynb=0;38;2;166;227;161:*.mdown=0;38;2;249;226;175:*.patch=0;38;2;166;227;161:*.scala=0;38;2;166;227;161:*.shtml=0;38;2;249;226;175:*.swift=0;38;2;166;227;161:*.toast=4;38;2;116;199;236:*.xhtml=0;38;2;249;226;175:*README=0;38;2;30;30;46;48;2;249;226;175:*passwd=0;38;2;249;226;175:*shadow=0;38;2;249;226;175:*.config=0;38;2;249;226;175:*.dyn_hi=0;38;2;88;91;112:*.flake8=0;38;2;148;226;213:*.gradle=0;38;2;166;227;161:*.groovy=0;38;2;166;227;161:*.ignore=0;38;2;148;226;213:*.matlab=0;38;2;166;227;161:*COPYING=0;38;2;147;153;178:*INSTALL=0;38;2;30;30;46;48;2;249;226;175:*LICENSE=0;38;2;147;153;178:*TODO.md=1:*.desktop=0;38;2;249;226;175:*.gemspec=0;38;2;148;226;213:*Doxyfile=0;38;2;148;226;213:*Makefile=0;38;2;148;226;213:*TODO.txt=1:*setup.py=0;38;2;148;226;213:*.DS_Store=0;38;2;88;91;112:*.cmake.in=0;38;2;148;226;213:*.fdignore=0;38;2;148;226;213:*.kdevelop=0;38;2;148;226;213:*.markdown=0;38;2;249;226;175:*.rgignore=0;38;2;148;226;213:*COPYRIGHT=0;38;2;147;153;178:*README.md=0;38;2;30;30;46;48;2;249;226;175:*configure=0;38;2;148;226;213:*.gitconfig=0;38;2;148;226;213:*.gitignore=0;38;2;148;226;213:*.localized=0;38;2;88;91;112:*.scons_opt=0;38;2;88;91;112:*CODEOWNERS=0;38;2;148;226;213:*Dockerfile=0;38;2;249;226;175:*INSTALL.md=0;38;2;30;30;46;48;2;249;226;175:*README.txt=0;38;2;30;30;46;48;2;249;226;175:*SConscript=0;38;2;148;226;213:*SConstruct=0;38;2;148;226;213:*.gitmodules=0;38;2;148;226;213:*.synctex.gz=0;38;2;88;91;112:*.travis.yml=0;38;2;166;227;161:*INSTALL.txt=0;38;2;30;30;46;48;2;249;226;175:*LICENSE-MIT=0;38;2;147;153;178:*MANIFEST.in=0;38;2;148;226;213:*Makefile.am=0;38;2;148;226;213:*Makefile.in=0;38;2;88;91;112:*.applescript=0;38;2;166;227;161:*.fdb_latexmk=0;38;2;88;91;112:*CONTRIBUTORS=0;38;2;30;30;46;48;2;249;226;175:*appveyor.yml=0;38;2;166;227;161:*configure.ac=0;38;2;148;226;213:*.clang-format=0;38;2;148;226;213:*.gitattributes=0;38;2;148;226;213:*.gitlab-ci.yml=0;38;2;166;227;161:*CMakeCache.txt=0;38;2;88;91;112:*CMakeLists.txt=0;38;2;148;226;213:*LICENSE-APACHE=0;38;2;147;153;178:*CONTRIBUTORS.md=0;38;2;30;30;46;48;2;249;226;175:*.sconsign.dblite=0;38;2;88;91;112:*CONTRIBUTORS.txt=0;38;2;30;30;46;48;2;249;226;175:*requirements.txt=0;38;2;148;226;213:*package-lock.json=0;38;2;88;91;112:*.CFUserTextEncoding=0;38;2;88;91;112 2 | -------------------------------------------------------------------------------- /users/modules/nushell/config/starship.toml: -------------------------------------------------------------------------------- 1 | [buf] 2 | format = "(with [$symbol$version ]($style))" 3 | symbol = " " 4 | 5 | [bun] 6 | format = "(via [$symbol($version )]($style))" 7 | 8 | [c] 9 | format = "(via [$symbol($version(-$name) )]($style))" 10 | symbol = " " 11 | 12 | [cmake] 13 | format = "(via [$symbol($version )]($style))" 14 | 15 | [cobol] 16 | format = "(via [$symbol($version )]($style))" 17 | 18 | [crystal] 19 | format = "(via [$symbol($version )]($style))" 20 | 21 | [daml] 22 | format = "(via [$symbol($version )]($style))" 23 | 24 | [dart] 25 | format = "(via [$symbol($version )]($style))" 26 | symbol = " " 27 | 28 | [deno] 29 | format = "(via [$symbol($version )]($style))" 30 | 31 | [dotnet] 32 | format = "(via [$symbol($version )(🎯 $tfm )]($style))" 33 | 34 | [elixir] 35 | format = "(via [$symbol($version \\(OTP $otp_version\\) )]($style))" 36 | symbol = " " 37 | 38 | [elm] 39 | format = "(via [$symbol($version )]($style))" 40 | symbol = " " 41 | 42 | [erlang] 43 | format = "(via [$symbol($version )]($style))" 44 | 45 | [fennel] 46 | format = "(via [$symbol($version )]($style))" 47 | 48 | [golang] 49 | format = "(via [$symbol($version )]($style))" 50 | symbol = " " 51 | 52 | [haskell] 53 | format = "(via [$symbol($version )]($style))" 54 | symbol = " " 55 | 56 | [helm] 57 | format = "(via [$symbol($version )]($style))" 58 | 59 | [java] 60 | format = "(via [$symbol($version )]($style))" 61 | symbol = " " 62 | 63 | [julia] 64 | format = "(via [$symbol($version )]($style))" 65 | symbol = " " 66 | 67 | [kotlin] 68 | format = "(via [$symbol($version )]($style))" 69 | 70 | [lua] 71 | format = "(via [$symbol($version )]($style))" 72 | symbol = " " 73 | 74 | [nim] 75 | format = "(via [$symbol($version )]($style))" 76 | symbol = "󰆥 " 77 | 78 | [nodejs] 79 | format = "(via [$symbol($version )]($style))" 80 | symbol = " " 81 | 82 | [ocaml] 83 | format = "(via [$symbol($version )(\\($switch_indicator$switch_name\\) )]($style))" 84 | 85 | [opa] 86 | format = '(via [$symbo($version ]($style))"' 87 | 88 | [package] 89 | format = "(is [$symbol$version]($style) )" 90 | symbol = "󰏗 " 91 | 92 | [perl] 93 | format = "(via [$symbol($version )]($style))" 94 | 95 | [php] 96 | format = "(via [$symbol($version )]($style))" 97 | 98 | [purescript] 99 | format = "(via [$symbol($version )]($style))" 100 | 101 | [python] 102 | format = "(via [${symbol}${pyenv_prefix}(${version} )(\\($virtualenv\\) )]($style))" 103 | symbol = " " 104 | 105 | [raku] 106 | format = "(via [$symbol($version-$vm_version )]($style))" 107 | 108 | [red] 109 | format = "(via [$symbol($version )]($style))" 110 | 111 | [rlang] 112 | format = "(via [$symbol($version )]($style))" 113 | symbol = "󰟔 " 114 | 115 | [ruby] 116 | format = "(via [$symbol($version )]($style))" 117 | symbol = " " 118 | 119 | [rust] 120 | format = "(via [$symbol($version )]($style))" 121 | symbol = " " 122 | 123 | [scala] 124 | format = "(via [$symbol($version )]($style))" 125 | symbol = " " 126 | 127 | [swift] 128 | format = "(via [$symbol($version )]($style))" 129 | 130 | [vagrant] 131 | format = "(via [$symbol($version )]($style))" 132 | 133 | [vlang] 134 | format = "(via [$symbol($version )]($style))" 135 | 136 | [zig] 137 | format = "(via [$symbol($version )]($style))" 138 | 139 | [aws] 140 | symbol = " " 141 | 142 | [conda] 143 | symbol = " " 144 | 145 | [directory] 146 | read_only = " 󰌾" 147 | 148 | [docker_context] 149 | symbol = " " 150 | 151 | [fossil_branch] 152 | symbol = " " 153 | 154 | [git_branch] 155 | symbol = " " 156 | 157 | [guix_shell] 158 | symbol = " " 159 | 160 | [haxe] 161 | symbol = " " 162 | 163 | [hg_branch] 164 | symbol = " " 165 | 166 | [hostname] 167 | ssh_symbol = " " 168 | 169 | [memory_usage] 170 | symbol = "󰍛 " 171 | 172 | [meson] 173 | symbol = "󰔷 " 174 | 175 | [nix_shell] 176 | symbol = " " 177 | 178 | [os.symbols] 179 | Alpaquita = " " 180 | Alpine = " " 181 | Amazon = " " 182 | Android = " " 183 | Arch = " " 184 | Artix = " " 185 | CentOS = " " 186 | Debian = " " 187 | DragonFly = " " 188 | Emscripten = " " 189 | EndeavourOS = " " 190 | Fedora = " " 191 | FreeBSD = " " 192 | Garuda = "󰛓 " 193 | Gentoo = " " 194 | HardenedBSD = "󰞌 " 195 | Illumos = "󰈸 " 196 | Linux = " " 197 | Mabox = " " 198 | Macos = " " 199 | Manjaro = " " 200 | Mariner = " " 201 | MidnightBSD = " " 202 | Mint = " " 203 | NetBSD = " " 204 | NixOS = " " 205 | OpenBSD = "󰈺 " 206 | openSUSE = " " 207 | OracleLinux = "󰌷 " 208 | Pop = " " 209 | Raspbian = " " 210 | Redhat = " " 211 | RedHatEnterprise = " " 212 | Redox = "󰀘 " 213 | Solus = "󰠳 " 214 | SUSE = " " 215 | Ubuntu = " " 216 | Unknown = " " 217 | Windows = "󰍲 " 218 | 219 | [pijul_channel] 220 | symbol = " " 221 | -------------------------------------------------------------------------------- /users/modules/nushell/default.nix: -------------------------------------------------------------------------------- 1 | { 2 | pkgs, 3 | config, 4 | lib, 5 | ... 6 | }: { 7 | home.packages = with pkgs; [ 8 | fish # nushell completion partly relies on it 9 | inshellisense # carapace completer support 10 | zsh # carapace completer support 11 | ]; 12 | 13 | # tntman.home.shell.executable = "${pkgs.nushell}/bin/nu"; 14 | 15 | programs = { 16 | direnv = { 17 | enable = true; 18 | nix-direnv.enable = true; 19 | enableNushellIntegration = true; 20 | }; 21 | 22 | atuin = { 23 | enable = true; 24 | enableNushellIntegration = true; 25 | }; 26 | 27 | zoxide = { 28 | enable = true; 29 | enableNushellIntegration = true; 30 | }; 31 | 32 | carapace = { 33 | enable = true; 34 | enableNushellIntegration = false; # handled manually 35 | }; 36 | 37 | starship = { 38 | enable = true; 39 | enableNushellIntegration = true; 40 | settings = builtins.fromTOML (builtins.readFile ./config/starship.toml); 41 | }; 42 | 43 | nushell = { 44 | enable = true; 45 | configFile.source = ./config/config.nu; 46 | envFile.source = ./config/env.nu; 47 | # extraEnv = let 48 | # envVars = config.home.sessionVariables; 49 | # path = config.home.sessionPath; 50 | 51 | # # exception for XCURSOR_PATH, where it needs to be replaced with $env.XCURSOR_PATH = ($env.XCURSOR_PATH | split row (char esep) | append "{path}"); 52 | # # where path is the original value of $env.XCURSOR_PATH with $XCURSOR_PATH${XCURSOR_PATH:+:} removed 53 | # envVarList = 54 | # builtins.mapAttrs ( 55 | # name: value: 56 | # if name == "XCURSOR_PATH" 57 | # then let 58 | # path = lib.strings.removePrefix "$XCURSOR_PATH$\{XCURSOR_PATH:+:}" value; 59 | # in ''$env.${name} = ($env.${name} | split row (char esep) | append "${path}")'' 60 | # else ''$env.${name} = "${toString value}"'' 61 | # ) 62 | # envVars; 63 | 64 | # envVariables = builtins.concatStringsSep "\n" (builtins.attrValues envVarList); 65 | 66 | # # format each path as $env.PATH = ($env.PATH | split row (char esep) | append "{path}"); 67 | # pathList = map (path: ''$env.PATH = ($env.PATH | split row (char esep) | append "${path}")'') path; 68 | # pathVariables = builtins.concatStringsSep "\n" pathList; 69 | # in 70 | # builtins.concatStringsSep "\n" [envVariables pathVariables]; 71 | }; 72 | }; 73 | } 74 | -------------------------------------------------------------------------------- /users/modules/obs/default.nix: -------------------------------------------------------------------------------- 1 | {pkgs, ...}: { 2 | programs.obs-studio = { 3 | enable = true; 4 | plugins = with pkgs.obs-studio-plugins; [ 5 | wlrobs 6 | obs-vaapi 7 | # obs-nvfbc 8 | obs-pipewire-audio-capture 9 | ]; 10 | }; 11 | } 12 | -------------------------------------------------------------------------------- /users/modules/openrgb/MOOSIC TIME.orp: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Suya1671/commafiles/386603e0af2253d673f5299952eeaee37493b644/users/modules/openrgb/MOOSIC TIME.orp -------------------------------------------------------------------------------- /users/modules/openrgb/default.nix: -------------------------------------------------------------------------------- 1 | {...}: { 2 | } 3 | -------------------------------------------------------------------------------- /users/modules/playerctl.nix: -------------------------------------------------------------------------------- 1 | {pkgs, ...}: { 2 | home.packages = [ 3 | pkgs.playerctl 4 | ]; 5 | services.playerctld.enable = true; 6 | } 7 | -------------------------------------------------------------------------------- /users/modules/shell.nix: -------------------------------------------------------------------------------- 1 | # common cross-shell config 2 | { 3 | lib, 4 | config, 5 | ... 6 | }: let 7 | cfg = config.tntman.home.shell; 8 | in { 9 | options.tntman.home.shell = { 10 | executable = lib.mkOption { 11 | type = lib.types.str; 12 | example = "\${pkgs.zsh}/bin/zsh"; 13 | description = "The command to execute the shell with."; 14 | }; 15 | 16 | # shell aliases 17 | enableDefaultAliases = lib.mkOption { 18 | type = lib.types.bool; 19 | default = true; 20 | description = '' 21 | Whether to enable default aliases. 22 | ''; 23 | }; 24 | }; 25 | 26 | config.home.shellAliases = lib.mkIf cfg.enableDefaultAliases { 27 | # it's sudover. 28 | sudover = "sudo -k"; 29 | }; 30 | } 31 | -------------------------------------------------------------------------------- /users/modules/spotify/config/config: -------------------------------------------------------------------------------- 1 | [color] 2 | gradient = 1 3 | 4 | gradient_color_1 = '#94e2d5' 5 | gradient_color_2 = '#89dceb' 6 | gradient_color_3 = '#74c7ec' 7 | gradient_color_4 = '#89b4fa' 8 | gradient_color_5 = '#cba6f7' 9 | gradient_color_6 = '#f5c2e7' 10 | gradient_color_7 = '#eba0ac' 11 | gradient_color_8 = '#f38ba8' 12 | 13 | [general] 14 | autosens = 0 15 | bar_width = 1 16 | bar_spacing = 0 17 | lower_cutoff_freq = 50 18 | higher_cutoff_freq = 8000 19 | 20 | [output] 21 | method = ncurses 22 | channels = mono 23 | 24 | [smoothing] 25 | monstercat = 1 26 | waves = 1 27 | noise_reduction = 30 28 | 29 | [eq] 30 | 1 = 2 # bass 31 | 2 = 2 32 | 3 = 1 # midtone 33 | 4 = 1 34 | 5 = 1 35 | 6 = 0.5 # treble 36 | -------------------------------------------------------------------------------- /users/modules/spotify/default.nix: -------------------------------------------------------------------------------- 1 | { 2 | pkgs, 3 | packages, 4 | inputs, 5 | ... 6 | }: let 7 | spotifyPlayerName = pkgs.craneLib.crateNameFromCargoToml { 8 | cargoToml = "${inputs.spotify-player-src}/spotify_player/Cargo.toml"; 9 | }; 10 | 11 | spotifyPlayer = pkgs.craneLib.buildPackage ({ 12 | src = pkgs.craneLib.cleanCargoSource inputs.spotify-player-src; 13 | nativeBuildInputs = with pkgs; [pkg-config alsaLib.dev dbus.dev libpulseaudio libiconv openssl]; 14 | cargoExtraArgs = "-p spotify_player --no-default-features --features image,notify,daemon,media-control,pulseaudio-backend"; 15 | } 16 | // spotifyPlayerName); 17 | in { 18 | home.packages = with pkgs; [ 19 | spotifyPlayer # spotify terminal edition 20 | sptlrx # spotify lyrics 21 | cava # the funny music visualizer 22 | ]; 23 | 24 | xdg.configFile.cava.source = ./config; 25 | } 26 | -------------------------------------------------------------------------------- /users/modules/swaylock.nix: -------------------------------------------------------------------------------- 1 | {pkgs, ...}: { 2 | programs.swaylock = { 3 | enable = true; 4 | package = pkgs.swaylock-effects; 5 | settings = { 6 | clock = true; 7 | show-failed-attempts = true; 8 | indicator = true; 9 | indicator-radius = 200; 10 | indicator-thickness = 20; 11 | line-uses-ring = false; 12 | grace = 0; 13 | grace-no-mouse = true; 14 | grace-no-touch = true; 15 | datestr = "%d.%m"; 16 | fade-in = "0.1"; 17 | ignore-empty-password = true; 18 | }; 19 | }; 20 | 21 | services.swayidle = { 22 | enable = true; 23 | events = [ 24 | { 25 | event = "before-sleep"; 26 | command = "swaylock"; 27 | } 28 | { 29 | event = "lock"; 30 | command = "swaylock"; 31 | } 32 | ]; 33 | timeouts = [ 34 | { 35 | timeout = 300; 36 | command = "hyprctl dispatch dpms off"; 37 | resumeCommand = "hyprctl dispatch dpms on"; 38 | } 39 | { 40 | timeout = 310; 41 | command = "loginctl lock-session"; 42 | } 43 | ]; 44 | }; 45 | } 46 | -------------------------------------------------------------------------------- /users/modules/syncthing.nix: -------------------------------------------------------------------------------- 1 | {...}: { 2 | services.syncthing = { 3 | enable = true; 4 | tray.enable = true; 5 | }; 6 | 7 | systemd.user.targets.tray = { 8 | Unit = { 9 | Description = "Home Manager System Tray"; 10 | Requires = [ "graphical-session-pre.target" ]; 11 | }; 12 | }; 13 | } 14 | -------------------------------------------------------------------------------- /users/modules/terminal.nix: -------------------------------------------------------------------------------- 1 | # common cross-terminal config 2 | {lib, ...}: { 3 | options.tntman.home.terminal = { 4 | executable = lib.mkOption { 5 | type = lib.types.str; 6 | example = "\${pkgs.zsh}/bin/zsh"; 7 | description = "The command to execute when opening a new terminal."; 8 | }; 9 | 10 | name = lib.mkOption { 11 | type = lib.types.str; 12 | example = "zsh"; 13 | description = "The name of the terminal."; 14 | }; 15 | }; 16 | } 17 | -------------------------------------------------------------------------------- /users/modules/theme.nix: -------------------------------------------------------------------------------- 1 | { ... }: { 2 | stylix.targets = { 3 | kitty.variant256Colors = true; 4 | bemenu.enable = false; 5 | vim.enable = true; 6 | # Custom themes handled by kleur directly 7 | kde.enable = false; 8 | gnome.enable = false; 9 | helix.enable = false; 10 | }; 11 | } 12 | -------------------------------------------------------------------------------- /users/modules/vscode/default.nix: -------------------------------------------------------------------------------- 1 | { 2 | pkgs, 3 | config, 4 | ... 5 | }: { 6 | home.packages = with pkgs; [ 7 | vscode 8 | wakatime 9 | ]; 10 | } 11 | -------------------------------------------------------------------------------- /users/modules/webcord/default.nix: -------------------------------------------------------------------------------- 1 | {pkgs, ...}: { 2 | home.packages = [ 3 | (pkgs.vesktop.override { 4 | withSystemVencord = false; 5 | }) 6 | ]; 7 | } 8 | -------------------------------------------------------------------------------- /users/modules/wezterm/default.nix: -------------------------------------------------------------------------------- 1 | {config, pkgs, ...}: { 2 | programs.wezterm = { 3 | enable = true; 4 | package = pkgs.wezterm; 5 | extraConfig = builtins.readFile ./wezterm.lua; 6 | }; 7 | 8 | tntman.home.terminal = { 9 | executable = "${config.programs.wezterm.package}/bin/wezterm start --always-new-process"; 10 | name = "wezterm"; 11 | }; 12 | } 13 | -------------------------------------------------------------------------------- /users/modules/wezterm/wezterm.lua: -------------------------------------------------------------------------------- 1 | -- This table will hold the configuration. 2 | local config = {} 3 | 4 | -- In newer versions of wezterm, use the config_builder which will 5 | -- help provide clearer error messages 6 | if wezterm.config_builder then 7 | config = wezterm.config_builder() 8 | end 9 | 10 | config.color_scheme = 'stylix' 11 | config.font = wezterm.font_with_fallback { 12 | "ComicCodeLigatures Nerd Font", 13 | "JetBrains Mono Nerd Font Mono", 14 | } 15 | config.enable_wayland = true 16 | config.enable_tab_bar = false 17 | config.underline_thickness = "2pt" 18 | config.enable_kitty_keyboard = true 19 | 20 | config.visual_bell = { 21 | fade_in_function = 'EaseIn', 22 | fade_in_duration_ms = 150, 23 | fade_out_function = 'EaseOut', 24 | fade_out_duration_ms = 150, 25 | } 26 | local gpus = wezterm.gui.enumerate_gpus() 27 | config.front_end = "WebGpu" 28 | config.webgpu_preferred_adapter = gpus[1] 29 | 30 | -- and finally, return the configuration to wezterm 31 | return config 32 | -------------------------------------------------------------------------------- /users/modules/wlsunset.nix: -------------------------------------------------------------------------------- 1 | { ... }: { 2 | services.wlsunset = { 3 | enable = true; 4 | # South Africa gaming 5 | latitude = "-26"; 6 | longitude = "28"; 7 | }; 8 | } 9 | 10 | -------------------------------------------------------------------------------- /users/modules/xdg.nix: -------------------------------------------------------------------------------- 1 | {pkgs, ...}: let 2 | browser = ["zen.desktop"]; 3 | 4 | associations = { 5 | "text/html" = browser; 6 | "x-scheme-handler/http" = browser; 7 | "x-scheme-handler/https" = browser; 8 | "x-scheme-handler/ftp" = browser; 9 | "x-scheme-handler/about" = browser; 10 | "x-scheme-handler/unknown" = browser; 11 | "application/x-extension-htm" = browser; 12 | "application/x-extension-html" = browser; 13 | "application/x-extension-shtml" = browser; 14 | "application/xhtml+xml" = browser; 15 | "application/x-extension-xhtml" = browser; 16 | "application/x-extension-xht" = browser; 17 | "image/svg" = ["org.inkscape.Inkscape.desktop"]; 18 | "image/svg+xml" = ["org.inkscape.Inkscape.desktop"]; 19 | 20 | "audio/*" = ["mpv.desktop"]; 21 | "video/*" = ["mpv.dekstop"]; 22 | "image/*" = ["imv.desktop"]; 23 | "application/json" = browser; 24 | "x-scheme-handler/spotify" = ["spotify.desktop"]; 25 | }; 26 | in { 27 | home.packages = with pkgs; [mpv xdg-utils]; 28 | 29 | xdg = { 30 | mimeApps.enable = true; 31 | mimeApps.associations.added = associations; 32 | mimeApps.defaultApplications = associations; 33 | }; 34 | } 35 | -------------------------------------------------------------------------------- /users/modules/yazi.nix: -------------------------------------------------------------------------------- 1 | {...}: { 2 | programs.yazi = { 3 | enable = true; 4 | enableNushellIntegration = true; 5 | enableZshIntegration = true; 6 | }; 7 | } 8 | -------------------------------------------------------------------------------- /users/modules/zellij/default.nix: -------------------------------------------------------------------------------- 1 | { inputs, pkgs, ... }: { 2 | programs.zellij = { 3 | enable = true; 4 | settings = { 5 | ui = { 6 | pane_frames = { 7 | rounded_corners = true; 8 | }; 9 | }; 10 | }; 11 | }; 12 | 13 | home.shellAliases = { 14 | zr = "zellij run --"; 15 | zrf = "zellij run --floating --"; 16 | ze = "zellij edit"; 17 | zef = "zellij edit --floating"; 18 | # dev-env rust 19 | ders = "zellij action new-tab -l ~/.config/zellij/layouts/rust.kdl"; 20 | # dev-env js 21 | dejs = "zellij action new-tab -l ~/.config/zellij/layouts/js.kdl"; 22 | }; 23 | 24 | xdg.configFile."zellij/layouts".source = ./layouts; 25 | } 26 | -------------------------------------------------------------------------------- /users/modules/zellij/layouts/default.kdl: -------------------------------------------------------------------------------- 1 | layout { 2 | pane split_direction="vertical" { 3 | pane 4 | } 5 | 6 | pane size=2 borderless=true { 7 | plugin location="zellij:status-bar" 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /users/modules/zellij/layouts/js.kdl: -------------------------------------------------------------------------------- 1 | layout { 2 | pane split_direction="vertical" { 3 | pane edit="package.json" size="65%" 4 | pane split_direction="horizontal" { 5 | pane command="pnpm" { 6 | args "run" "dev" 7 | } 8 | pane 9 | } 10 | } 11 | 12 | pane size=1 borderless=true { 13 | plugin location="https://github.com/dj95/zjstatus/releases/download/v0.14.0/zjstatus.wasm" 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /users/modules/zellij/layouts/rust.kdl: -------------------------------------------------------------------------------- 1 | layout { 2 | pane split_direction="vertical" { 3 | pane edit="Cargo.toml" size="65%" 4 | pane split_direction="horizontal" size="35%" { 5 | pane command="cargo" { 6 | args "check" 7 | } 8 | pane command="cargo" { 9 | args "test" 10 | } 11 | pane 12 | } 13 | } 14 | 15 | pane size=1 borderless=true { 16 | plugin location="https://github.com/dj95/zjstatus/releases/download/v0.14.0/zjstatus.wasm" 17 | } 18 | } 19 | -------------------------------------------------------------------------------- /users/tau/default.nix: -------------------------------------------------------------------------------- 1 | { 2 | inputs, 3 | ezModules, 4 | pkgs, 5 | config, 6 | ... 7 | }: { 8 | imports = [ 9 | inputs.nix-index-database.hmModules.nix-index 10 | 11 | ezModules.git 12 | ezModules.wezterm 13 | # ezModules.nushell 14 | ezModules.syncthing 15 | ezModules.xdg 16 | 17 | ezModules.terminal 18 | ezModules.shell 19 | ]; 20 | 21 | home = { 22 | username = "tau"; 23 | homeDirectory = "/home/tau"; 24 | 25 | stateVersion = "23.11"; 26 | 27 | packages = with pkgs; [ 28 | cachix # caching stuff 29 | rsync 30 | zellij 31 | # (openocd.override { extraHardwareSupport = ["bcm2835gpio"]; }) 32 | ]; 33 | }; 34 | 35 | programs = { 36 | home-manager.enable = true; 37 | nix-index-database.comma.enable = true; 38 | }; 39 | } 40 | -------------------------------------------------------------------------------- /users/tntman/default.nix: -------------------------------------------------------------------------------- 1 | { 2 | pkgs, 3 | ezModules, 4 | inputs, 5 | ... 6 | }: { 7 | imports = [ 8 | inputs.nix-index-database.hmModules.nix-index 9 | 10 | ezModules.electron 11 | # ezModules.firefox 12 | ezModules.git 13 | ezModules.gtk 14 | ezModules.niri 15 | ezModules.openrgb 16 | ezModules.playerctl 17 | ezModules.kleur 18 | ezModules.syncthing 19 | ezModules.xdg 20 | ezModules.fastfetch 21 | ezModules.obs 22 | ezModules.wlsunset 23 | ezModules.vscode 24 | ezModules.webcord 25 | ezModules.yazi 26 | ezModules.zellij 27 | 28 | ezModules.shell 29 | ezModules.fish 30 | ezModules.nushell 31 | 32 | ezModules.terminal 33 | ezModules.wezterm 34 | 35 | ezModules.editor 36 | ezModules.helix 37 | 38 | ezModules.theme 39 | ]; 40 | 41 | home = { 42 | username = "tntman"; 43 | homeDirectory = "/home/tntman"; 44 | 45 | stateVersion = "22.05"; 46 | 47 | packages = with pkgs; [ 48 | (pkgs.obsidian.override { 49 | electron = pkgs.electron_32; 50 | }) # notes 51 | anki # cards (obsidian spaced reptition has failed me again) 52 | 53 | nautilus # file manager 54 | loupe # image viewer 55 | fragments # for torrenting... :cluelesser: 56 | signal-desktop 57 | kicad 58 | freecad-wayland 59 | 60 | sptlrx # funni lyrics 61 | 62 | fractal # matrix go brrr 63 | polari # IRC go brrr 64 | (pkgs.feishin.override { 65 | # now this is just cursed 66 | electron_31 = pkgs.electron_32; 67 | }) # music go brrr 68 | protonup-qt # proton-GE go brrr 69 | protontricks # proton sound go brrr 70 | pavucontrol # sound go brrr 71 | openttd # gamig time 72 | inputs.zen-browser.packages."${system}".default # browser go brrr 73 | slack 74 | zed-editor 75 | 76 | # CLI utils 77 | btop # monitoring stuff 78 | ripgrep # searching stuff 79 | cachix # caching stuff 80 | cloudflared # ssh tunnel stuff 81 | nix-output-monitor # building stuff 82 | dive 83 | podman-tui 84 | podman-compose 85 | rsync 86 | ]; 87 | }; 88 | 89 | home.sessionVariables = { 90 | FLAKE = "/home/tntman/commafiles"; 91 | }; 92 | 93 | programs = { 94 | home-manager.enable = true; 95 | nix-index-database.comma.enable = true; 96 | }; 97 | 98 | services.easyeffects.enable = true; 99 | } 100 | -------------------------------------------------------------------------------- /wallpapers/Orbit.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Suya1671/commafiles/386603e0af2253d673f5299952eeaee37493b644/wallpapers/Orbit.png -------------------------------------------------------------------------------- /wallpapers/Particles.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Suya1671/commafiles/386603e0af2253d673f5299952eeaee37493b644/wallpapers/Particles.png -------------------------------------------------------------------------------- /wallpapers/colourlist.txt: -------------------------------------------------------------------------------- 1 | #060516 2 | #d4d5f2 3 | #060516 4 | #09081b 5 | #141327 6 | #2b2b41 7 | #60607a 8 | #dadbf8 9 | #e7e8ff 10 | #aaa8ff 11 | #ab8be3 12 | #ea9d00 13 | #ff5d66 14 | #27b892 15 | #00c2ba 16 | #acaaff 17 | #44a8e7 18 | #45455d 19 | #141327 20 | #e7e8ff 21 | #433889 22 | #acaaff 23 | #004d85 24 | #44a8e7 25 | #09081b 26 | #dadbf8 27 | #27b892 28 | #ab8be3 29 | #ea9d00 30 | #ff5d66 31 | #45455d 32 | #00c2ba 33 | -------------------------------------------------------------------------------- /wallpapers/gabriel.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Suya1671/commafiles/386603e0af2253d673f5299952eeaee37493b644/wallpapers/gabriel.png -------------------------------------------------------------------------------- /wallpapers/intoTheCatrix.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Suya1671/commafiles/386603e0af2253d673f5299952eeaee37493b644/wallpapers/intoTheCatrix.png -------------------------------------------------------------------------------- /wallpapers/justAReallyCoolArtwork.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Suya1671/commafiles/386603e0af2253d673f5299952eeaee37493b644/wallpapers/justAReallyCoolArtwork.png -------------------------------------------------------------------------------- /wallpapers/launch.jpg: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Suya1671/commafiles/386603e0af2253d673f5299952eeaee37493b644/wallpapers/launch.jpg -------------------------------------------------------------------------------- /wallpapers/linox.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Suya1671/commafiles/386603e0af2253d673f5299952eeaee37493b644/wallpapers/linox.png -------------------------------------------------------------------------------- /wallpapers/longRoadAhead.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Suya1671/commafiles/386603e0af2253d673f5299952eeaee37493b644/wallpapers/longRoadAhead.png -------------------------------------------------------------------------------- /wallpapers/theAlmightyHexagon.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Suya1671/commafiles/386603e0af2253d673f5299952eeaee37493b644/wallpapers/theAlmightyHexagon.png -------------------------------------------------------------------------------- /wallpapers/vivaldiBackground.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Suya1671/commafiles/386603e0af2253d673f5299952eeaee37493b644/wallpapers/vivaldiBackground.png -------------------------------------------------------------------------------- /wallpapers/waves.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/Suya1671/commafiles/386603e0af2253d673f5299952eeaee37493b644/wallpapers/waves.png --------------------------------------------------------------------------------