Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
bb038bfba0 |
@@ -1,17 +0,0 @@
|
|||||||
{
|
|
||||||
"permissions": {
|
|
||||||
"allow": [
|
|
||||||
"Read(//home/jashton/.local/state/nix/profiles/**)",
|
|
||||||
"Read(//nix/var/nix/profiles/**)",
|
|
||||||
"Read(//nix/store/**)",
|
|
||||||
"Bash(systemctl --user show-environment)",
|
|
||||||
"Bash(nix eval *)",
|
|
||||||
"Bash(nix-instantiate --parse /home/jashton/.dotfiles/home/jashton.nix)",
|
|
||||||
"Bash(git -C /home/jashton/.dotfiles status)",
|
|
||||||
"Bash(git -C /home/jashton/.dotfiles log -3 --stat)",
|
|
||||||
"Bash(gh api *)",
|
|
||||||
"Bash(nix-store -q --references /nix/store/256vhj20yfbajhvdm3cpaxradb4pi1ac-ollama-0.34.0)",
|
|
||||||
"Bash(nix-store -q --references /nix/store/pxgnnjm1p1zlavx8i2wjdmz484lq4k8v-ollama-0.34.0)"
|
|
||||||
]
|
|
||||||
}
|
|
||||||
}
|
|
||||||
@@ -1,3 +0,0 @@
|
|||||||
[submodule "plasma-manager"]
|
|
||||||
path = plasma-manager
|
|
||||||
url = https://github.com/nix-community/plasma-manager
|
|
||||||
@@ -1,11 +1,9 @@
|
|||||||
keys:
|
keys:
|
||||||
- &lavender age1az6l56h4m38jw2hm7t7a99wp9f88s845sg29grtmdpz72lrkc5cq66kmcv
|
- &lavender age1az6l56h4m38jw2hm7t7a99wp9f88s845sg29grtmdpz72lrkc5cq66kmcv
|
||||||
- &violet age1cd40qmufxzvw8dkml9340czqfq6ta3kxpjfj47jpavwn2t7ghywsxhqz79
|
- &violet age1cd40qmufxzvw8dkml9340czqfq6ta3kxpjfj47jpavwn2t7ghywsxhqz79
|
||||||
- &lilac age1dsf6z3hcr8qrtptdk6xyky9c99tdpjyrnuaawv4atme9rffhps9qpwdn6j
|
|
||||||
creation_rules:
|
creation_rules:
|
||||||
- path_regex: secrets/[^/]+\.yaml$
|
- path_regex: secrets/[^/]+\.yaml$
|
||||||
key_groups:
|
key_groups:
|
||||||
- age:
|
- age:
|
||||||
- *lavender
|
- *lavender
|
||||||
- *violet
|
- *violet
|
||||||
- *lilac
|
|
||||||
|
|||||||
@@ -1,131 +0,0 @@
|
|||||||
# .dotfiles
|
|
||||||
|
|
||||||
NixOS + Home Manager configuration for jashton's machines, built as a single flake.
|
|
||||||
|
|
||||||
## NixOS Flakes Structure
|
|
||||||
|
|
||||||
```
|
|
||||||
.
|
|
||||||
├── flake.nix / flake.lock Inputs + the 3 nixosConfigurations (violet, lilac, lavender)
|
|
||||||
├── hosts/<name>/ Per-machine entrypoint + hardware.nix
|
|
||||||
├── system/ Shared NixOS (system-level) configuration
|
|
||||||
├── home/ Home Manager configuration for user "jashton"
|
|
||||||
├── secrets/ + .sops.yaml sops-nix encrypted secrets
|
|
||||||
└── ports.registry State file written by the find-open-port script
|
|
||||||
```
|
|
||||||
|
|
||||||
**`flake.nix`** pins `nixpkgs` to `nixos-26.05` (plus an `nixpkgs-unstable` follower), and pulls in `home-manager`, `sops-nix`, `niri` (compositor), `wvkbd-src` (on-screen keyboard source), the DankMaterialShell trio (`dms`, `dms-plugin-registry`, `danksearch`), and `nixos-hardware`. Its `outputs` define three `nixosConfigurations`, one per host — each wires up the niri/dms-plugin-registry/sops-nix NixOS modules and a `home-manager.users.jashton` block importing `home/jashton.nix` (plus the `danksearch` home module).
|
|
||||||
|
|
||||||
**`hosts/`** — one directory per machine, each with `default.nix` (hostname + host-specific services/hardware tweaks, imports `../../system`) and `hardware.nix` (generated hardware scan):
|
|
||||||
- `violet` — imports the ThinkPad-specific security module (`system/security/thinkpad.nix`), disables lid-switch suspend, has (disabled) TLP power-profile tuning, and enables `input-remapper`.
|
|
||||||
- `lilac` — Framework laptop (Intel Core Ultra series 3, via `nixos-hardware`), fingerprint reader + Thunderbolt/bolt + Intel graphics acceleration.
|
|
||||||
- `lavender` — minimal host, just graphics enablement.
|
|
||||||
- Both `violet`/`lilac` open a Thunderbolt-networking point-to-point link (`thunderbolt0`, ports 4242).
|
|
||||||
|
|
||||||
**`system/`** — shared NixOS config imported by every host, split by concern:
|
|
||||||
- `packages.nix` — system-wide packages, unfree allowed, plus a hand-written `unix` script (`sudo nixos-rebuild switch`, then auto-commits/pushes the dotfiles repo on success) and Steam setup.
|
|
||||||
- `core/` — `boot.nix` (systemd-boot, `uinput` module), `audio.nix` (PipeWire/Bluetooth tuning), `env.nix` (zsh + oh-my-zsh, Nerd Font, flakes enabled, shell aliases), `locale.nix` (Denver/en_US), `power.nix` (deep sleep).
|
|
||||||
- `security/` — `sops.nix` (age-via-SSH-host-key secrets), `sudo.nix` (passwordless `tlp` for jashton), `systemd.nix`, `thinkpad.nix` (fprintd), `users.nix` (user/group defs).
|
|
||||||
- `network/` — NetworkManager + firewall, plus `pi-hole.nix` (a Pi-hole container run via Podman `oci-containers`).
|
|
||||||
- `services/` — currently an empty placeholder module (compositor/greeter services are declared per-host instead, see `hosts/violet/default.nix`).
|
|
||||||
- `virtualisation/` — Podman (with Docker compat), Waydroid, VirtualBox, libvirtd.
|
|
||||||
|
|
||||||
**`home/`** — Home Manager config for `jashton`:
|
|
||||||
- `jashton.nix` — top-level user config: session vars, SSH client config (aliases for `lavender`/`violet`/`lilac`/`heliotrope`), the `lan-mouse` user service, workspace directory scaffolding (`~/dev`, `~/school`, etc.), a `custom_wvkbd` package override (builds `wvkbd` from `wvkbd-src` against the `.custom.h` files below), and a set of hand-written shell tools installed as packages: `jroot`/`jbuild`/`jrun`/`jtest`/`jclean` (Java project tooling — see below), `fkill` (interactive `pkill` by name), `find-open-port` (dev-port registry in `ports.registry`).
|
|
||||||
- `programs/` — `default.nix` imports `alacritty.nix` (terminal theme/font), `git.nix` (identity + ignores), `nvim.nix` (full Neovim config: LSP, completion, Java/jdtls + DAP debugging — see Keybinds). `keymap.custom.h`, `layout.custom.h`, `config.custom.h` (+ `.bak` backups) are C source overrides for wvkbd's `mobintl` on-screen-keyboard layout, spliced into the `custom_wvkbd` build in `jashton.nix`.
|
|
||||||
- `desktop/` — `default.nix` imports `niri.nix` (the niri compositor config, touch-gesture daemon, and on-screen-keyboard launcher — see Keybinds); `wvkbd.nix` is currently an empty stub.
|
|
||||||
|
|
||||||
**`secrets/secrets.yaml`** + **`.sops.yaml`** — sops-encrypted secrets (currently Vaultwarden client id/secret), decrypted at activation time using each host's SSH host key as the age identity.
|
|
||||||
|
|
||||||
## Keybinds
|
|
||||||
|
|
||||||
### Niri (compositor, `home/desktop/niri.nix`)
|
|
||||||
`Mod` is niri's default modifier (Super/Windows key).
|
|
||||||
|
|
||||||
| Bind | Action |
|
|
||||||
|---|---|
|
|
||||||
| `Mod+Return` | Spawn Alacritty |
|
|
||||||
| `Mod+Space` | Toggle DMS spotlight launcher |
|
|
||||||
| `Mod+F` | Fullscreen focused window |
|
|
||||||
| `Mod+V` | Toggle floating for focused window |
|
|
||||||
| `Mod+X` | Close focused window |
|
|
||||||
| `Mod+H` / `Mod+L` | Focus column left / right |
|
|
||||||
| `Mod+J` / `Mod+K` | Focus window down / up |
|
|
||||||
| `Mod+Shift+H` / `Mod+Shift+L` | Move column left / right |
|
|
||||||
| `Mod+Shift+J` / `Mod+Shift+K` | Move column to workspace down / up |
|
|
||||||
| `Mod+U` / `Mod+N` | Focus workspace up / down |
|
|
||||||
| `Mod+Shift+P` | Toggle overview |
|
|
||||||
| `Mod+P` | Toggle the on-screen keyboard (signals `wvkbd-mobintl`) |
|
|
||||||
| `Mod+Shift+E` | Quit niri |
|
|
||||||
| `Print` | Screenshot (interactive) |
|
|
||||||
| `Ctrl+Print` | Screenshot whole screen |
|
|
||||||
| `XF86AudioRaiseVolume` / `XF86AudioLowerVolume` | Volume ±5% |
|
|
||||||
| `XF86AudioMute` | Toggle mute |
|
|
||||||
| `XF86MonBrightnessUp` / `XF86MonBrightnessDown` | Brightness ±5 (via `dms ipc call brightness`) |
|
|
||||||
|
|
||||||
### Touchscreen gestures (`lisgd`, launched at niri startup, `home/desktop/niri.nix`)
|
|
||||||
| Gesture | Action |
|
|
||||||
|---|---|
|
|
||||||
| 3-finger swipe left → right | Focus column left |
|
|
||||||
| 3-finger swipe right → left | Focus column right |
|
|
||||||
| 3-finger swipe up → down | Focus workspace up |
|
|
||||||
| 3-finger swipe down → up | Focus workspace down |
|
|
||||||
| 4-finger swipe down → up | Toggle DMS spotlight |
|
|
||||||
| 1-finger swipe down → up, starting from the bottom edge | Toggle the on-screen keyboard |
|
|
||||||
| 1-finger swipe up → down, starting from the top edge | Maximize window to edges |
|
|
||||||
|
|
||||||
### On-screen keyboard (custom `wvkbd-mobintl` build, `home/programs/{layout,config,keymap}.custom.h`)
|
|
||||||
- Toggle show/hide: `Mod+P` or the bottom-edge swipe gesture above (both send `SIGRTMIN` to `wvkbd-mobintl`).
|
|
||||||
- The "⌨" key (`NextLayer`) cycles keyboard layers: `Full ⇄ Special` in portrait, `Landscape ⇄ LandscapeSpecial` in landscape.
|
|
||||||
- `Abc` (in the `Special` layer) returns to the base layer.
|
|
||||||
- `Cmp` (Compose) + a letter opens that letter's accent/diacritic picker (e.g. `Cmp` then `e` → é/è/ê/ë/ē…).
|
|
||||||
- The `q` key doubles as a shortcut into the emoji layer.
|
|
||||||
- Alternate script layouts exist in the layout source (Cyrillic, Arabic, Persian, Greek, Georgian, Hebrew) but are not wired into the active `layers[]` cycle — only `Full`/`Special` (portrait) and `Landscape`/`LandscapeSpecial` (landscape) are reachable from the running config.
|
|
||||||
|
|
||||||
### Neovim (`home/programs/nvim.nix`, leader = `<Space>`)
|
|
||||||
General:
|
|
||||||
| Bind | Action |
|
|
||||||
|---|---|
|
|
||||||
| `<leader>w` | Write file |
|
|
||||||
| `<leader>q` | Quit |
|
|
||||||
| `<leader>wq` | Write and quit |
|
|
||||||
| `<leader>x` | `chmod +x` the current file |
|
|
||||||
| `Q` | Disabled (no-op) |
|
|
||||||
| `o` / `O` | Open a line below/above, stay in normal mode |
|
|
||||||
| `jj` (insert mode) | Escape to normal mode |
|
|
||||||
|
|
||||||
Completion (insert mode, nvim-cmp):
|
|
||||||
| Bind | Action |
|
|
||||||
|---|---|
|
|
||||||
| `<C-Space>` | Trigger completion |
|
|
||||||
| `<CR>` | Confirm selection |
|
|
||||||
| `<C-n>` / `<C-p>` | Next / previous item |
|
|
||||||
|
|
||||||
Java LSP (buffer-local, active once `jdtls` attaches to a `.java` file):
|
|
||||||
| Bind | Action |
|
|
||||||
|---|---|
|
|
||||||
| `gd` | Go to definition |
|
|
||||||
| `gr` | Find references |
|
|
||||||
| `K` | Hover docs |
|
|
||||||
| `<leader>rn` | Rename symbol |
|
|
||||||
| `<leader>ca` | Code action |
|
|
||||||
| `<leader>f` | Format buffer |
|
|
||||||
| `<leader>oi` | Organize imports |
|
|
||||||
|
|
||||||
Debugging (nvim-dap / nvim-dap-ui, global):
|
|
||||||
| Bind | Action |
|
|
||||||
|---|---|
|
|
||||||
| `<leader>db` | Toggle breakpoint |
|
|
||||||
| `<leader>dB` | Conditional breakpoint (prompts for condition) |
|
|
||||||
| `<leader>dc` | Continue / start session (prompts for a config if none is running) |
|
|
||||||
| `<leader>dn` | Step over |
|
|
||||||
| `<leader>di` | Step into |
|
|
||||||
| `<leader>du` | Step out |
|
|
||||||
| `<leader>dr` | Toggle the debug REPL |
|
|
||||||
| `<leader>dq` | Terminate session |
|
|
||||||
| `<leader>de` (normal + visual) | Evaluate expression under cursor / selection |
|
|
||||||
|
|
||||||
### Other applications
|
|
||||||
- **Alacritty** (`home/programs/alacritty.nix`) — only theme/font/window settings are configured; keybindings are Alacritty's unmodified defaults.
|
|
||||||
- Everything else installed (LibreWolf, Thunderbird, Discord, VLC, Zathura, etc.) is installed via `home.packages`/`environment.systemPackages` with no keybind customization in this repo — they run with upstream defaults.
|
|
||||||
- `input-remapper` is enabled on `violet` (`hosts/violet/default.nix`) but has no remapping profile committed in this repo.
|
|
||||||
@@ -1,129 +1,38 @@
|
|||||||
{
|
{
|
||||||
"nodes": {
|
"nodes": {
|
||||||
"dank-greeter": {
|
"danksearch": {
|
||||||
"inputs": {
|
|
||||||
"dank-qml-common": "dank-qml-common",
|
|
||||||
"nixpkgs": [
|
|
||||||
"nixpkgs"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1789701749,
|
|
||||||
"narHash": "sha256-vVJUgNEUa+trNXZFK7DGmuV9HMz4GMiA+f+de6k51hw=",
|
|
||||||
"owner": "AvengeMedia",
|
|
||||||
"repo": "dank-greeter",
|
|
||||||
"rev": "c792f1e13287fed01b1bf1a80654553019f3e0cb",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "AvengeMedia",
|
|
||||||
"repo": "dank-greeter",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"dank-qml-common": {
|
|
||||||
"flake": false,
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1789701545,
|
|
||||||
"narHash": "sha256-aNZwXDlF1NMIrMtPL3ZtDg5Q8LZY62DjnpPRoe2453g=",
|
|
||||||
"owner": "AvengeMedia",
|
|
||||||
"repo": "dank-qml-common",
|
|
||||||
"rev": "55d3897192f47692b7961812d94ad18004fa0ad8",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "AvengeMedia",
|
|
||||||
"repo": "dank-qml-common",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"dank-qml-common_2": {
|
|
||||||
"flake": false,
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1789755182,
|
|
||||||
"narHash": "sha256-47BBqvpzKSKo65gRnGirwulJ/c6N3Dg+vEfErwXTu58=",
|
|
||||||
"owner": "AvengeMedia",
|
|
||||||
"repo": "dank-qml-common",
|
|
||||||
"rev": "ff99ec8a93c4a52d792e7020575540582f249ea9",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "AvengeMedia",
|
|
||||||
"repo": "dank-qml-common",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"dank-qml-common_3": {
|
|
||||||
"flake": false,
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1788376015,
|
|
||||||
"narHash": "sha256-/tT8rTznLADndTwLBzdgzzgfJH1ZhYQibYo5v/F8U+U=",
|
|
||||||
"owner": "AvengeMedia",
|
|
||||||
"repo": "dank-qml-common",
|
|
||||||
"rev": "26396ce432d6c71c3f5367438f96f4a8d667e160",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "AvengeMedia",
|
|
||||||
"repo": "dank-qml-common",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"dankcalendar": {
|
|
||||||
"inputs": {
|
|
||||||
"dank-qml-common": "dank-qml-common_2",
|
|
||||||
"nixpkgs": [
|
|
||||||
"nixpkgs"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1789758001,
|
|
||||||
"narHash": "sha256-9mkKoWExAmPdKT5VEK5oW7XFs6wTaDtqXa8OUOS2UKk=",
|
|
||||||
"owner": "AvengeMedia",
|
|
||||||
"repo": "dankcalendar",
|
|
||||||
"rev": "feebbb5de09e57467c6bf3e97ec9366af8ad5c6b",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "AvengeMedia",
|
|
||||||
"repo": "dankcalendar",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"dgop": {
|
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"nixpkgs": [
|
"nixpkgs": [
|
||||||
"nixpkgs"
|
"nixpkgs"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1789657958,
|
"lastModified": 1784433272,
|
||||||
"narHash": "sha256-0zWMFcxLZEVPzCRe5yDgPlPHBNgw3MMq78MAUvGNu/4=",
|
"narHash": "sha256-5Gz3pC/rcn8LLwzLZZhrpPMqY+PDdUzoFtXV3uWoitg=",
|
||||||
"owner": "AvengeMedia",
|
"owner": "AvengeMedia",
|
||||||
"repo": "dgop",
|
"repo": "danksearch",
|
||||||
"rev": "56a43ff5b8c6b14c5a7c190a69eec43f2297d76b",
|
"rev": "4b4905e2ef3454230fb648d2139f3139b742b0eb",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
"owner": "AvengeMedia",
|
"owner": "AvengeMedia",
|
||||||
"repo": "dgop",
|
"repo": "danksearch",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"dms": {
|
"dms": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"dank-qml-common": "dank-qml-common_3",
|
|
||||||
"flake-compat": "flake-compat",
|
"flake-compat": "flake-compat",
|
||||||
"nixpkgs": [
|
"nixpkgs": [
|
||||||
"nixpkgs"
|
"nixpkgs"
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1789657660,
|
"lastModified": 1785111455,
|
||||||
"narHash": "sha256-NPYX33iiXo6aBwh7umfJzeZQBedupOG7pk5z171ID3s=",
|
"narHash": "sha256-aTNuC9NDBnYAeEtFsleeUwmGX3AZlKOutbl+LQRPkmQ=",
|
||||||
"owner": "AvengeMedia",
|
"owner": "AvengeMedia",
|
||||||
"repo": "DankMaterialShell",
|
"repo": "DankMaterialShell",
|
||||||
"rev": "2db7646fe3ab47fddfdb8723f2da07d61a0d47ac",
|
"rev": "069ddab041c738236a8910e4c39b65d9628d3018",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -140,11 +49,11 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1789789500,
|
"lastModified": 1784857968,
|
||||||
"narHash": "sha256-rBndooJeUIgPQewnYn31dx1yrk/fhAsKN8A3q4KcbGs=",
|
"narHash": "sha256-83haLQzxrk6sCX76iQlloHWQ+TD0RKsK+LdVTMikNwk=",
|
||||||
"owner": "AvengeMedia",
|
"owner": "AvengeMedia",
|
||||||
"repo": "dms-plugin-registry",
|
"repo": "dms-plugin-registry",
|
||||||
"rev": "f50a3779a1e20b80e9148181f5f9f053664c4b74",
|
"rev": "78d478f34ad6790faea447c37d16bab63e1d3570",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -176,11 +85,11 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1789267039,
|
"lastModified": 1784350909,
|
||||||
"narHash": "sha256-LWiBv9yAYFi2LPbUhDGHPGKYskJQjj2fw12OlyO1uQo=",
|
"narHash": "sha256-ZWyzLbS1yKUTeFJLmdVuWNnHttL333/ldJbEE+KzCrM=",
|
||||||
"owner": "nix-community",
|
"owner": "nix-community",
|
||||||
"repo": "home-manager",
|
"repo": "home-manager",
|
||||||
"rev": "ec172013fa62135f58fb58dd17ae9651e8f39727",
|
"rev": "4ce190229c73d44536caa7072f6308fb2d8feeb3",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -200,11 +109,11 @@
|
|||||||
"xwayland-satellite-unstable": "xwayland-satellite-unstable"
|
"xwayland-satellite-unstable": "xwayland-satellite-unstable"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1785857305,
|
"lastModified": 1784874881,
|
||||||
"narHash": "sha256-25q05zpF1sqOCxPPUG9DPPGd+EDW7SiAOWCzBWRS7r0=",
|
"narHash": "sha256-u4jhSIf/Un0qZB+Cn3hTTaHSI20XeAxYbA5o4faqdJs=",
|
||||||
"owner": "sodiboo",
|
"owner": "sodiboo",
|
||||||
"repo": "niri-flake",
|
"repo": "niri-flake",
|
||||||
"rev": "9ee3e13b60643448228353097880521658b2fe0e",
|
"rev": "ef7a2a3d719af46b906c22a3ebfb7d65627b2cd2",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -233,11 +142,11 @@
|
|||||||
"niri-unstable": {
|
"niri-unstable": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1785701241,
|
"lastModified": 1784570726,
|
||||||
"narHash": "sha256-ircVOzPWRircI39ac/tqJajr5OoJxEVrDlBb05TULEk=",
|
"narHash": "sha256-9EMn69JBcFWFgUM7f0VBAX+jBby5b9H3M59U75+5yI4=",
|
||||||
"owner": "YaLTeR",
|
"owner": "YaLTeR",
|
||||||
"repo": "niri",
|
"repo": "niri",
|
||||||
"rev": "feb3e43f1475e0865bb89cbd1e898b34d1d2ccf6",
|
"rev": "7f26c3ee804fb6ed458ef7fb0e3c794f14e0b3bc",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -246,34 +155,13 @@
|
|||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"nixos-hardware": {
|
|
||||||
"inputs": {
|
|
||||||
"nixpkgs": [
|
|
||||||
"nixpkgs"
|
|
||||||
]
|
|
||||||
},
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1789752250,
|
|
||||||
"narHash": "sha256-q0J27mJDfd4BM9a7KcMVbcRmqyU+goQwudbMIu66qsg=",
|
|
||||||
"owner": "NixOS",
|
|
||||||
"repo": "nixos-hardware",
|
|
||||||
"rev": "b2d7d02644f0002535a3bb51a73780945cdc7ba4",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "NixOS",
|
|
||||||
"ref": "master",
|
|
||||||
"repo": "nixos-hardware",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"nixpkgs": {
|
"nixpkgs": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1785828668,
|
"lastModified": 1784796856,
|
||||||
"narHash": "sha256-8fsyqeO+mJqvIzeO4xIpgJe/f7MTbbVTEC6RT6WSXNs=",
|
"narHash": "sha256-wWFrV5/Qbm+lyt5x20E/bSbfJiGKMo4RCxZV8cl/WZI=",
|
||||||
"owner": "NixOS",
|
"owner": "NixOS",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "e72e4f299401a3689d4b3d5fc6496b11db7064eb",
|
"rev": "e2587caef70cea85dd97d7daab492899902dbf5d",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -301,11 +189,11 @@
|
|||||||
},
|
},
|
||||||
"nixpkgs-unstable": {
|
"nixpkgs-unstable": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1789684949,
|
"lastModified": 1784796856,
|
||||||
"narHash": "sha256-ZKhUe/2IJUq1JhKxKMu8rbkgSGmPP2ZCqlIPn40aGCM=",
|
"narHash": "sha256-wWFrV5/Qbm+lyt5x20E/bSbfJiGKMo4RCxZV8cl/WZI=",
|
||||||
"owner": "nixos",
|
"owner": "nixos",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "e554fab72f81915600f3f449b786fd9af40439a5",
|
"rev": "e2587caef70cea85dd97d7daab492899902dbf5d",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -317,11 +205,11 @@
|
|||||||
},
|
},
|
||||||
"nixpkgs_2": {
|
"nixpkgs_2": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1789749394,
|
"lastModified": 1784856561,
|
||||||
"narHash": "sha256-cFTsMQz8Hzn8MT49oaeLSHg62tE86NykugCWkeM2ypk=",
|
"narHash": "sha256-J+Bx1Z6Oeoj2FgnBhRMKyUhhtDoOpTgXYaVLZpDjW4A=",
|
||||||
"owner": "nixos",
|
"owner": "nixos",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "cf9d2fb3e50fa1cd5114c47505ea9177f7ff5f49",
|
"rev": "597283ad8aa0b331c788e97c4c262d58877074ef",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -333,14 +221,11 @@
|
|||||||
},
|
},
|
||||||
"root": {
|
"root": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"dank-greeter": "dank-greeter",
|
"danksearch": "danksearch",
|
||||||
"dankcalendar": "dankcalendar",
|
|
||||||
"dgop": "dgop",
|
|
||||||
"dms": "dms",
|
"dms": "dms",
|
||||||
"dms-plugin-registry": "dms-plugin-registry",
|
"dms-plugin-registry": "dms-plugin-registry",
|
||||||
"home-manager": "home-manager",
|
"home-manager": "home-manager",
|
||||||
"niri": "niri",
|
"niri": "niri",
|
||||||
"nixos-hardware": "nixos-hardware",
|
|
||||||
"nixpkgs": "nixpkgs_2",
|
"nixpkgs": "nixpkgs_2",
|
||||||
"nixpkgs-unstable": "nixpkgs-unstable",
|
"nixpkgs-unstable": "nixpkgs-unstable",
|
||||||
"sops-nix": "sops-nix",
|
"sops-nix": "sops-nix",
|
||||||
@@ -354,11 +239,11 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1789691124,
|
"lastModified": 1783174389,
|
||||||
"narHash": "sha256-k+I+R6uwHX3VcJ7326qLV6vCahZUgsVl+i8sSU/Stxk=",
|
"narHash": "sha256-aCWC8ngycU7OdJrU2+Je3qf+1a2ykuBvpPhZT/9tXMc=",
|
||||||
"owner": "Mic92",
|
"owner": "Mic92",
|
||||||
"repo": "sops-nix",
|
"repo": "sops-nix",
|
||||||
"rev": "1e73e8f7176d65e1b55e324de099bbfff4b2c574",
|
"rev": "f1406619a3884cd5c47992a70b8b35c9c0fcb4c9",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
|
|||||||
@@ -27,33 +27,18 @@
|
|||||||
inputs.nixpkgs.follows = "nixpkgs";
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
};
|
};
|
||||||
|
|
||||||
dgop = {
|
|
||||||
url = "github:AvengeMedia/dgop";
|
|
||||||
inputs.nixpkgs.follows = "nixpkgs";
|
|
||||||
};
|
|
||||||
|
|
||||||
dank-greeter = {
|
|
||||||
url = "github:AvengeMedia/dank-greeter";
|
|
||||||
inputs.nixpkgs.follows = "nixpkgs";
|
|
||||||
};
|
|
||||||
|
|
||||||
dankcalendar = {
|
|
||||||
url = "github:AvengeMedia/dankcalendar";
|
|
||||||
inputs.nixpkgs.follows = "nixpkgs";
|
|
||||||
};
|
|
||||||
|
|
||||||
dms-plugin-registry = {
|
dms-plugin-registry = {
|
||||||
url = "github:AvengeMedia/dms-plugin-registry";
|
url = "github:AvengeMedia/dms-plugin-registry";
|
||||||
inputs.nixpkgs.follows = "nixpkgs";
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
};
|
};
|
||||||
|
|
||||||
nixos-hardware = {
|
danksearch = {
|
||||||
url = "github:NixOS/nixos-hardware/master";
|
url = "github:AvengeMedia/danksearch";
|
||||||
inputs.nixpkgs.follows = "nixpkgs";
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
outputs = { nixpkgs, home-manager, sops-nix, niri, dms, dgop, dank-greeter, dankcalendar, dms-plugin-registry, wvkbd-src, nixos-hardware, ... }@inputs: {
|
outputs = { nixpkgs, home-manager, sops-nix, niri, dms, dms-plugin-registry, danksearch, wvkbd-src, ... }@inputs: {
|
||||||
nixosConfigurations = {
|
nixosConfigurations = {
|
||||||
violet = nixpkgs.lib.nixosSystem {
|
violet = nixpkgs.lib.nixosSystem {
|
||||||
system = "x86_64-linux";
|
system = "x86_64-linux";
|
||||||
@@ -63,9 +48,6 @@
|
|||||||
./hosts/violet/default.nix
|
./hosts/violet/default.nix
|
||||||
|
|
||||||
niri.nixosModules.niri
|
niri.nixosModules.niri
|
||||||
dms.nixosModules.default
|
|
||||||
|
|
||||||
dank-greeter.nixosModules.default
|
|
||||||
dms-plugin-registry.nixosModules.default
|
dms-plugin-registry.nixosModules.default
|
||||||
sops-nix.nixosModules.sops
|
sops-nix.nixosModules.sops
|
||||||
|
|
||||||
@@ -78,39 +60,7 @@
|
|||||||
home-manager.users.jashton = {
|
home-manager.users.jashton = {
|
||||||
imports = [
|
imports = [
|
||||||
./home/jashton.nix
|
./home/jashton.nix
|
||||||
dankcalendar.homeModules.default
|
danksearch.homeModules.default
|
||||||
|
|
||||||
];
|
|
||||||
};
|
|
||||||
}
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
lilac = nixpkgs.lib.nixosSystem {
|
|
||||||
system = "x86_64-linux";
|
|
||||||
specialArgs = { inherit inputs; };
|
|
||||||
|
|
||||||
modules = [
|
|
||||||
./hosts/lilac/default.nix
|
|
||||||
|
|
||||||
niri.nixosModules.niri
|
|
||||||
dms-plugin-registry.nixosModules.default
|
|
||||||
dms.nixosModules.default
|
|
||||||
|
|
||||||
dank-greeter.nixosModules.default
|
|
||||||
sops-nix.nixosModules.sops
|
|
||||||
nixos-hardware.nixosModules.framework-intel-core-ultra-series3
|
|
||||||
|
|
||||||
home-manager.nixosModules.home-manager {
|
|
||||||
home-manager.useGlobalPkgs = true;
|
|
||||||
home-manager.useUserPackages = true;
|
|
||||||
home-manager.extraSpecialArgs = { inherit inputs; };
|
|
||||||
|
|
||||||
home-manager.users.jashton = {
|
|
||||||
imports = [
|
|
||||||
./home/jashton.nix
|
|
||||||
dankcalendar.homeModules.default
|
|
||||||
|
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
@@ -125,9 +75,6 @@
|
|||||||
./hosts/lavender/default.nix
|
./hosts/lavender/default.nix
|
||||||
|
|
||||||
niri.nixosModules.niri
|
niri.nixosModules.niri
|
||||||
dms.nixosModules.default
|
|
||||||
|
|
||||||
dank-greeter.nixosModules.default
|
|
||||||
dms-plugin-registry.nixosModules.default
|
dms-plugin-registry.nixosModules.default
|
||||||
sops-nix.nixosModules.sops
|
sops-nix.nixosModules.sops
|
||||||
|
|
||||||
@@ -139,8 +86,7 @@
|
|||||||
home-manager.users.jashton = {
|
home-manager.users.jashton = {
|
||||||
imports = [
|
imports = [
|
||||||
./home/jashton.nix
|
./home/jashton.nix
|
||||||
dankcalendar.homeModules.default
|
danksearch.homeModules.default
|
||||||
|
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
|
Before Width: | Height: | Size: 566 KiB |
|
Before Width: | Height: | Size: 3.6 MiB |
@@ -1,150 +0,0 @@
|
|||||||
{ config, lib, pkgs, inputs, ... }:
|
|
||||||
|
|
||||||
let
|
|
||||||
launch-lisgd = pkgs.writeShellScriptBin "launch-lisgd" ''
|
|
||||||
# Search for the capacitive touch layer and extract its event number.
|
|
||||||
# UPDATE 'Touchscreen' below to match the unique word you found in step 1.
|
|
||||||
TOUCH_EVENT=$(grep -i -E 'name=".*Finger.*"' -A 5 /proc/bus/input/devices | grep -o 'event[0-9]\+' | head -n 1)
|
|
||||||
|
|
||||||
if [ -n "$TOUCH_EVENT" ]; then
|
|
||||||
# Start lisgd locked exclusively to the finger digitizer
|
|
||||||
${pkgs.lisgd}/bin/lisgd -t 30 -m 150 -r 45 -d "/dev/input/$TOUCH_EVENT" \
|
|
||||||
-g "3,LR,*,*,P,niri msg action focus-column-left && sleep 0.4" \
|
|
||||||
-g "3,RL,*,*,P,niri msg action focus-column-right && sleep 0.4" \
|
|
||||||
-g "3,UD,*,*,P,niri msg action focus-workspace-up && sleep 0.4" \
|
|
||||||
-g "3,DU,*,*,P,niri msg action focus-workspace-down && sleep 0.4" \
|
|
||||||
-g "4,DU,*,*,P,dms ipc spotlight toggle && sleep 0.4" \
|
|
||||||
-g "1,DU,B,*,pkill -u jashton -RTMIN wvkbd-mobintl && sleep 0.4" \
|
|
||||||
-g "1,UD,T,*,P,niri msg action maximize-window-to-edges && sleep 0.4"
|
|
||||||
fi
|
|
||||||
'';
|
|
||||||
|
|
||||||
launch-wvkbd = pkgs.writeShellScriptBin "launch-wvkbd" ''
|
|
||||||
THEME_CACHE="$HOME/.cache/DankMaterialShell/dms-colors.json"
|
|
||||||
|
|
||||||
if [ -f "$THEME_CACHE" ]; then
|
|
||||||
BG=$(jq -r '.["colors"]["dark"]["background"]' "$THEME_CACHE" | tr -d '#')
|
|
||||||
FG=$(jq -r '.["colors"]["dark"]["surface_container_lowest"]' "$THEME_CACHE" | tr -d '#')
|
|
||||||
TXT=$(jq -r '.["colors"]["dark"]["on_background"]' "$THEME_CACHE" | tr -d '#')
|
|
||||||
PRIMARY=$(jq -r '.["colors"]["dark"]["surface_container_lowest"]' "$THEME_CACHE" | tr -d '#')
|
|
||||||
ON_PRIMARY=$(jq -r '.["colors"]["dark"]["on_background"]' "$THEME_CACHE" | tr -d '#')
|
|
||||||
|
|
||||||
wvkbd-mobintl --hidden --no-popup --bg "$BG" --press "$BG" --fg "$FG" --text "$TXT" --fg-sp "$PRIMARY" --text-sp "$ON_PRIMARY" -L 300
|
|
||||||
else
|
|
||||||
wvkbd-mobintl --hidden --no-popup
|
|
||||||
fi
|
|
||||||
'';
|
|
||||||
in
|
|
||||||
|
|
||||||
{
|
|
||||||
|
|
||||||
xdg.portal = {
|
|
||||||
enable = true;
|
|
||||||
config.niri = {
|
|
||||||
default = [ "gnome" "gtk" ];
|
|
||||||
"org.freedesktop.impl.portal.FileChooser" = [ "gtk" ];
|
|
||||||
};
|
|
||||||
extraPortals = [
|
|
||||||
pkgs.xdg-desktop-portal-gnome
|
|
||||||
pkgs.xdg-desktop-portal-gtk
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
#programs.niri.enable = true;
|
|
||||||
xdg.configFile."niri/config.kdl".text = lib.mkForce ''
|
|
||||||
input {
|
|
||||||
keyboard {
|
|
||||||
xkb {
|
|
||||||
layout "us"
|
|
||||||
model ""
|
|
||||||
rules ""
|
|
||||||
variant ""
|
|
||||||
}
|
|
||||||
repeat-delay 600
|
|
||||||
repeat-rate 25
|
|
||||||
track-layout "global"
|
|
||||||
}
|
|
||||||
touchpad {
|
|
||||||
tap
|
|
||||||
natural-scroll
|
|
||||||
}
|
|
||||||
}
|
|
||||||
screenshot-path "~/media/pics/screenshots/%Y-%m-%d %H-%M-%S.png"
|
|
||||||
prefer-no-csd
|
|
||||||
layout {
|
|
||||||
gaps 8
|
|
||||||
struts {
|
|
||||||
left 0
|
|
||||||
right 0
|
|
||||||
top 0
|
|
||||||
bottom 0
|
|
||||||
}
|
|
||||||
focus-ring { off; }
|
|
||||||
border { off; }
|
|
||||||
default-column-width { proportion 1.000000; }
|
|
||||||
center-focused-column "never"
|
|
||||||
}
|
|
||||||
cursor {
|
|
||||||
xcursor-theme "default"
|
|
||||||
xcursor-size 24
|
|
||||||
}
|
|
||||||
hotkey-overlay { skip-at-startup; }
|
|
||||||
binds {
|
|
||||||
Ctrl+Print { screenshot-screen; }
|
|
||||||
Mod+F { fullscreen-window; }
|
|
||||||
Mod+H { focus-column-left; }
|
|
||||||
Mod+J { focus-window-down; }
|
|
||||||
Mod+K { focus-window-up; }
|
|
||||||
Mod+L { focus-column-right; }
|
|
||||||
Mod+N { focus-workspace-down; }
|
|
||||||
Mod+V { toggle-window-floating; }
|
|
||||||
Mod+P { spawn "pkill" "-RTMIN" "wvkbd-mobintl"; }
|
|
||||||
Mod+Return { spawn "alacritty"; }
|
|
||||||
Mod+Shift+E { quit; }
|
|
||||||
Mod+Shift+H { move-column-left; }
|
|
||||||
Mod+Shift+J { move-column-to-workspace-down; }
|
|
||||||
Mod+Shift+K { move-column-to-workspace-up; }
|
|
||||||
Mod+Shift+L { move-column-right; }
|
|
||||||
Mod+Shift+P { toggle-overview; }
|
|
||||||
Mod+Space { spawn "dms" "ipc" "spotlight" "toggle"; }
|
|
||||||
Mod+U { focus-workspace-up; }
|
|
||||||
Mod+X { close-window; }
|
|
||||||
Print { screenshot; }
|
|
||||||
XF86AudioLowerVolume { spawn "wpctl" "set-volume" "@DEFAULT_AUDIO_SINK@" "0.05-"; }
|
|
||||||
XF86AudioMute { spawn "wpctl" "set-mute" "@DEFAULT_AUDIO_SINK@" "toggle"; }
|
|
||||||
XF86AudioRaiseVolume { spawn "wpctl" "set-volume" "@DEFAULT_AUDIO_SINK@" "0.05+"; }
|
|
||||||
XF86MonBrightnessDown { spawn "dms" "ipc" "call" "brightness" "decrement" "5" ""; }
|
|
||||||
XF86MonBrightnessUp { spawn "dms" "ipc" "call" "brightness" "increment" "5" ""; }
|
|
||||||
}
|
|
||||||
spawn-at-startup "/nix/store/b1kxyzg5r6644mcmjh8jwsb8rinqzsw8-launch-wvkbd/bin/launch-wvkbd"
|
|
||||||
spawn-at-startup "/nix/store/l9k161qcs6ypzzbicjhkn8b203r610j6-launch-lisgd/bin/launch-lisgd"
|
|
||||||
window-rule {
|
|
||||||
draw-border-with-background true
|
|
||||||
geometry-corner-radius 25.000000 25.000000 25.000000 25.000000
|
|
||||||
clip-to-geometry true
|
|
||||||
}
|
|
||||||
|
|
||||||
window-rule {
|
|
||||||
match app-id="^Alacritty$"
|
|
||||||
|
|
||||||
background-effect {
|
|
||||||
blur true
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
overview {
|
|
||||||
backdrop-color "#987CA7"
|
|
||||||
}
|
|
||||||
|
|
||||||
gestures {
|
|
||||||
hot-corners {
|
|
||||||
off
|
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
include "/home/jashton/.config/niri/dms/outputs.kdl"
|
|
||||||
include "/home/jashton/.config/niri/dms/binds.kdl"
|
|
||||||
include "/home/jashton/.config/niri/dms/cursor.kdl"
|
|
||||||
include "/home/jashton/.config/niri/dms/windowrules.kdl"
|
|
||||||
'';
|
|
||||||
}
|
|
||||||
@@ -1,330 +0,0 @@
|
|||||||
{ config, lib, pkgs, inputs, ... }:
|
|
||||||
|
|
||||||
let
|
|
||||||
# Compile your custom wvkbd build
|
|
||||||
custom_wvkbd = pkgs.wvkbd.overrideAttrs (oldAttrs: {
|
|
||||||
# Pin the package version to the exact commit from your flake input
|
|
||||||
src = inputs.wvkbd-src;
|
|
||||||
version = "custom-git";
|
|
||||||
|
|
||||||
# Choose your preferred layout layout (e.g., mobintl, standard, cyrillic)
|
|
||||||
makeFlags = (oldAttrs.makeFlags or []) ++ [ "LAYOUT=mobintl" ];
|
|
||||||
|
|
||||||
# Optional: Swap out the layout with your own config.h file if you have one
|
|
||||||
preBuild = ''
|
|
||||||
cp ${./programs/layout.custom.h} layout.mobintl.h
|
|
||||||
cp ${./programs/config.custom.h} config.mobintl.h
|
|
||||||
cp ${./programs/keymap.custom.h} keymap.mobintl.h
|
|
||||||
'';
|
|
||||||
});
|
|
||||||
in
|
|
||||||
{
|
|
||||||
imports = [
|
|
||||||
./programs
|
|
||||||
./desktop
|
|
||||||
];
|
|
||||||
|
|
||||||
home.username = "jashton";
|
|
||||||
home.homeDirectory = "/home/jashton";
|
|
||||||
home.file.".zshrc".text = ''
|
|
||||||
# Zsh is configured globally at the NixOS system level.
|
|
||||||
# This file exists solely to prevent the zsh-newuser-install prompt.
|
|
||||||
'';
|
|
||||||
|
|
||||||
home.sessionVariables = {
|
|
||||||
EDITOR = "nvim";
|
|
||||||
NIXOS_OZONE_WL = "1"; # Forces Electron/Chromium apps to use Wayland natively
|
|
||||||
GTK_IM_MODULE = "wayland"; # Forces GTK apps to use Wayland text-input protocols
|
|
||||||
QT_IM_MODULE = "wayland"; # Forces Qt apps to use Wayland text-input protocols
|
|
||||||
TEXT_INPUT_PRESENT = "1"; # Explicitly signals virtual keyboard capability to the shell
|
|
||||||
JAVA_HOME = "${pkgs.jdk21.home}";
|
|
||||||
};
|
|
||||||
|
|
||||||
home.sessionPath = [
|
|
||||||
"$HOME/.cargo/bin"
|
|
||||||
];
|
|
||||||
|
|
||||||
home.packages = with pkgs; [
|
|
||||||
android-tools
|
|
||||||
antigravity
|
|
||||||
asciinema
|
|
||||||
claude-code
|
|
||||||
discord
|
|
||||||
eclipses.eclipse-java
|
|
||||||
ffmpeg
|
|
||||||
gemini-cli
|
|
||||||
kicad
|
|
||||||
libreoffice
|
|
||||||
librewolf
|
|
||||||
pdftk
|
|
||||||
picom
|
|
||||||
prismlauncher
|
|
||||||
scrot
|
|
||||||
signal-desktop
|
|
||||||
spotify
|
|
||||||
thunderbird
|
|
||||||
tor
|
|
||||||
tor-browser
|
|
||||||
vlc
|
|
||||||
wtype
|
|
||||||
xwayland-satellite
|
|
||||||
yt-dlp
|
|
||||||
zathura
|
|
||||||
|
|
||||||
custom_wvkbd
|
|
||||||
|
|
||||||
(pkgs.writeShellScriptBin "jroot" ''
|
|
||||||
d="$PWD"
|
|
||||||
while [ "$d" != "/" ]; do
|
|
||||||
if [ -f "$d/.classpath" ]; then printf '%s\n' "$d"; exit 0; fi
|
|
||||||
d="$(dirname "$d")"
|
|
||||||
done
|
|
||||||
echo "jroot: no .classpath found at or above $PWD" >&2
|
|
||||||
exit 1
|
|
||||||
'')
|
|
||||||
|
|
||||||
(pkgs.writeShellScriptBin "jbuild" ''
|
|
||||||
set -euo pipefail
|
|
||||||
if [ $# -lt 1 ]; then
|
|
||||||
echo "usage: jbuild <package.MainClass> [args...]" >&2
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
|
|
||||||
ROOT="$(jroot)"
|
|
||||||
cd "$ROOT"
|
|
||||||
mkdir -p bin
|
|
||||||
|
|
||||||
# Set the target directory, defaulting to the current directory (.) if $1 is empty
|
|
||||||
TARGET_DIR="$1"
|
|
||||||
SOURCES_FILE="SOURCES"
|
|
||||||
|
|
||||||
# Fix the find command to safely search the target directory
|
|
||||||
find "$TARGET_DIR" -name '*.java' > "$SOURCES_FILE"
|
|
||||||
|
|
||||||
if [ ! -s "$SOURCES_FILE" ]; then
|
|
||||||
# Fix the error message to reference the directory, not the output text file
|
|
||||||
echo "jbuild: no .java files found under $TARGET_DIR" >&2
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Source roots for every top-level package (assignments/assign04 -> package assign04, etc.).
|
|
||||||
# Needed so javac can resolve cross-package imports (eg. assign04 -> timing) and
|
|
||||||
# transitively compile whatever those imports require, even though TARGET_DIR only
|
|
||||||
# covers one subtree.
|
|
||||||
SOURCEPATH="assignments:labs:timing:playground:src"
|
|
||||||
|
|
||||||
javac -g --release 21 -encoding UTF-8 -d bin -cp "lib/*" -sourcepath "$SOURCEPATH" @"$SOURCES_FILE"
|
|
||||||
'')
|
|
||||||
|
|
||||||
(pkgs.writeShellScriptBin "jclean" ''
|
|
||||||
set -euo pipefail
|
|
||||||
ROOT="$(jroot)"
|
|
||||||
rm -rf "$ROOT/bin"
|
|
||||||
echo "cleaned $ROOT/bin"
|
|
||||||
'')
|
|
||||||
|
|
||||||
(pkgs.writeShellScriptBin "jrun" ''
|
|
||||||
set -euo pipefail
|
|
||||||
if [ $# -lt 3 ]; then
|
|
||||||
echo "usage: jrun <folder> <package> <MainClass> [args...]" >&2
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
ROOT="$(jroot)"
|
|
||||||
cd "$ROOT"
|
|
||||||
jbuild "$1"
|
|
||||||
MAIN="$2.$3"
|
|
||||||
shift 3
|
|
||||||
java -cp "bin:lib/*" "$MAIN" "$@"
|
|
||||||
'')
|
|
||||||
|
|
||||||
(pkgs.writeShellScriptBin "jtest" ''
|
|
||||||
set -euo pipefail
|
|
||||||
if [ "$#" -lt 1 ]; then
|
|
||||||
echo "usage: jtest <package.MainClass> [args...]"
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
|
|
||||||
# sort -V so 1.10.2 beats 1.9.0; plain tail -n1 sorts those the wrong way.
|
|
||||||
JUNIT="$(ls -1 "$HOME"/dev/jars/junit-platform-console-standalone-*.jar 2>/dev/null | sort -V | tail -n1 || true)"
|
|
||||||
if [ -z "$JUNIT" ]; then
|
|
||||||
echo "jtest: no junit-platform-console-standalone jar in ~/dev/jars" >&2
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
|
|
||||||
# --debug suspends the test JVM on start and waits for nvim-dap to attach
|
|
||||||
# on :5005 (see the "Attach to jtest" config in nvim.nix), so breakpoints
|
|
||||||
# set before running jtest --debug are hit from the very first test.
|
|
||||||
DEBUG_ARGS=()
|
|
||||||
if [[ "$1" = "debug" ]]; then
|
|
||||||
DEBUG_ARGS=(-agentlib:jdwp=transport=dt_socket,server=y,suspend=y,address=*:5005)
|
|
||||||
shift
|
|
||||||
echo "jtest: waiting for debugger to attach on 127.0.0.1:5005..." >&2
|
|
||||||
fi
|
|
||||||
|
|
||||||
ROOT="$(jroot)"
|
|
||||||
cd "$ROOT"
|
|
||||||
jbuild "$1"
|
|
||||||
if [ $# -eq 0 ]; then
|
|
||||||
exec java "''${DEBUG_ARGS[@]}" -jar "$JUNIT" execute --class-path "bin:lib/*" --scan-class-path --details=tree
|
|
||||||
fi
|
|
||||||
ARGS=""
|
|
||||||
for pkg in "$@"; do
|
|
||||||
ARGS="$ARGS --select-package $pkg"
|
|
||||||
done
|
|
||||||
exec java "''${DEBUG_ARGS[@]}" -jar "$JUNIT" execute --class-path "bin:lib/*" $ARGS --details=tree
|
|
||||||
'')
|
|
||||||
|
|
||||||
(pkgs.writeShellScriptBin "fkill" ''
|
|
||||||
set -eu
|
|
||||||
if [ $# -lt 1 ]; then
|
|
||||||
echo "usage: fkill <process-name>" >&2
|
|
||||||
echo "eg. fkill firefox" >&2
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
|
|
||||||
PROGRAM="$1"
|
|
||||||
|
|
||||||
if ! pgrep -x -- "$PROGRAM" >/dev/null 2>&1; then
|
|
||||||
echo "fkill: no process named '$PROGRAM'" >&2
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
|
|
||||||
pgrep -a -x -- "$PROGRAM"
|
|
||||||
printf 'Kill these? [y/N] '
|
|
||||||
read -r reply
|
|
||||||
case "$reply" in
|
|
||||||
[yY]*) pkill -x -- "$PROGRAM" ;;
|
|
||||||
*) echo "aborted" ;;
|
|
||||||
esac
|
|
||||||
'')
|
|
||||||
|
|
||||||
(pkgs.writeShellScriptBin "find-open-port" ''
|
|
||||||
set -u
|
|
||||||
if [ $# -lt 1 ]; then
|
|
||||||
echo "Please provide an application name, project directory, or other identifier."
|
|
||||||
echo ' Usage: find-open-port $HOME/dev/some-project'
|
|
||||||
echo " Usage: find-open-port some-app"
|
|
||||||
|
|
||||||
exit 1
|
|
||||||
fi
|
|
||||||
|
|
||||||
APP_NAME="$1"
|
|
||||||
REGISTRY_FILE="$HOME/.dotfiles/ports.registry"
|
|
||||||
|
|
||||||
MIN_PORT=8000
|
|
||||||
MAX_PORT=8999
|
|
||||||
MAX_RETRIES=50
|
|
||||||
|
|
||||||
mkdir -p "$(dirname "$REGISTRY_FILE")"
|
|
||||||
|
|
||||||
if [ -f "$REGISTRY_FILE" ] && grep -q "^$APP_NAME : " "$REGISTRY_FILE"; then
|
|
||||||
echo "Already registered:"
|
|
||||||
grep "^$APP_NAME : " "$REGISTRY_FILE"
|
|
||||||
exit 0
|
|
||||||
fi
|
|
||||||
|
|
||||||
echo "Searching for available port between $MIN_PORT and $MAX_PORT for $APP_NAME..."
|
|
||||||
|
|
||||||
for ((i=1; i<=MAX_RETRIES; i++)); do
|
|
||||||
RANDOM_PORT=$(shuf -i $MIN_PORT-$MAX_PORT -n 1)
|
|
||||||
|
|
||||||
if ! ss -tuln | grep -E -q ":$RANDOM_PORT\b"; then
|
|
||||||
if [ -f "$REGISTRY_FILE" ] && grep -q "\b$RANDOM_PORT\b" "$REGISTRY_FILE"; then
|
|
||||||
continue
|
|
||||||
fi
|
|
||||||
|
|
||||||
echo "$APP_NAME : $RANDOM_PORT" >> "$REGISTRY_FILE"
|
|
||||||
echo -e "\nSuccessfully wrote '$APP_NAME : $RANDOM_PORT' to $REGISTRY_FILE"
|
|
||||||
exit 0
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
|
|
||||||
echo -e "\nError: Could not find an open port between $MIN_PORT and $MAX_PORT after $MAX_RETRIES attempts."
|
|
||||||
exit 1
|
|
||||||
'')
|
|
||||||
];
|
|
||||||
|
|
||||||
home.activation = {
|
|
||||||
# 1. Create the persistent directories
|
|
||||||
createWorkspaceDirs = lib.hm.dag.entryAfter ["writeBoundary"] ''
|
|
||||||
$DRY_RUN_CMD mkdir -p $HOME/dev
|
|
||||||
$DRY_RUN_CMD mkdir -p $HOME/downloads
|
|
||||||
$DRY_RUN_CMD mkdir -p $HOME/life
|
|
||||||
$DRY_RUN_CMD mkdir -p $HOME/media/pics
|
|
||||||
$DRY_RUN_CMD mkdir -p $HOME/media/videos
|
|
||||||
$DRY_RUN_CMD mkdir -p $HOME/school
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
|
|
||||||
systemd.user.services.lan-mouse = {
|
|
||||||
Unit = {
|
|
||||||
Description = "Lan Mouse Daemon";
|
|
||||||
After = [ "graphical-session.target" ];
|
|
||||||
PartOf = [ "graphical-session.target" ];
|
|
||||||
};
|
|
||||||
Install = {
|
|
||||||
WantedBy = [ "graphical-session.target" ];
|
|
||||||
};
|
|
||||||
Service = {
|
|
||||||
# The --daemon flag ensures it runs silently in the background without opening the GUI
|
|
||||||
ExecStart = "${pkgs.lan-mouse}/bin/lan-mouse --daemon";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
programs.opencode = {
|
|
||||||
enable = true;
|
|
||||||
|
|
||||||
settings = {
|
|
||||||
provider = {
|
|
||||||
ollama = {
|
|
||||||
npm = "@ai-sdk/openai-compatible";
|
|
||||||
name = "Ollama (Local)";
|
|
||||||
options = {
|
|
||||||
baseURL = "http://localhost:11434/v1";
|
|
||||||
};
|
|
||||||
models = {
|
|
||||||
"qwen3-coder-next:q4_K_M" = {
|
|
||||||
name = "Qwen3 Coder Next";
|
|
||||||
};
|
|
||||||
"qwen3.6:35b-a3b-q4_K_M" = {
|
|
||||||
name = "Qwen3.6 35B Thinker";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
programs.ssh = {
|
|
||||||
enable = true;
|
|
||||||
enableDefaultConfig = false;
|
|
||||||
settings = {
|
|
||||||
"*" = {
|
|
||||||
forwardAgent = false;
|
|
||||||
addKeysToAgent = "no";
|
|
||||||
compression = false;
|
|
||||||
serverAliveInterval = 0;
|
|
||||||
serverAliveCountMax = 3;
|
|
||||||
hashKnownHosts = false;
|
|
||||||
userKnownHostsFile = "~/.ssh/known_hosts";
|
|
||||||
controlMaster = "no";
|
|
||||||
controlPath = "~/.ssh/master-%r@%n:%p";
|
|
||||||
controlPersist = "no";
|
|
||||||
};
|
|
||||||
"heliotrope" = {
|
|
||||||
hostname = "100.77.235.110";
|
|
||||||
};
|
|
||||||
"lavender" = {
|
|
||||||
hostname = "100.99.189.49";
|
|
||||||
};
|
|
||||||
"violet" = {
|
|
||||||
hostname = "100.101.100.84";
|
|
||||||
};
|
|
||||||
"lilac" = {
|
|
||||||
hostname = "100.82.51.88";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
home.stateVersion = "26.05"; # DO NOT CHANGE
|
|
||||||
}
|
|
||||||
@@ -1,307 +0,0 @@
|
|||||||
{ config, pkgs, ... }:
|
|
||||||
|
|
||||||
let
|
|
||||||
javaDebug = pkgs.vscode-extensions.vscjava.vscode-java-debug;
|
|
||||||
in
|
|
||||||
{
|
|
||||||
programs.neovim = {
|
|
||||||
enable = true;
|
|
||||||
viAlias = true;
|
|
||||||
vimAlias = true;
|
|
||||||
defaultEditor = true;
|
|
||||||
|
|
||||||
initLua = ''
|
|
||||||
vim.opt.number = true
|
|
||||||
vim.opt.relativenumber = true
|
|
||||||
vim.opt.tabstop = 2
|
|
||||||
vim.opt.softtabstop = 2
|
|
||||||
vim.opt.expandtab = true
|
|
||||||
vim.opt.shiftwidth = 2
|
|
||||||
vim.opt.smartindent = true
|
|
||||||
vim.opt.wrap = false
|
|
||||||
vim.opt.swapfile = false
|
|
||||||
vim.opt.backup = false
|
|
||||||
vim.opt.undofile = false
|
|
||||||
vim.opt.hlsearch = false
|
|
||||||
vim.opt.incsearch = true
|
|
||||||
vim.opt.termguicolors = true
|
|
||||||
vim.opt.clipboard = "unnamedplus"
|
|
||||||
vim.opt.scrolloff = 999
|
|
||||||
vim.opt.updatetime = 50
|
|
||||||
vim.opt.foldmethod = "indent"
|
|
||||||
vim.opt.foldlevel = 99
|
|
||||||
|
|
||||||
vim.g.mapleader = " "
|
|
||||||
vim.keymap.set("n", "<leader>w", "<cmd>w<CR>", { silent = true })
|
|
||||||
vim.keymap.set("n", "<leader>q", "<cmd>q<CR>", { silent = true })
|
|
||||||
vim.keymap.set("n", "<leader>wq", "<cmd>wq<CR>", { silent = true })
|
|
||||||
vim.keymap.set("n", "<leader>x", "<cmd>!chmod +x %<CR>", { silent = true })
|
|
||||||
vim.keymap.set("n", "Q", "<nop>")
|
|
||||||
vim.keymap.set("n", "o", "o<esc>")
|
|
||||||
vim.keymap.set("n", "O", "O<esc>")
|
|
||||||
vim.keymap.set("i", "jj", "<esc>")
|
|
||||||
|
|
||||||
local is_dark = vim.o.background ~= "light"
|
|
||||||
require("cyberdream").setup({
|
|
||||||
transparent = is_dark,
|
|
||||||
variant = is_dark and "dark" or "light",
|
|
||||||
terminal_colors = true,
|
|
||||||
})
|
|
||||||
vim.cmd.colorscheme("cyberdream")
|
|
||||||
|
|
||||||
require("nvim-tree").setup({
|
|
||||||
view = { width = 30 },
|
|
||||||
renderer = { group_empty = true },
|
|
||||||
filters = { dotfiles = false },
|
|
||||||
})
|
|
||||||
|
|
||||||
require("bufferline").setup({
|
|
||||||
options = {
|
|
||||||
offsets = {
|
|
||||||
{
|
|
||||||
filetype = "NvimTree",
|
|
||||||
text = "Files",
|
|
||||||
highlight = "Directory",
|
|
||||||
separator = true,
|
|
||||||
},
|
|
||||||
},
|
|
||||||
},
|
|
||||||
})
|
|
||||||
|
|
||||||
require("lualine").setup({
|
|
||||||
options = { theme = "auto" },
|
|
||||||
})
|
|
||||||
|
|
||||||
require("neocord").setup({
|
|
||||||
logo = "auto",
|
|
||||||
logo_tooltip = "Neovim",
|
|
||||||
main_image = "language",
|
|
||||||
show_time = true,
|
|
||||||
global_timer = true,
|
|
||||||
})
|
|
||||||
|
|
||||||
require("gitsigns").setup({
|
|
||||||
signs = {
|
|
||||||
add = { text = "+" },
|
|
||||||
change = { text = "~" },
|
|
||||||
delete = { text = "_" },
|
|
||||||
},
|
|
||||||
})
|
|
||||||
|
|
||||||
-- nvim-treesitter no longer exposes a configs module; highlighting is
|
|
||||||
-- started per buffer. Indent is deliberately left alone so treesitter
|
|
||||||
-- doesn't fight the Eclipse-matching tab settings below.
|
|
||||||
vim.api.nvim_create_autocmd("FileType", {
|
|
||||||
pattern = { "java", "xml", "nix", "lua", "rs" },
|
|
||||||
callback = function(args)
|
|
||||||
pcall(vim.treesitter.start, args.buf)
|
|
||||||
end,
|
|
||||||
})
|
|
||||||
|
|
||||||
-- Java indentation must match Eclipse's formatter, not the 2-space default.
|
|
||||||
vim.api.nvim_create_autocmd("FileType", {
|
|
||||||
pattern = "java",
|
|
||||||
callback = function()
|
|
||||||
vim.bo.expandtab = false
|
|
||||||
vim.bo.tabstop = 4
|
|
||||||
vim.bo.shiftwidth = 4
|
|
||||||
vim.bo.softtabstop = 4
|
|
||||||
end,
|
|
||||||
})
|
|
||||||
|
|
||||||
local cmp = require("cmp")
|
|
||||||
local luasnip = require("luasnip")
|
|
||||||
cmp.setup({
|
|
||||||
snippet = { expand = function(a) luasnip.lsp_expand(a.body) end },
|
|
||||||
mapping = cmp.mapping.preset.insert({
|
|
||||||
["<C-Space>"] = cmp.mapping.complete(),
|
|
||||||
["<CR>"] = cmp.mapping.confirm({ select = false }),
|
|
||||||
["<C-n>"] = cmp.mapping.select_next_item(),
|
|
||||||
["<C-p>"] = cmp.mapping.select_prev_item(),
|
|
||||||
}),
|
|
||||||
sources = {
|
|
||||||
{ name = "nvim_lsp" },
|
|
||||||
{ name = "luasnip" },
|
|
||||||
{ name = "buffer" },
|
|
||||||
{ name = "path" },
|
|
||||||
},
|
|
||||||
})
|
|
||||||
|
|
||||||
local capabilities = require("cmp_nvim_lsp").default_capabilities()
|
|
||||||
|
|
||||||
-- rustaceanvim auto-starts rust-analyzer on FileType rust, picking it up
|
|
||||||
-- from PATH -- so per-project rust-analyzer pins (e.g. from a project's
|
|
||||||
-- flake devShell/direnv) are used automatically without extra config here.
|
|
||||||
vim.g.rustaceanvim = {
|
|
||||||
server = {
|
|
||||||
capabilities = capabilities,
|
|
||||||
on_attach = function(_, bufnr)
|
|
||||||
local map = function(k, f) vim.keymap.set("n", k, f, { buffer = bufnr, silent = true }) end
|
|
||||||
map("gd", vim.lsp.buf.definition)
|
|
||||||
map("gr", vim.lsp.buf.references)
|
|
||||||
map("K", vim.lsp.buf.hover)
|
|
||||||
map("<leader>rn", vim.lsp.buf.rename)
|
|
||||||
map("<leader>ca", vim.lsp.buf.code_action)
|
|
||||||
map("<leader>f", function() vim.lsp.buf.format({ async = true }) end)
|
|
||||||
end,
|
|
||||||
},
|
|
||||||
}
|
|
||||||
|
|
||||||
local bundles = vim.fn.glob(
|
|
||||||
"${javaDebug}/share/vscode/extensions/vscjava.vscode-java-debug/server/com.microsoft.java.debug.plugin-*.jar",
|
|
||||||
true, true)
|
|
||||||
if #bundles == 0 then
|
|
||||||
vim.notify("java-debug bundle not found - Java debugging disabled", vim.log.levels.WARN)
|
|
||||||
end
|
|
||||||
|
|
||||||
local java_home = os.getenv("JAVA_HOME")
|
|
||||||
if not java_home then
|
|
||||||
local javac = vim.fn.exepath("javac")
|
|
||||||
if javac ~= "" then
|
|
||||||
java_home = vim.fn.fnamemodify(vim.fn.resolve(javac), ":h:h")
|
|
||||||
end
|
|
||||||
end
|
|
||||||
if not java_home then
|
|
||||||
vim.notify("No JAVA_HOME and no javac on PATH - jdtls will guess a runtime", vim.log.levels.WARN)
|
|
||||||
end
|
|
||||||
if not java_home then
|
|
||||||
vim.notify("JAVA_HOME unset - jdtls will guess a runtime", vim.log.levels.WARN)
|
|
||||||
end
|
|
||||||
|
|
||||||
-- Eclipse metadata wins over build files, build files over .git, and the
|
|
||||||
-- file's own directory is the last resort so bare folders still attach.
|
|
||||||
local function find_project_root()
|
|
||||||
local setup = require("jdtls.setup")
|
|
||||||
return setup.find_root({ ".project", ".classpath" })
|
|
||||||
or setup.find_root({ "pom.xml", "build.gradle", "build.gradle.kts" })
|
|
||||||
or setup.find_root({ ".git" })
|
|
||||||
or vim.fn.expand("%:p:h")
|
|
||||||
end
|
|
||||||
|
|
||||||
local dap_configured = false
|
|
||||||
|
|
||||||
local function start_jdtls()
|
|
||||||
local jdtls = require("jdtls")
|
|
||||||
local root_dir = find_project_root()
|
|
||||||
|
|
||||||
local project_name = vim.fn.fnamemodify(root_dir, ":p:h:t")
|
|
||||||
.. "-" .. vim.fn.sha256(root_dir):sub(1, 8)
|
|
||||||
local workspace = vim.fn.stdpath("cache") .. "/jdtls-workspaces/" .. project_name
|
|
||||||
|
|
||||||
local java_settings = {
|
|
||||||
configuration = {
|
|
||||||
updateBuildConfiguration = "automatic",
|
|
||||||
},
|
|
||||||
-- Keep a stray pom.xml from overriding the Eclipse project model.
|
|
||||||
-- Flip these on if a course actually requires Maven or Gradle.
|
|
||||||
import = {
|
|
||||||
maven = { enabled = false },
|
|
||||||
gradle = { enabled = false },
|
|
||||||
},
|
|
||||||
project = {
|
|
||||||
outputPath = "bin",
|
|
||||||
referencedLibraries = { "lib/**/*.jar" },
|
|
||||||
},
|
|
||||||
signatureHelp = { enabled = true },
|
|
||||||
eclipse = { downloadSources = true },
|
|
||||||
}
|
|
||||||
|
|
||||||
if java_home then
|
|
||||||
java_settings.configuration.runtimes = {
|
|
||||||
{ name = "JavaSE-21", path = java_home, default = true },
|
|
||||||
}
|
|
||||||
end
|
|
||||||
|
|
||||||
-- If the repo carries an exported Eclipse formatter profile, use it verbatim.
|
|
||||||
local formatter = root_dir .. "/.settings/eclipse-formatter.xml"
|
|
||||||
if vim.uv.fs_stat(formatter) then
|
|
||||||
java_settings.format = { settings = { url = formatter } }
|
|
||||||
end
|
|
||||||
|
|
||||||
jdtls.start_or_attach({
|
|
||||||
cmd = { "jdtls", "-data", workspace },
|
|
||||||
root_dir = root_dir,
|
|
||||||
capabilities = capabilities,
|
|
||||||
settings = { java = java_settings },
|
|
||||||
init_options = { bundles = bundles },
|
|
||||||
on_attach = function(_, bufnr)
|
|
||||||
require("jdtls").setup_dap({ hotcodereplace = "auto" })
|
|
||||||
if not dap_configured then
|
|
||||||
dap_configured = true
|
|
||||||
require("jdtls.dap").setup_dap_main_class_configs()
|
|
||||||
end
|
|
||||||
|
|
||||||
local map = function(k, f) vim.keymap.set("n", k, f, { buffer = bufnr, silent = true }) end
|
|
||||||
map("gd", vim.lsp.buf.definition)
|
|
||||||
map("gr", vim.lsp.buf.references)
|
|
||||||
map("K", vim.lsp.buf.hover)
|
|
||||||
map("<leader>rn", vim.lsp.buf.rename)
|
|
||||||
map("<leader>ca", vim.lsp.buf.code_action)
|
|
||||||
map("<leader>f", function() vim.lsp.buf.format({ async = true }) end)
|
|
||||||
map("<leader>oi", require("jdtls").organize_imports)
|
|
||||||
end,
|
|
||||||
})
|
|
||||||
end
|
|
||||||
|
|
||||||
vim.api.nvim_create_autocmd("FileType", {
|
|
||||||
pattern = "java",
|
|
||||||
callback = start_jdtls,
|
|
||||||
})
|
|
||||||
|
|
||||||
local dap, dapui = require("dap"), require("dapui")
|
|
||||||
dapui.setup()
|
|
||||||
require("nvim-dap-virtual-text").setup()
|
|
||||||
|
|
||||||
-- `jtest --debug` suspends the test JVM waiting on :5005; this lets
|
|
||||||
-- <leader>dc attach to it directly from the config picker.
|
|
||||||
dap.configurations.java = dap.configurations.java or {}
|
|
||||||
table.insert(dap.configurations.java, {
|
|
||||||
type = "java",
|
|
||||||
request = "attach",
|
|
||||||
name = "Attach to jtest (:5005)",
|
|
||||||
hostName = "127.0.0.1",
|
|
||||||
port = 5005,
|
|
||||||
})
|
|
||||||
|
|
||||||
dap.listeners.after.event_initialized["dapui"] = function() dapui.open() end
|
|
||||||
dap.listeners.before.event_terminated["dapui"] = function() dapui.close() end
|
|
||||||
dap.listeners.before.event_exited["dapui"] = function() dapui.close() end
|
|
||||||
|
|
||||||
vim.keymap.set("n", "<leader>db", dap.toggle_breakpoint)
|
|
||||||
vim.keymap.set("n", "<leader>dB", function()
|
|
||||||
dap.set_breakpoint(vim.fn.input("Condition: "))
|
|
||||||
end)
|
|
||||||
vim.keymap.set("n", "<leader>dc", dap.continue)
|
|
||||||
vim.keymap.set("n", "<leader>dn", dap.step_over)
|
|
||||||
vim.keymap.set("n", "<leader>di", dap.step_into)
|
|
||||||
vim.keymap.set("n", "<leader>du", dap.step_out)
|
|
||||||
vim.keymap.set("n", "<leader>dr", dap.repl.toggle)
|
|
||||||
vim.keymap.set("n", "<leader>dq", dap.terminate)
|
|
||||||
vim.keymap.set({ "n", "v" }, "<leader>de", function() dapui.eval() end)
|
|
||||||
'';
|
|
||||||
|
|
||||||
plugins = with pkgs.vimPlugins; [
|
|
||||||
{ plugin = cyberdream-nvim; }
|
|
||||||
{ plugin = nvim-web-devicons; }
|
|
||||||
{ plugin = nvim-tree-lua; }
|
|
||||||
{ plugin = bufferline-nvim; }
|
|
||||||
{ plugin = lualine-nvim; }
|
|
||||||
{ plugin = neocord; }
|
|
||||||
{ plugin = gitsigns-nvim; }
|
|
||||||
|
|
||||||
{ plugin = nvim-jdtls; }
|
|
||||||
{ plugin = nvim-dap; }
|
|
||||||
{ plugin = nvim-dap-ui; }
|
|
||||||
{ plugin = nvim-nio; }
|
|
||||||
{ plugin = nvim-dap-virtual-text; }
|
|
||||||
{ plugin = nvim-cmp; }
|
|
||||||
{ plugin = cmp-nvim-lsp; }
|
|
||||||
{ plugin = cmp-buffer; }
|
|
||||||
{ plugin = cmp-path; }
|
|
||||||
{ plugin = luasnip; }
|
|
||||||
{ plugin = cmp_luasnip; }
|
|
||||||
{ plugin = rustaceanvim; }
|
|
||||||
{ plugin = (nvim-treesitter.withPlugins (p: [ p.java p.xml p.nix p.lua p.rust ])); }
|
|
||||||
];
|
|
||||||
};
|
|
||||||
}
|
|
||||||
@@ -9,9 +9,4 @@
|
|||||||
networking.hostName = "lavender";
|
networking.hostName = "lavender";
|
||||||
|
|
||||||
system.stateVersion = "26.05";
|
system.stateVersion = "26.05";
|
||||||
|
|
||||||
hardware.graphics = {
|
|
||||||
enable = true;
|
|
||||||
enable32Bit = true;
|
|
||||||
};
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,81 +0,0 @@
|
|||||||
{ config, pkgs, inputs, ... }:
|
|
||||||
|
|
||||||
let
|
|
||||||
unstable = import inputs.nixpkgs-unstable {
|
|
||||||
system = pkgs.stdenv.hostPlatform.system;
|
|
||||||
config.allowUnfree = true;
|
|
||||||
};
|
|
||||||
in
|
|
||||||
{
|
|
||||||
imports = [
|
|
||||||
./hardware.nix
|
|
||||||
../../system
|
|
||||||
];
|
|
||||||
|
|
||||||
networking.hostName = "lilac";
|
|
||||||
|
|
||||||
services.fwupd.enable = true;
|
|
||||||
services.fprintd.enable = true;
|
|
||||||
services.hardware.bolt.enable = true;
|
|
||||||
|
|
||||||
system.stateVersion = "26.05";
|
|
||||||
|
|
||||||
environment.systemPackages = with pkgs; [
|
|
||||||
framework-tool
|
|
||||||
|
|
||||||
# GPU compute diagnostics
|
|
||||||
clinfo
|
|
||||||
vulkan-tools
|
|
||||||
intel-gpu-tools
|
|
||||||
|
|
||||||
# Vulkan-accelerated llama.cpp CLI/server for manual/advanced use
|
|
||||||
(llama-cpp.override { vulkanSupport = true; })
|
|
||||||
];
|
|
||||||
|
|
||||||
boot.kernelModules = [ "bnep" ];
|
|
||||||
|
|
||||||
networking.interfaces.bnep0.ipv4.addresses = [{
|
|
||||||
address = "10.0.0.1";
|
|
||||||
prefixLength = 24;
|
|
||||||
}];
|
|
||||||
|
|
||||||
networking.firewall.interfaces."bnep0".allowedUDPPorts = [ 4242 ];
|
|
||||||
|
|
||||||
systemd = {
|
|
||||||
services = {
|
|
||||||
# 1. Start the listening server profile
|
|
||||||
bt-pan-server = {
|
|
||||||
description = "Bluetooth PAN GN Server";
|
|
||||||
after = [ "bluetooth.service" ];
|
|
||||||
wantedBy = [ "multi-user.target" ];
|
|
||||||
serviceConfig = {
|
|
||||||
ExecStart = "${pkgs.bluez-tools}/bin/bt-network -s nap bnep";
|
|
||||||
Restart = "always";
|
|
||||||
RestartSec = 5;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
hardware.graphics = {
|
|
||||||
enable = true;
|
|
||||||
enable32Bit = true;
|
|
||||||
extraPackages = with pkgs; [
|
|
||||||
intel-media-driver # Hardware acceleration
|
|
||||||
intel-vaapi-driver
|
|
||||||
vpl-gpu-rt # Video processing runtime
|
|
||||||
intel-compute-runtime # OpenCL + Level Zero GPU compute (Arc iGPU)
|
|
||||||
];
|
|
||||||
extraPackages32 = with pkgs.pkgsi686Linux; [
|
|
||||||
intel-media-driver
|
|
||||||
];
|
|
||||||
};
|
|
||||||
|
|
||||||
services.power-profiles-daemon.enable = true;
|
|
||||||
services.thermald.enable = true;
|
|
||||||
|
|
||||||
services.ollama = {
|
|
||||||
enable = true;
|
|
||||||
package = unstable.ollama-vulkan;
|
|
||||||
};
|
|
||||||
}
|
|
||||||
@@ -1,41 +0,0 @@
|
|||||||
# Do not modify this file! It was generated by ‘nixos-generate-config’
|
|
||||||
# and may be overwritten by future invocations. Please make changes
|
|
||||||
# to /etc/nixos/configuration.nix instead.
|
|
||||||
{ config, lib, pkgs, modulesPath, ... }:
|
|
||||||
|
|
||||||
{
|
|
||||||
imports =
|
|
||||||
[ (modulesPath + "/installer/scan/not-detected.nix")
|
|
||||||
];
|
|
||||||
|
|
||||||
boot.initrd.availableKernelModules = [ "xhci_pci" "thunderbolt" "nvme" "usb_storage" "sd_mod" ];
|
|
||||||
boot.initrd.kernelModules = [ ];
|
|
||||||
boot.kernelModules = [ "kvm-intel" ];
|
|
||||||
boot.extraModulePackages = [ ];
|
|
||||||
|
|
||||||
fileSystems."/" =
|
|
||||||
{ device = "/dev/disk/by-uuid/829d5d81-c2d1-466f-a490-a97ec2a29bc8";
|
|
||||||
fsType = "ext4";
|
|
||||||
};
|
|
||||||
|
|
||||||
fileSystems."/boot" =
|
|
||||||
{ device = "/dev/disk/by-uuid/530C-3D2D";
|
|
||||||
fsType = "vfat";
|
|
||||||
options = [ "fmask=0022" "dmask=0022" ];
|
|
||||||
};
|
|
||||||
|
|
||||||
swapDevices =
|
|
||||||
[ { device = "/dev/disk/by-uuid/3e31b909-ac9d-4329-9ed5-595ea5a9b099"; }
|
|
||||||
];
|
|
||||||
|
|
||||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
|
||||||
|
|
||||||
hardware = {
|
|
||||||
cpu.intel = {
|
|
||||||
npu.enable = true;
|
|
||||||
updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
|
||||||
};
|
|
||||||
|
|
||||||
bluetooth.enable = true;
|
|
||||||
};
|
|
||||||
}
|
|
||||||
@@ -9,64 +9,7 @@
|
|||||||
|
|
||||||
networking.hostName = "violet";
|
networking.hostName = "violet";
|
||||||
|
|
||||||
services.power-profiles-daemon.enable = true;
|
services.power-profiles-daemon.enable = false;
|
||||||
services.hardware.bolt.enable = true;
|
|
||||||
services.logind = {
|
|
||||||
settings = {
|
|
||||||
Login.HandleLidSwitch = "ignore";
|
|
||||||
Login.lidSwitchDocked = "ignore";
|
|
||||||
Login.lidSwitchExternalPower = "ignore";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
services.input-remapper.enable = true;
|
|
||||||
|
|
||||||
system.stateVersion = "26.05";
|
system.stateVersion = "26.05";
|
||||||
|
|
||||||
boot.kernelModules = [ "bnep" ];
|
|
||||||
|
|
||||||
networking.interfaces.bnep0.ipv4.addresses = [{
|
|
||||||
address = "10.0.0.2";
|
|
||||||
prefixLength = 24;
|
|
||||||
}];
|
|
||||||
|
|
||||||
networking.firewall.interfaces."bnep0".allowedUDPPorts = [ 4242 ];
|
|
||||||
|
|
||||||
systemd = {
|
|
||||||
services = {
|
|
||||||
bt-pan-client = {
|
|
||||||
description = "Bluetooth PAN Client Connection to Device A";
|
|
||||||
after = [ "bluetooth.service" ];
|
|
||||||
wantedBy = [ "multi-user.target" ];
|
|
||||||
serviceConfig = {
|
|
||||||
# Replace XX:XX:XX:XX:XX:XX with Device B's actual Bluetooth MAC Address
|
|
||||||
ExecStartPre = "${pkgs.bluez}/bin/bluetoothctl trust 84:D1:C1:A9:EE:52";
|
|
||||||
ExecStart = "${pkgs.bluez-tools}/bin/bt-network -c 84:D1:C1:A9:EE:52 bnep";
|
|
||||||
Restart = "always";
|
|
||||||
RestartSec = 10; # Retry every 10 seconds if Device B goes out of range
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
services.tlp = {
|
|
||||||
enable = false;
|
|
||||||
settings = {
|
|
||||||
USB_AUTOSUSPEND = 0;
|
|
||||||
|
|
||||||
# AC
|
|
||||||
CPU_SCALING_GOVERNOR_ON_AC = "performance";
|
|
||||||
CPU_ENERGY_PERF_POLICY_ON_AC = "performance";
|
|
||||||
SOUND_POWER_SAVE_ON_AC = 0;
|
|
||||||
PCIE_ASPM_ON_AC = "default";
|
|
||||||
CPU_BOOST_ON_BAT = 0;
|
|
||||||
|
|
||||||
# Battery
|
|
||||||
CPU_SCALING_GOVERNOR_ON_BAT = "powersave";
|
|
||||||
CPU_ENERGY_PERF_POLICY_ON_BAT = "power";
|
|
||||||
SOUND_POWER_SAVE_ON_BAT = 1;
|
|
||||||
PCIE_ASPM_ON_BAT = "powersupersave";
|
|
||||||
CPU_BOOST_ON_AC = 1;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -39,7 +39,7 @@
|
|||||||
'';
|
'';
|
||||||
|
|
||||||
services.howdy = {
|
services.howdy = {
|
||||||
enable = false;
|
enable = true;
|
||||||
control = "sufficient";
|
control = "sufficient";
|
||||||
settings = {
|
settings = {
|
||||||
video = {
|
video = {
|
||||||
@@ -60,6 +60,19 @@
|
|||||||
sensor.iio.enable = true;
|
sensor.iio.enable = true;
|
||||||
graphics.enable = true;
|
graphics.enable = true;
|
||||||
|
|
||||||
bluetooth.enable = true;
|
bluetooth = {
|
||||||
|
enable = true;
|
||||||
|
powerOnBoot = true;
|
||||||
|
|
||||||
|
settings = {
|
||||||
|
General = {
|
||||||
|
Experimental = true;
|
||||||
|
KernelExperimental = true;
|
||||||
|
|
||||||
|
ControllerMode = "dual";
|
||||||
|
Enable = "Source,Sink,Media,Socket";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
|
Before Width: | Height: | Size: 664 KiB After Width: | Height: | Size: 664 KiB |
|
Before Width: | Height: | Size: 1.9 MiB After Width: | Height: | Size: 1.9 MiB |
|
After Width: | Height: | Size: 87 KiB |
|
Before Width: | Height: | Size: 394 KiB After Width: | Height: | Size: 394 KiB |
|
Before Width: | Height: | Size: 113 KiB After Width: | Height: | Size: 113 KiB |
|
Before Width: | Height: | Size: 2.1 MiB After Width: | Height: | Size: 2.1 MiB |
|
Before Width: | Height: | Size: 850 KiB After Width: | Height: | Size: 850 KiB |
|
Before Width: | Height: | Size: 6.2 MiB After Width: | Height: | Size: 6.2 MiB |
|
Before Width: | Height: | Size: 1.1 MiB After Width: | Height: | Size: 1.1 MiB |
|
Before Width: | Height: | Size: 924 KiB After Width: | Height: | Size: 924 KiB |
|
Before Width: | Height: | Size: 1.0 MiB After Width: | Height: | Size: 1.0 MiB |
|
Before Width: | Height: | Size: 2.4 MiB After Width: | Height: | Size: 2.4 MiB |
|
Before Width: | Height: | Size: 1.3 MiB After Width: | Height: | Size: 1.3 MiB |
|
Before Width: | Height: | Size: 2.1 MiB After Width: | Height: | Size: 2.1 MiB |
|
Before Width: | Height: | Size: 1.1 MiB After Width: | Height: | Size: 1.1 MiB |
|
Before Width: | Height: | Size: 1.6 MiB After Width: | Height: | Size: 1.6 MiB |
|
Before Width: | Height: | Size: 1.4 MiB After Width: | Height: | Size: 1.4 MiB |
|
Before Width: | Height: | Size: 662 KiB After Width: | Height: | Size: 662 KiB |
|
Before Width: | Height: | Size: 1.5 MiB After Width: | Height: | Size: 1.5 MiB |
|
Before Width: | Height: | Size: 229 KiB After Width: | Height: | Size: 229 KiB |
|
Before Width: | Height: | Size: 7.6 MiB After Width: | Height: | Size: 7.6 MiB |
|
Before Width: | Height: | Size: 731 KiB After Width: | Height: | Size: 731 KiB |
|
Before Width: | Height: | Size: 1.9 MiB After Width: | Height: | Size: 1.9 MiB |
|
Before Width: | Height: | Size: 10 MiB After Width: | Height: | Size: 10 MiB |
|
Before Width: | Height: | Size: 12 MiB After Width: | Height: | Size: 12 MiB |
|
Before Width: | Height: | Size: 4.9 MiB After Width: | Height: | Size: 4.9 MiB |
|
Before Width: | Height: | Size: 1.3 MiB After Width: | Height: | Size: 1.3 MiB |
|
Before Width: | Height: | Size: 1.0 MiB After Width: | Height: | Size: 1.0 MiB |
|
Before Width: | Height: | Size: 1.5 MiB After Width: | Height: | Size: 1.5 MiB |
@@ -0,0 +1,142 @@
|
|||||||
|
{ config, lib, pkgs, inputs, ... }:
|
||||||
|
|
||||||
|
let
|
||||||
|
launch-lisgd = pkgs.writeShellScriptBin "launch-lisgd" ''
|
||||||
|
# Search for the capacitive touch layer and extract its event number.
|
||||||
|
# UPDATE 'Touchscreen' below to match the unique word you found in step 1.
|
||||||
|
TOUCH_EVENT=$(grep -i -E 'name=".*Finger.*"' -A 5 /proc/bus/input/devices | grep -o 'event[0-9]\+' | head -n 1)
|
||||||
|
|
||||||
|
if [ -n "$TOUCH_EVENT" ]; then
|
||||||
|
# Start lisgd locked exclusively to the finger digitizer
|
||||||
|
${pkgs.lisgd}/bin/lisgd -t 30 -m 150 -r 45 -d "/dev/input/$TOUCH_EVENT" \
|
||||||
|
-g "3,LR,*,*,P,niri msg action focus-column-left && sleep 0.4" \
|
||||||
|
-g "3,RL,*,*,P,niri msg action focus-column-right && sleep 0.4" \
|
||||||
|
-g "3,UD,*,*,P,niri msg action focus-workspace-up && sleep 0.4" \
|
||||||
|
-g "3,DU,*,*,P,niri msg action focus-workspace-down && sleep 0.4" \
|
||||||
|
-g "4,DU,*,*,P,dms ipc spotlight toggle && sleep 0.4" \
|
||||||
|
-g "1,DU,B,*,pkill -u jashton -RTMIN wvkbd-mobintl && sleep 0.4"
|
||||||
|
fi
|
||||||
|
'';
|
||||||
|
|
||||||
|
launch-wvkbd = pkgs.writeShellScriptBin "launch-wvkbd" ''
|
||||||
|
THEME_CACHE="$HOME/.cache/DankMaterialShell/dms-colors.json"
|
||||||
|
|
||||||
|
if [ -f "$THEME_CACHE" ]; then
|
||||||
|
BG=$(jq -r '.["colors"]["dark"]["background"]' "$THEME_CACHE" | tr -d '#')
|
||||||
|
FG=$(jq -r '.["colors"]["dark"]["surface_container_lowest"]' "$THEME_CACHE" | tr -d '#')
|
||||||
|
TXT=$(jq -r '.["colors"]["dark"]["on_background"]' "$THEME_CACHE" | tr -d '#')
|
||||||
|
PRIMARY=$(jq -r '.["colors"]["dark"]["surface_container_lowest"]' "$THEME_CACHE" | tr -d '#')
|
||||||
|
ON_PRIMARY=$(jq -r '.["colors"]["dark"]["on_background"]' "$THEME_CACHE" | tr -d '#')
|
||||||
|
|
||||||
|
wvkbd-mobintl --hidden --no-popup --bg "$BG" --press "$BG" --fg "$FG" --text "$TXT" --fg-sp "$PRIMARY" --text-sp "$ON_PRIMARY" -L 300
|
||||||
|
else
|
||||||
|
wvkbd-mobintl --hidden --no-popup
|
||||||
|
fi
|
||||||
|
'';
|
||||||
|
in
|
||||||
|
|
||||||
|
{
|
||||||
|
|
||||||
|
xdg.portal = {
|
||||||
|
enable = true;
|
||||||
|
# Use gtk or kde based on your preferred file picker dialog
|
||||||
|
config.niri = {
|
||||||
|
"org.freedesktop.impl.portal.FileChooser" = [ "gtk" ]; # or "kde"
|
||||||
|
};
|
||||||
|
|
||||||
|
# Ensure the GTK portal is installed
|
||||||
|
extraPortals = [ pkgs.xdg-desktop-portal-gtk ];
|
||||||
|
};
|
||||||
|
|
||||||
|
programs.niri = {
|
||||||
|
settings = {
|
||||||
|
# Autostart DMS if you prefer launching it directly from Niri instead of systemd
|
||||||
|
spawn-at-startup = [
|
||||||
|
{ command = [ "dms" "run" ]; }
|
||||||
|
{ command = [ "${launch-wvkbd}/bin/launch-wvkbd" ]; }
|
||||||
|
{ command = [ "${launch-lisgd}/bin/launch-lisgd" ]; } # Spawns the daemon
|
||||||
|
];
|
||||||
|
|
||||||
|
hotkey-overlay = {
|
||||||
|
skip-at-startup = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
input = {
|
||||||
|
keyboard.xkb.layout = "us";
|
||||||
|
touchpad = {
|
||||||
|
tap = true;
|
||||||
|
natural-scroll = true;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
layout = {
|
||||||
|
gaps = 8;
|
||||||
|
center-focused-column = "never";
|
||||||
|
default-column-width.proportion = 1.0;
|
||||||
|
border.enable = false;
|
||||||
|
#tab-indicator.corner-radius = 18.0;
|
||||||
|
focus-ring = {
|
||||||
|
|
||||||
|
enable = false;
|
||||||
|
width = 2;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
prefer-no-csd = true;
|
||||||
|
window-rules = [
|
||||||
|
{ # All windows
|
||||||
|
geometry-corner-radius = {
|
||||||
|
bottom-left = 25.0;
|
||||||
|
bottom-right = 25.0;
|
||||||
|
top-right = 25.0;
|
||||||
|
top-left = 25.0;
|
||||||
|
};
|
||||||
|
|
||||||
|
draw-border-with-background = true;
|
||||||
|
clip-to-geometry = true;
|
||||||
|
}
|
||||||
|
];
|
||||||
|
|
||||||
|
# Vim Keybindings & Built-in Features
|
||||||
|
binds = with config.lib.niri.actions; {
|
||||||
|
# Launchers & Session Control
|
||||||
|
"Mod+Return".action.spawn = [ "alacritty" ];
|
||||||
|
"Mod+P".action.spawn = [ "pkill" "-RTMIN" "wvkbd-mobintl" ];
|
||||||
|
"Mod+Space".action.spawn = [ "dms" "ipc" "spotlight" "toggle" ];
|
||||||
|
"Mod+X".action.close-window = [];
|
||||||
|
"Mod+F".action.fullscreen-window = [];
|
||||||
|
"Mod+Shift+E".action.quit = [];
|
||||||
|
"Mod+Shift+P".action.toggle-overview = [];
|
||||||
|
|
||||||
|
# Vim Focus Movement
|
||||||
|
"Mod+H".action.focus-column-left = [];
|
||||||
|
"Mod+J".action.focus-window-down = [];
|
||||||
|
"Mod+K".action.focus-window-up = [];
|
||||||
|
"Mod+L".action.focus-column-right = [];
|
||||||
|
|
||||||
|
# Workspace Navigation
|
||||||
|
"Mod+N".action.focus-workspace-down = [];
|
||||||
|
"Mod+U".action.focus-workspace-up = [];
|
||||||
|
|
||||||
|
# Vim Window Reordering
|
||||||
|
"Mod+Shift+H".action.move-column-left = [];
|
||||||
|
"Mod+Shift+L".action.move-column-right = [];
|
||||||
|
"Mod+Shift+J".action.move-column-to-workspace-down = [];
|
||||||
|
"Mod+Shift+K".action.move-column-to-workspace-up = [];
|
||||||
|
|
||||||
|
# Volume & Brightness Media Controls
|
||||||
|
"XF86AudioRaiseVolume".action.spawn = [ "wpctl" "set-volume" "@DEFAULT_AUDIO_SINK@" "0.05+" ];
|
||||||
|
"XF86AudioLowerVolume".action.spawn = [ "wpctl" "set-volume" "@DEFAULT_AUDIO_SINK@" "0.05-" ];
|
||||||
|
"XF86AudioMute".action.spawn = [ "wpctl" "set-mute" "@DEFAULT_AUDIO_SINK@" "toggle" ];
|
||||||
|
"XF86MonBrightnessUp".action.spawn = [ "dms" "ipc" "call" "brightness" "increment" "5" "" ];
|
||||||
|
"XF86MonBrightnessDown".action.spawn = [ "dms" "ipc" "call" "brightness" "decrement" "5" "" ];
|
||||||
|
|
||||||
|
# Screenshots
|
||||||
|
"Print".action.screenshot = [];
|
||||||
|
"Ctrl+Print".action.screenshot-screen = [];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -0,0 +1,128 @@
|
|||||||
|
{ config, lib, pkgs, inputs, ... }:
|
||||||
|
|
||||||
|
let
|
||||||
|
# Compile your custom wvkbd build
|
||||||
|
custom_wvkbd = pkgs.wvkbd.overrideAttrs (oldAttrs: {
|
||||||
|
# Pin the package version to the exact commit from your flake input
|
||||||
|
src = inputs.wvkbd-src;
|
||||||
|
version = "custom-git";
|
||||||
|
|
||||||
|
# Choose your preferred layout layout (e.g., mobintl, standard, cyrillic)
|
||||||
|
makeFlags = (oldAttrs.makeFlags or []) ++ [ "LAYOUT=mobintl" ];
|
||||||
|
|
||||||
|
# Optional: Swap out the layout with your own config.h file if you have one
|
||||||
|
preBuild = ''
|
||||||
|
cp ${./programs/layout.custom.h} layout.mobintl.h
|
||||||
|
cp ${./programs/config.custom.h} config.mobintl.h
|
||||||
|
cp ${./programs/keymap.custom.h} keymap.mobintl.h
|
||||||
|
'';
|
||||||
|
});
|
||||||
|
in
|
||||||
|
{
|
||||||
|
imports = [
|
||||||
|
./programs
|
||||||
|
./desktop
|
||||||
|
];
|
||||||
|
|
||||||
|
home.username = "jashton";
|
||||||
|
home.homeDirectory = "/home/jashton";
|
||||||
|
home.file.".zshrc".text = ''
|
||||||
|
# Zsh is configured globally at the NixOS system level.
|
||||||
|
# This file exists solely to prevent the zsh-newuser-install prompt.
|
||||||
|
'';
|
||||||
|
|
||||||
|
home.sessionVariables = {
|
||||||
|
EDITOR = "nvim";
|
||||||
|
NIXOS_OZONE_WL = "1"; # Forces Electron/Chromium apps to use Wayland natively
|
||||||
|
GTK_IM_MODULE = "wayland"; # Forces GTK apps to use Wayland text-input protocols
|
||||||
|
QT_IM_MODULE = "wayland"; # Forces Qt apps to use Wayland text-input protocols
|
||||||
|
TEXT_INPUT_PRESENT = "1"; # Explicitly signals virtual keyboard capability to the shell
|
||||||
|
};
|
||||||
|
|
||||||
|
home.packages = with pkgs; [
|
||||||
|
antigravity
|
||||||
|
asciinema
|
||||||
|
discord
|
||||||
|
ffmpeg
|
||||||
|
gemini-cli
|
||||||
|
libreoffice
|
||||||
|
mc
|
||||||
|
opencode
|
||||||
|
pdftk
|
||||||
|
scrot
|
||||||
|
spotify
|
||||||
|
vlc
|
||||||
|
wtype
|
||||||
|
xwayland-satellite
|
||||||
|
yt-dlp
|
||||||
|
zathura
|
||||||
|
|
||||||
|
custom_wvkbd
|
||||||
|
|
||||||
|
(pkgs.writeShellScriptBin "find-open-port" ''
|
||||||
|
if [ -z "$1" ]; then
|
||||||
|
echo "Please provide an application name, project directory, or other identifier."
|
||||||
|
echo " Usage: find-open-port $HOME/dev/some-project"
|
||||||
|
echo " Usage: find-open-port some-app"
|
||||||
|
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
APP_NAME=$1
|
||||||
|
REGISTRY_FILE=$HOME/.dotfiles/ports.registry
|
||||||
|
|
||||||
|
MIN_PORT=8000
|
||||||
|
MAX_PORT=8999
|
||||||
|
MAX_RETRIES=50
|
||||||
|
|
||||||
|
echo "Searching for available port between $MIN_PORT and $MAX_PORT for $APP_NAME..."
|
||||||
|
|
||||||
|
for ((i=1; i<=MAX_RETRIES; i++)); do
|
||||||
|
RANDOM_PORT=$(shuf -i $MIN_PORT-$MAX_PORT -n 1)
|
||||||
|
|
||||||
|
if ! ss -tuln | grep -E -q ":$RANDOM_PORT\b"; then
|
||||||
|
if [ -f "$REGISTRY_FILE" ] && grep -q "\b$RANDOM_PORT\b" "$REGISTRY_FILE"; then
|
||||||
|
continue
|
||||||
|
fi
|
||||||
|
|
||||||
|
echo "$APP_NAME : $RANDOM_PORT" >> "$REGISTRY_FILE"
|
||||||
|
echo -e "\nSuccessfully wrote '$APP_NAME : $RANDOM_PORT' to $REGISTRY_FILE"
|
||||||
|
exit 0
|
||||||
|
fi
|
||||||
|
done
|
||||||
|
|
||||||
|
echo -e "\nError: Could not find an open port between $MIN_PORT and $MAX_PORT after $MAX_RETRIES attempts."
|
||||||
|
exit 1
|
||||||
|
'')
|
||||||
|
];
|
||||||
|
|
||||||
|
home.activation = {
|
||||||
|
# 1. Create the persistent directories
|
||||||
|
createWorkspaceDirs = lib.hm.dag.entryAfter ["writeBoundary"] ''
|
||||||
|
$DRY_RUN_CMD mkdir -p $HOME/dev
|
||||||
|
$DRY_RUN_CMD mkdir -p $HOME/downloads
|
||||||
|
$DRY_RUN_CMD mkdir -p $HOME/life
|
||||||
|
$DRY_RUN_CMD mkdir -p $HOME/media/pics
|
||||||
|
$DRY_RUN_CMD mkdir -p $HOME/media/videos
|
||||||
|
$DRY_RUN_CMD mkdir -p $HOME/school
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
|
||||||
|
programs.ssh = {
|
||||||
|
enable = true;
|
||||||
|
matchBlocks = {
|
||||||
|
"heliotrope" = {
|
||||||
|
hostname = "100.77.235.110";
|
||||||
|
};
|
||||||
|
"lavender" = {
|
||||||
|
hostname = "100.99.189.49";
|
||||||
|
};
|
||||||
|
"violet" = {
|
||||||
|
hostname = "100.101.100.84";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
home.stateVersion = "26.05"; # DO NOT CHANGE
|
||||||
|
}
|
||||||
|
|
||||||
@@ -20,10 +20,8 @@
|
|||||||
};
|
};
|
||||||
|
|
||||||
colors = {
|
colors = {
|
||||||
draw_bold_text_with_bright_colors = true;
|
|
||||||
|
|
||||||
primary = {
|
primary = {
|
||||||
background = "#080808"; # Carbon Black
|
background = "#08090b"; # Black
|
||||||
foreground = "#8d739c"; # Vintage Lavender 1
|
foreground = "#8d739c"; # Vintage Lavender 1
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -1173,7 +1173,7 @@ static struct key keys_landscape_special[] = {
|
|||||||
{";", ":", 1.0, Code, KEY_SEMICOLON, .scheme = 1},
|
{";", ":", 1.0, Code, KEY_SEMICOLON, .scheme = 1},
|
||||||
{"'", "\"", 1.0, Code, KEY_APOSTROPHE, .scheme = 1},
|
{"'", "\"", 1.0, Code, KEY_APOSTROPHE, .scheme = 1},
|
||||||
{",", "<", 1.0, Code, KEY_COMMA, .scheme = 1},
|
{",", "<", 1.0, Code, KEY_COMMA, .scheme = 1},
|
||||||
{".", ">", 1.0, Code, KEY_DOT, .scheme = 1},
|
{".", ">", 1.0, Code, KEY_SLASH, .scheme = 1},
|
||||||
{"/", "?", 1.0, Code, KEY_SLASH, .scheme = 1},
|
{"/", "?", 1.0, Code, KEY_SLASH, .scheme = 1},
|
||||||
|
|
||||||
{"", "", 0.0, EndRow},
|
{"", "", 0.0, EndRow},
|
||||||
@@ -0,0 +1,100 @@
|
|||||||
|
{ config, pkgs, ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
programs.neovim = {
|
||||||
|
enable = true;
|
||||||
|
viAlias = true;
|
||||||
|
vimAlias = true;
|
||||||
|
defaultEditor = true;
|
||||||
|
|
||||||
|
initLua = ''
|
||||||
|
vim.opt.number = true
|
||||||
|
vim.opt.relativenumber = true
|
||||||
|
vim.opt.tabstop = 2
|
||||||
|
vim.opt.softtabstop = 2
|
||||||
|
vim.opt.expandtab = true
|
||||||
|
vim.opt.shiftwidth = 2
|
||||||
|
vim.opt.smartindent = true
|
||||||
|
vim.opt.wrap = false
|
||||||
|
vim.opt.swapfile = false
|
||||||
|
vim.opt.backup = false
|
||||||
|
vim.opt.undofile = false
|
||||||
|
vim.opt.hlsearch = false
|
||||||
|
vim.opt.incsearch = true
|
||||||
|
vim.opt.termguicolors = true
|
||||||
|
vim.opt.clipboard = "unnamedplus"
|
||||||
|
vim.opt.scrolloff = 999
|
||||||
|
vim.opt.updatetime = 50
|
||||||
|
vim.opt.foldmethod = "indent"
|
||||||
|
vim.opt.foldlevel = 99
|
||||||
|
|
||||||
|
vim.g.mapleader = " "
|
||||||
|
vim.keymap.set("n", "<leader>", ":")
|
||||||
|
vim.keymap.set("n", "<leader>w", "<cmd>w<CR>", { silent = true })
|
||||||
|
vim.keymap.set("n", "<leader>q", "<cmd>q<CR>", { silent = true })
|
||||||
|
vim.keymap.set("n", "<leader>wq", "<cmd>wq<CR>", { silent = true })
|
||||||
|
vim.keymap.set("n", "<leader>x", "<cmd>!chmod +x %<CR>", { silent = true })
|
||||||
|
vim.keymap.set("n", "Q", "<nop>")
|
||||||
|
vim.keymap.set("n", "o", "o<esc>")
|
||||||
|
vim.keymap.set("n", "O", "O<esc>")
|
||||||
|
vim.keymap.set("i", "jj", "<esc>")
|
||||||
|
|
||||||
|
local is_dark = vim.o.background ~= "light"
|
||||||
|
require("cyberdream").setup({
|
||||||
|
transparent = is_dark,
|
||||||
|
variant = is_dark and "dark" or "light",
|
||||||
|
terminal_colors = true,
|
||||||
|
})
|
||||||
|
vim.cmd.colorscheme("cyberdream")
|
||||||
|
|
||||||
|
require("nvim-tree").setup({
|
||||||
|
view = { width = 30 },
|
||||||
|
renderer = { group_empty = true },
|
||||||
|
filters = { dotfiles = false },
|
||||||
|
})
|
||||||
|
|
||||||
|
require("bufferline").setup({
|
||||||
|
options = {
|
||||||
|
offsets = {
|
||||||
|
{
|
||||||
|
filetype = "NvimTree",
|
||||||
|
text = "Files",
|
||||||
|
highlight = "Directory",
|
||||||
|
separator = true,
|
||||||
|
},
|
||||||
|
},
|
||||||
|
},
|
||||||
|
})
|
||||||
|
|
||||||
|
require("lualine").setup({
|
||||||
|
ons = { theme = "auto" },
|
||||||
|
})
|
||||||
|
|
||||||
|
require("neocord").setup({
|
||||||
|
logo = "auto",
|
||||||
|
logo_tooltip = "Neovim",
|
||||||
|
main_image = "language",
|
||||||
|
show_time = true,
|
||||||
|
global_timer = true,
|
||||||
|
})
|
||||||
|
|
||||||
|
require("gitsigns").setup({
|
||||||
|
signs = {
|
||||||
|
add = { text = "+" },
|
||||||
|
change = { text = "~" },
|
||||||
|
delete = { text = "_" },
|
||||||
|
},
|
||||||
|
})
|
||||||
|
'';
|
||||||
|
|
||||||
|
plugins = with pkgs.vimPlugins; [
|
||||||
|
{ plugin = cyberdream-nvim; }
|
||||||
|
{ plugin = nvim-web-devicons; }
|
||||||
|
{ plugin = nvim-tree-lua; }
|
||||||
|
{ plugin = bufferline-nvim; }
|
||||||
|
{ plugin = lualine-nvim; }
|
||||||
|
{ plugin = neocord; }
|
||||||
|
{ plugin = gitsigns-nvim; }
|
||||||
|
];
|
||||||
|
};
|
||||||
|
}
|
||||||
@@ -5,6 +5,6 @@
|
|||||||
boot.loader.efi.canTouchEfiVariables = true;
|
boot.loader.efi.canTouchEfiVariables = true;
|
||||||
boot.kernelPackages = pkgs.linuxPackages_latest;
|
boot.kernelPackages = pkgs.linuxPackages_latest;
|
||||||
boot.kernelModules = [ "uinput" ];
|
boot.kernelModules = [ "uinput" ];
|
||||||
system.nixos.label = "niri-v.1.3";
|
system.nixos.label = "niri-v.1.2";
|
||||||
environment.pathsToLink = [ "/libexec" "/share/xdg-desktop-portal" "/share/xdg-desktop-portal/portals" ];
|
environment.pathsToLink = [ "/libexec" ];
|
||||||
}
|
}
|
||||||
@@ -8,6 +8,4 @@
|
|||||||
./locale.nix
|
./locale.nix
|
||||||
./power.nix
|
./power.nix
|
||||||
];
|
];
|
||||||
|
|
||||||
hardware.flipperzero.enable = true;
|
|
||||||
}
|
}
|
||||||
@@ -43,12 +43,6 @@
|
|||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
shellInit = ''
|
|
||||||
if [ -f "/etc/profiles/per-user/$USER/etc/profile.d/hm-session-vars.sh" ]; then
|
|
||||||
. "/etc/profiles/per-user/$USER/etc/profile.d/hm-session-vars.sh"
|
|
||||||
fi
|
|
||||||
'';
|
|
||||||
|
|
||||||
interactiveShellInit = ''
|
interactiveShellInit = ''
|
||||||
if [ -f "/run/secrets/vaultwarden_clientid" ]; then
|
if [ -f "/run/secrets/vaultwarden_clientid" ]; then
|
||||||
export BW_CLIENTID=$(cat /run/secrets/vaultwarden_clientid)
|
export BW_CLIENTID=$(cat /run/secrets/vaultwarden_clientid)
|
||||||
@@ -0,0 +1,32 @@
|
|||||||
|
{ config, pkgs, ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
boot.kernelParams = [ "mem_sleep_default=deep" ];
|
||||||
|
|
||||||
|
services.power-profiles-daemon.enable = false;
|
||||||
|
|
||||||
|
services.tlp = {
|
||||||
|
enable = true;
|
||||||
|
settings = {
|
||||||
|
USB_AUTOSUSPEND = 0;
|
||||||
|
|
||||||
|
# AC
|
||||||
|
CPU_SCALING_GOVERNOR_ON_AC = "performance";
|
||||||
|
CPU_ENERGY_PERF_POLICY_ON_AC = "performance";
|
||||||
|
SOUND_POWER_SAVE_ON_AC = 0;
|
||||||
|
PCIE_ASPM_ON_AC = "default";
|
||||||
|
CPU_BOOST_ON_BAT = 0;
|
||||||
|
|
||||||
|
# Battery
|
||||||
|
CPU_SCALING_GOVERNOR_ON_BAT = "powersave";
|
||||||
|
CPU_ENERGY_PERF_POLICY_ON_BAT = "power";
|
||||||
|
SOUND_POWER_SAVE_ON_BAT = 1;
|
||||||
|
PCIE_ASPM_ON_BAT = "powersupersave";
|
||||||
|
CPU_BOOST_ON_AC = 1;
|
||||||
|
|
||||||
|
# Battery Thresholds
|
||||||
|
START_CHARGE_THRESH_BAT0 = 40;
|
||||||
|
STOP_CHARGE_THRESH_BAT0 = 80;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
@@ -0,0 +1,18 @@
|
|||||||
|
{ config, pkgs, ... }:
|
||||||
|
|
||||||
|
{
|
||||||
|
|
||||||
|
imports = [
|
||||||
|
./pi-hole.nix
|
||||||
|
];
|
||||||
|
|
||||||
|
networking = {
|
||||||
|
networkmanager.enable = true;
|
||||||
|
|
||||||
|
firewall = {
|
||||||
|
enable = true;
|
||||||
|
allowedTCPPorts = [];
|
||||||
|
allowedUDPPorts = [];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
@@ -1,11 +1,5 @@
|
|||||||
{ config, pkgs, inputs, ... }:
|
{ config, pkgs, ... }:
|
||||||
|
|
||||||
let
|
|
||||||
unstable = import inputs.nixpkgs-unstable {
|
|
||||||
system = pkgs.stdenv.hostPlatform.system;
|
|
||||||
config.allowUnfree = true;
|
|
||||||
};
|
|
||||||
in
|
|
||||||
{
|
{
|
||||||
nixpkgs.config.allowUnfree = true;
|
nixpkgs.config.allowUnfree = true;
|
||||||
|
|
||||||
@@ -13,51 +7,31 @@ in
|
|||||||
acpi
|
acpi
|
||||||
age
|
age
|
||||||
alacritty
|
alacritty
|
||||||
bluez
|
|
||||||
bluez-tools
|
|
||||||
bitwarden-cli
|
bitwarden-cli
|
||||||
btop
|
btop
|
||||||
dbus
|
|
||||||
dconf
|
dconf
|
||||||
deskflow
|
|
||||||
direnv
|
|
||||||
fastfetch
|
fastfetch
|
||||||
firefox
|
firefox
|
||||||
gemini-cli
|
|
||||||
gimp
|
|
||||||
git
|
git
|
||||||
github-cli
|
github-cli
|
||||||
gnome-calculator
|
|
||||||
(google-chrome.override {
|
(google-chrome.override {
|
||||||
commandLineArgs = [
|
commandLineArgs = [
|
||||||
"--disable-pinch"
|
"--disable-pinch"
|
||||||
];
|
];
|
||||||
})
|
})
|
||||||
google-chrome
|
google-chrome
|
||||||
google-java-format
|
|
||||||
gnupg
|
gnupg
|
||||||
jdk
|
|
||||||
jdt-language-server
|
|
||||||
jq
|
jq
|
||||||
keepassxc
|
keepassxc
|
||||||
lan-mouse
|
|
||||||
libnotify
|
libnotify
|
||||||
macchanger
|
|
||||||
makeDBusConf
|
|
||||||
mypy
|
mypy
|
||||||
nautilus
|
|
||||||
networkmanagerapplet
|
networkmanagerapplet
|
||||||
nitrogen
|
nitrogen
|
||||||
nix-direnv
|
ollama
|
||||||
unstable.ollama
|
|
||||||
pasystray
|
pasystray
|
||||||
pkg-config
|
|
||||||
playerctl
|
|
||||||
pulseaudioFull
|
pulseaudioFull
|
||||||
python3
|
|
||||||
rclone
|
rclone
|
||||||
rnote
|
rnote
|
||||||
rustdesk
|
|
||||||
sops
|
sops
|
||||||
ssh-to-age
|
ssh-to-age
|
||||||
tldr
|
tldr
|
||||||
@@ -65,14 +39,12 @@ in
|
|||||||
unrar
|
unrar
|
||||||
unzip
|
unzip
|
||||||
upower
|
upower
|
||||||
usbutils
|
|
||||||
v4l-utils
|
v4l-utils
|
||||||
vim
|
vim
|
||||||
wget
|
wget
|
||||||
wl-clipboard
|
wl-clipboard
|
||||||
xclip
|
xclip
|
||||||
xournalpp
|
xournalpp
|
||||||
zip
|
|
||||||
|
|
||||||
(pkgs.writeShellScriptBin "unix" ''
|
(pkgs.writeShellScriptBin "unix" ''
|
||||||
set -u
|
set -u
|
||||||
@@ -83,7 +55,6 @@ in
|
|||||||
trap "rm -f '$ERRFILE'" EXIT
|
trap "rm -f '$ERRFILE'" EXIT
|
||||||
|
|
||||||
echo "Building NixOS..."
|
echo "Building NixOS..."
|
||||||
cd $DOTFILES && git stage -A
|
|
||||||
sudo nixos-rebuild switch --flake "$DOTFILES#$HOST" 2>&1 | tee "$ERRFILE"
|
sudo nixos-rebuild switch --flake "$DOTFILES#$HOST" 2>&1 | tee "$ERRFILE"
|
||||||
STATUS=''${PIPESTATUS[0]}
|
STATUS=''${PIPESTATUS[0]}
|
||||||
|
|
||||||
@@ -116,14 +87,18 @@ in
|
|||||||
'')
|
'')
|
||||||
];
|
];
|
||||||
|
|
||||||
programs.direnv.enable = true;
|
programs.firefox.enable = true;
|
||||||
programs.direnv.nix-direnv.enable = true;
|
programs.thunar.enable = true;
|
||||||
|
|
||||||
|
hardware.graphics = {
|
||||||
|
enable = true;
|
||||||
|
enable32Bit = true;
|
||||||
|
};
|
||||||
|
|
||||||
programs.steam = {
|
programs.steam = {
|
||||||
enable = true;
|
enable = true;
|
||||||
remotePlay.openFirewall = true;
|
remotePlay.openFirewall = true;
|
||||||
dedicatedServer.openFirewall = true;
|
dedicatedServer.openFirewall = true;
|
||||||
localNetworkGameTransfers.openFirewall = true;
|
localNetworkGameTransfers.openFirewall = true;
|
||||||
gamescopeSession.enable = true;
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
@@ -8,6 +8,8 @@
|
|||||||
./users.nix
|
./users.nix
|
||||||
];
|
];
|
||||||
|
|
||||||
|
systemd.user.services.niri-flake-polkit.enable = false;
|
||||||
|
|
||||||
security = {
|
security = {
|
||||||
pam.services.swaylock = {};
|
pam.services.swaylock = {};
|
||||||
polkit.enable = true;
|
polkit.enable = true;
|
||||||
@@ -9,7 +9,7 @@
|
|||||||
isNormalUser = true;
|
isNormalUser = true;
|
||||||
description = "Josh Ashton";
|
description = "Josh Ashton";
|
||||||
group = "jashton";
|
group = "jashton";
|
||||||
extraGroups = [ "networkmanager" "wheel" "tss" "video" "audio" "input" "render" "adbuser" "dialout" "tty" ];
|
extraGroups = [ "networkmanager" "wheel" "tss" "video" "audio" "input" ];
|
||||||
|
|
||||||
shell = pkgs.zsh;
|
shell = pkgs.zsh;
|
||||||
};
|
};
|
||||||
@@ -0,0 +1,79 @@
|
|||||||
|
{ config, pkgs, inputs, ... }:
|
||||||
|
|
||||||
|
let
|
||||||
|
# Instantiate the unstable package set for your system architecture
|
||||||
|
unstable = import inputs.nixpkgs-unstable {
|
||||||
|
system = pkgs.system;
|
||||||
|
config.allowUnfree = true;
|
||||||
|
};
|
||||||
|
in
|
||||||
|
{
|
||||||
|
imports = [
|
||||||
|
inputs.dms.nixosModules.greeter
|
||||||
|
];
|
||||||
|
|
||||||
|
programs.niri = {
|
||||||
|
enable = true;
|
||||||
|
# Tell the Niri module to use the unstable package directly from the niri-flake
|
||||||
|
package = inputs.niri.packages.${pkgs.system}.niri-unstable;
|
||||||
|
};
|
||||||
|
|
||||||
|
programs.dsearch.enable = true;
|
||||||
|
|
||||||
|
programs.dank-material-shell.greeter = {
|
||||||
|
enable = true;
|
||||||
|
compositor.name = "niri";
|
||||||
|
|
||||||
|
configHome = "/home/jashton";
|
||||||
|
};
|
||||||
|
|
||||||
|
programs.dms-shell = {
|
||||||
|
enable = true;
|
||||||
|
enableSystemMonitoring = true;
|
||||||
|
enableVPN = true;
|
||||||
|
enableDynamicTheming = true;
|
||||||
|
enableAudioWavelength = true;
|
||||||
|
enableCalendarEvents = true;
|
||||||
|
|
||||||
|
systemd = {
|
||||||
|
enable = false;
|
||||||
|
restartIfChanged = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
quickshell.package = unstable.quickshell;
|
||||||
|
|
||||||
|
plugins = {
|
||||||
|
developerUtilities.enable = true;
|
||||||
|
batteryPlus.enable = true;
|
||||||
|
mediaDownloader.enable = true;
|
||||||
|
dankBatteryAlerts.enable = true;
|
||||||
|
dmsThemeSync.enable = true;
|
||||||
|
dmsPass.enable = true;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
programs.gnupg.agent = {
|
||||||
|
enable = true;
|
||||||
|
enableSSHSupport = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
services = {
|
||||||
|
libinput = {
|
||||||
|
enable = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
openssh = {
|
||||||
|
enable = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
tailscale = {
|
||||||
|
enable = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
upower.enable = true;
|
||||||
|
printing.enable = true;
|
||||||
|
gvfs.enable = true;
|
||||||
|
gnome.gnome-keyring.enable = true;
|
||||||
|
blueman.enable = true;
|
||||||
|
};
|
||||||
|
}
|
||||||
@@ -2,12 +2,9 @@
|
|||||||
|
|
||||||
{
|
{
|
||||||
virtualisation = {
|
virtualisation = {
|
||||||
containers.enable = true;
|
|
||||||
|
|
||||||
podman = {
|
podman = {
|
||||||
enable = true;
|
enable = true;
|
||||||
dockerCompat = true;
|
dockerCompat = true;
|
||||||
defaultNetwork.settings.dns_enabled = true;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
waydroid.enable = true;
|
waydroid.enable = true;
|
||||||
@@ -17,12 +14,4 @@
|
|||||||
};
|
};
|
||||||
|
|
||||||
networking.firewall.trustedInterfaces = [ "waydroid0" ];
|
networking.firewall.trustedInterfaces = [ "waydroid0" ];
|
||||||
|
|
||||||
# Install podman-compose and helper tools
|
|
||||||
environment.systemPackages = with pkgs; [
|
|
||||||
podman-compose
|
|
||||||
podman-tui
|
|
||||||
slirp4netns
|
|
||||||
fuse-overlayfs
|
|
||||||
];
|
|
||||||
}
|
}
|
||||||
@@ -4,31 +4,22 @@ sops:
|
|||||||
age:
|
age:
|
||||||
- enc: |
|
- enc: |
|
||||||
-----BEGIN AGE ENCRYPTED FILE-----
|
-----BEGIN AGE ENCRYPTED FILE-----
|
||||||
YWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSA5THRkQUg1S1pRTEpHdjRT
|
YWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSAyNjkvMzI5MUtPZEVua0U1
|
||||||
MThsR2tuSytIdzdvWndqMnM3MUNxRk5PMHdBCkRRalFpRC8zQ012RkNKYlloUGpH
|
TkxIREI3MnNNbytGTStXWWxwdm9XbEYwTmlZCnhMcGZGNnU2RTVtRzVUWWxzRzFw
|
||||||
cWJ1bmZEL3VxRndrei9BbGlNYnR3amsKLS0tIFEvR295a2VsRXJsZ1IzSUZCWlhI
|
NTRVT1ZSUFZOY29JNWZacjdoMjE1S3MKLS0tIFVoZk5Ea3pMUUYvYVgvUzdTN2Yx
|
||||||
akcybUs1cmlyL2I0U2tXQmdYb3V5NVUKQ0bkyCvBwpa7BUolE/QXDib5tZ0QvIie
|
V3VITk1wc05DK0tvRnBNZ1ptSldWUGsKT3fSHkqsjkvtRgbPpvIz0ufGPf4pZh6G
|
||||||
cZZ4NDdhq7EtS++sQl6AN9ZUp209F49XMoV/3u17njg1Mdqt2kM5vw==
|
iibDAgCCrsHk0GViDIBlnwOHgwCM4io3j565M+jS6cjV2YKsOHz2Ng==
|
||||||
-----END AGE ENCRYPTED FILE-----
|
-----END AGE ENCRYPTED FILE-----
|
||||||
recipient: age1az6l56h4m38jw2hm7t7a99wp9f88s845sg29grtmdpz72lrkc5cq66kmcv
|
recipient: age1az6l56h4m38jw2hm7t7a99wp9f88s845sg29grtmdpz72lrkc5cq66kmcv
|
||||||
- enc: |
|
- enc: |
|
||||||
-----BEGIN AGE ENCRYPTED FILE-----
|
-----BEGIN AGE ENCRYPTED FILE-----
|
||||||
YWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSBmY2hSRWRjRXBNMXduUTZw
|
YWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSBQelp5Y2E2WFM1TFhIb1gz
|
||||||
NHlyUGxoRnZyVFYzMENDVTljeGpoVlBReFZ3Ci9aREtkYjJuUklaYXljSkNod0RG
|
eS9lWTAydUYrQlYxZkY5akt3MkI5TGlXSVhRCktTV0tFcmFwaS9VVTdwZTRlWkFF
|
||||||
NHhReE5Sck9DRmR2ZlJYdGZEM3pieDAKLS0tIDlYbWV2UllheFRQRUZwVmRteDJW
|
alNQYW83TTcycytWVHVZUVhmOU5ETU0KLS0tIGJmSWZRaW5tM3R6a3ZlaitSb3d3
|
||||||
NU9wZHQyU0t3Tm5odE9UUTVmZkMwZlUKcnXTTlGDMMMwtfIbAOT8UiM/yTyuoDmA
|
a0JFN3NORTBFYVpsMjJkUHdtbFh4c1EK7lRQR/qO3rpctSDC6Mvy6eAA6zj70MDD
|
||||||
+sqOslfVPW/FgCXtCdca2wc3SFs6LjPNmuJFp14tUQByqftNgLv3gA==
|
cmUiMcIDn2FyX5d9r2jk5EZtx2rZPB4ti4pp4Lox3zuEMMCksaFXmw==
|
||||||
-----END AGE ENCRYPTED FILE-----
|
-----END AGE ENCRYPTED FILE-----
|
||||||
recipient: age1cd40qmufxzvw8dkml9340czqfq6ta3kxpjfj47jpavwn2t7ghywsxhqz79
|
recipient: age1cd40qmufxzvw8dkml9340czqfq6ta3kxpjfj47jpavwn2t7ghywsxhqz79
|
||||||
- enc: |
|
|
||||||
-----BEGIN AGE ENCRYPTED FILE-----
|
|
||||||
YWdlLWVuY3J5cHRpb24ub3JnL3YxCi0+IFgyNTUxOSBBYkRuVERsU0JXaXkwc1NM
|
|
||||||
MFlZUzlzWEpWbEVPUTZTcTdLS0hFaXJkc0dnCnh2dDdXZXMreDRCMmU2anNhUnl4
|
|
||||||
ek5zc2hQYThXWVBZM0dTN1F2MXlFV0EKLS0tIG05NmdrK3BJUDVsc0t4dWhrRzZF
|
|
||||||
VnZNV0hpRlZnbEVvc0NSa2NDTU9HeEUKD68eN/3/ReQYS1z0kQ6Txa18hVqrEVo+
|
|
||||||
Cuii27UwrwN07cE1XZx7PHG17pfuCzdnxFPr3CNhFPWCz4f/CD13SA==
|
|
||||||
-----END AGE ENCRYPTED FILE-----
|
|
||||||
recipient: age1dsf6z3hcr8qrtptdk6xyky9c99tdpjyrnuaawv4atme9rffhps9qpwdn6j
|
|
||||||
lastmodified: "2026-08-05T02:52:44Z"
|
lastmodified: "2026-08-05T02:52:44Z"
|
||||||
mac: ENC[AES256_GCM,data:69aZI03tg5IakwK80lx/eVrFq84WB2dk3DFKc5X5Idc2irrz2AodqsmlBNkrDDC6bnv1kUAW8dQlOscbHxKNtOq+lzEtuVI88A2sO1JT06ILFMMfj3R2BEZPtuidl/iytovUKmZrL9JzlNKTd/74htsBvC3cLoIk7r/WfyfoU4w=,iv:r2Jzq9IqL+ssKo13tpJ4OrgnPxxNaNaYbAa0+DnLt54=,tag:GL5AEZPDudVB+IQZtbmwvg==,type:str]
|
mac: ENC[AES256_GCM,data:69aZI03tg5IakwK80lx/eVrFq84WB2dk3DFKc5X5Idc2irrz2AodqsmlBNkrDDC6bnv1kUAW8dQlOscbHxKNtOq+lzEtuVI88A2sO1JT06ILFMMfj3R2BEZPtuidl/iytovUKmZrL9JzlNKTd/74htsBvC3cLoIk7r/WfyfoU4w=,iv:r2Jzq9IqL+ssKo13tpJ4OrgnPxxNaNaYbAa0+DnLt54=,tag:GL5AEZPDudVB+IQZtbmwvg==,type:str]
|
||||||
unencrypted_suffix: _unencrypted
|
unencrypted_suffix: _unencrypted
|
||||||
|
|||||||
@@ -1,5 +0,0 @@
|
|||||||
{ config, pkgs, ... }:
|
|
||||||
|
|
||||||
{
|
|
||||||
boot.kernelParams = [ "mem_sleep_default=deep" ];
|
|
||||||
}
|
|
||||||
@@ -1,28 +0,0 @@
|
|||||||
{ config, pkgs, ... }:
|
|
||||||
|
|
||||||
{
|
|
||||||
|
|
||||||
imports = [];
|
|
||||||
|
|
||||||
networking = {
|
|
||||||
networkmanager = {
|
|
||||||
enable = true;
|
|
||||||
wifi.powersave = false;
|
|
||||||
};
|
|
||||||
|
|
||||||
firewall = {
|
|
||||||
enable = true;
|
|
||||||
allowedTCPPorts = [ 4242 ];
|
|
||||||
allowedUDPPorts = [ 4242 ];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
hardware.bluetooth = {
|
|
||||||
powerOnBoot = true;
|
|
||||||
settings.General.Enable = "Source,Sink,Media,Socket,Network";
|
|
||||||
};
|
|
||||||
|
|
||||||
boot.extraModprobeConfig = ''
|
|
||||||
options iwlwifi power_save=0
|
|
||||||
'';
|
|
||||||
}
|
|
||||||
@@ -1,19 +0,0 @@
|
|||||||
{ config, pkgs, ... }:
|
|
||||||
|
|
||||||
{
|
|
||||||
services.tor = {
|
|
||||||
enable = true;
|
|
||||||
client = {
|
|
||||||
socksListenAddresses = [ { addr = "127.0.0.1"; port = 9050; } ];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
services.privoxy = {
|
|
||||||
enable = true;
|
|
||||||
enableTor = true;
|
|
||||||
};
|
|
||||||
|
|
||||||
environment.systemPackages = with pkgs; [
|
|
||||||
torsocks
|
|
||||||
];
|
|
||||||
}
|
|
||||||
@@ -1,118 +0,0 @@
|
|||||||
{ config, pkgs, inputs, ... }:
|
|
||||||
|
|
||||||
let
|
|
||||||
# Instantiate the unstable package set for your system architecture
|
|
||||||
unstable = import inputs.nixpkgs-unstable {
|
|
||||||
system = pkgs.stdenv.hostPlatform.system;
|
|
||||||
config.allowUnfree = true;
|
|
||||||
};
|
|
||||||
in
|
|
||||||
{
|
|
||||||
imports = [
|
|
||||||
inputs.dankcalendar.nixosModules.default
|
|
||||||
];
|
|
||||||
|
|
||||||
programs.niri = {
|
|
||||||
enable = true;
|
|
||||||
package = inputs.niri.packages.${pkgs.stdenv.hostPlatform.system}.niri-unstable;
|
|
||||||
};
|
|
||||||
|
|
||||||
programs.dms-shell = {
|
|
||||||
enable = true;
|
|
||||||
enableSystemMonitoring = true;
|
|
||||||
enableVPN = true;
|
|
||||||
enableDynamicTheming = true;
|
|
||||||
enableAudioWavelength = true;
|
|
||||||
enableCalendarEvents = true;
|
|
||||||
|
|
||||||
systemd = {
|
|
||||||
enable = true;
|
|
||||||
restartIfChanged = true;
|
|
||||||
};
|
|
||||||
|
|
||||||
quickshell.package = unstable.quickshell;
|
|
||||||
|
|
||||||
plugins = {
|
|
||||||
developerUtilities.enable = true;
|
|
||||||
batteryPlus.enable = true;
|
|
||||||
dankBatteryAlerts.enable = true;
|
|
||||||
dmsThemeSync.enable = true;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
programs.dms-greeter = {
|
|
||||||
enable = true;
|
|
||||||
compositor.name = "niri";
|
|
||||||
|
|
||||||
configHome = "/home/jashton";
|
|
||||||
};
|
|
||||||
|
|
||||||
programs.dank-calendar.enable = true;
|
|
||||||
|
|
||||||
systemd = {
|
|
||||||
user = {
|
|
||||||
services = {
|
|
||||||
niri-flake-polkit.enable = true;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
programs.gnupg.agent = {
|
|
||||||
enable = true;
|
|
||||||
enableSSHSupport = true;
|
|
||||||
};
|
|
||||||
|
|
||||||
services = {
|
|
||||||
libinput = {
|
|
||||||
enable = true;
|
|
||||||
};
|
|
||||||
|
|
||||||
openssh = {
|
|
||||||
enable = true;
|
|
||||||
};
|
|
||||||
|
|
||||||
tailscale = {
|
|
||||||
enable = true;
|
|
||||||
};
|
|
||||||
|
|
||||||
displayManager = {
|
|
||||||
autoLogin = {
|
|
||||||
enable = false;
|
|
||||||
user = "jashton";
|
|
||||||
};
|
|
||||||
|
|
||||||
defaultSession = "niri";
|
|
||||||
};
|
|
||||||
|
|
||||||
upower.enable = true;
|
|
||||||
printing.enable = true;
|
|
||||||
gvfs.enable = true;
|
|
||||||
gnome.gnome-keyring.enable = true;
|
|
||||||
blueman.enable = true;
|
|
||||||
};
|
|
||||||
|
|
||||||
hardware.printers.ensurePrinters = [
|
|
||||||
{
|
|
||||||
name = "Marriott_Library_BW";
|
|
||||||
location = "Knowledge Commons Level 2";
|
|
||||||
description = "UofU B&W Print Queue";
|
|
||||||
deviceUri = "lpd://pharossys-ps1.ucard.utah.edu/kcq-1";
|
|
||||||
model = "drv:///sample.drv/generic.ppd";
|
|
||||||
ppdOptions = {
|
|
||||||
PageSize = "Letter";
|
|
||||||
Duplex = "DuplexNoTumble";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
name = "Marriott_Library_Color";
|
|
||||||
location = "Knowledge Commons Level 2";
|
|
||||||
description = "UofU Color Print Queue";
|
|
||||||
deviceUri = "lpd://pharossys-ps1.ucard.utah.edu/kcq-7";
|
|
||||||
model = "drv:///sample.drv/generic.ppd";
|
|
||||||
ppdOptions = {
|
|
||||||
PageSize = "Letter";
|
|
||||||
Duplex = "DuplexNoTumble";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
];
|
|
||||||
}
|
|
||||||