Compare commits

...

80 commits

Author SHA1 Message Date
9079af661f
callisto: use pre-compiled vesktop to avoid long updates 2024-08-25 05:19:43 -07:00
efaa5c81cd
callisto: pin vesktop to stable to stop constant rebuilds 2024-08-25 04:07:29 -07:00
df1ecf6de4
overlays: refactor and fix error 2024-08-25 03:57:33 -07:00
43224bd176
overlays: remove typst-lsp; add librewolf from stable to build 2024-08-25 03:52:29 -07:00
6f597d83f5
git: add safe directory so nix can rebuild with doas 2024-08-25 03:52:13 -07:00
8804431c97
flake.lock: Update
Flake lock file updates:

• Updated input 'bleedingpkgs':
    'github:nixos/nixpkgs/4c97b427ece2d45026ab6c5264adb67c763e7927' (2024-08-21)
  → 'github:nixos/nixpkgs/cefe8a71e78741c16e88181c8cdf467d07a4b401' (2024-08-25)
• Updated input 'catppuccin':
    'github:catppuccin/nix/8886a68edadb1d93c7101337f995ffce4b410ff2' (2024-08-20)
  → 'github:catppuccin/nix/874e668ddaf3687e8d38ccd0188a641ffefe1cfb' (2024-08-24)
• Updated input 'home-manager':
    'github:nix-community/home-manager/2598861031b78aadb4da7269df7ca9ddfc3e1671' (2024-08-18)
  → 'github:nix-community/home-manager/c2cd2a52e02f1dfa1c88f95abeb89298d46023be' (2024-08-23)
• Updated input 'homebrew-cask':
    'github:homebrew/homebrew-cask/761ddda3d71597c6b594af9416492fbf67ec813e' (2024-08-21)
  → 'github:homebrew/homebrew-cask/f3046f799c32d169398e9940d00018c3535ec8f6' (2024-08-25)
• Updated input 'homebrew-core':
    'github:homebrew/homebrew-core/7270362c593e96b2368834f6a87cd0d904874eb9' (2024-08-21)
  → 'github:homebrew/homebrew-core/0f996959e7c025eb54aa1ada8b43dad0737e78a6' (2024-08-25)
• Updated input 'nix-darwin':
    'github:LnL7/nix-darwin/d6703b988728b89456b32bac242c8689902e5a5b' (2024-08-21)
  → 'github:LnL7/nix-darwin/ac5694a0b855a981e81b4d9f14052e3ff46ca39e' (2024-08-25)
• Updated input 'nixpkgs':
    'github:nixos/nixpkgs/8a3354191c0d7144db9756a74755672387b702ba' (2024-08-18)
  → 'github:nixos/nixpkgs/c374d94f1536013ca8e92341b540eba4c22f9c62' (2024-08-21)
• Updated input 'personal-neovim':
    'github:youwen5/neovim-flake/707837ca26cf3e125309b883815d4bbfd25ccc92' (2024-08-25)
  → 'github:youwen5/neovim-flake/e78144554b191f08a05c7e3d0cb7966c363fcdbb' (2024-08-25)
• Updated input 'spicetify':
    'github:Gerg-L/spicetify-nix/3caf2a241f7af52419ce97c6682b0467219ab914' (2024-08-24)
  → 'github:Gerg-L/spicetify-nix/8d823dea059ec5de57f276360acbd0601b20e433' (2024-08-25)
• Updated input 'stablepkgs':
    'github:nixos/nixpkgs/f1bad50880bae73ff2d82fafc22010b4fc097a9c' (2024-08-19)
  → 'github:nixos/nixpkgs/797f7dc49e0bc7fab4b57c021cdf68f595e47841' (2024-08-22)
2024-08-25 03:41:38 -07:00
02a6f0b4f8
feat: switch to new package-based neovim flake 2024-08-24 23:58:52 -07:00
eb83c0af49
flake: use new neovim flake with package 2024-08-24 23:58:43 -07:00
ec4b978819
nvim flake lock update 2024-08-24 23:11:54 -07:00
d27fd31030
fix: remove deprecated neovim module 2024-08-24 22:22:37 -07:00
bad90f15ed
feat: move neovim to external flake 2024-08-24 22:20:31 -07:00
a47575cfae
chore: clean up unused file 2024-08-24 11:28:18 -07:00
0b902b95e4
fix: use better patch on asahi for hyprland 2024-08-24 11:28:02 -07:00
7fb6171dcf
chore: remove outdated sudo config for doas 2024-08-24 04:05:07 -07:00
4e5adbd869
feat: switch from sudo to doas 2024-08-24 03:52:55 -07:00
cbcb9467d6
chore: rename nixos to linux 2024-08-24 03:52:45 -07:00
26aa04552c
fix: place omp disable checking in right place 2024-08-24 03:47:26 -07:00
3ebf22d7ce
chore: remove unused functions/aliae 2024-08-24 03:46:51 -07:00
d60a08ceb0
docs: update some stuff 2024-08-24 03:23:36 -07:00
c11f3ef550
feat(vim): replace mini.pairs with nvim-autopair 2024-08-24 03:04:12 -07:00
4343e50b6d
update todos 2024-08-24 02:18:37 -07:00
5b3c4b4ee6
style(spotify): adjust themes and extensions 2024-08-24 01:42:43 -07:00
dc86e970e7
networking: open firewall ports for grim dawn 2024-08-23 23:47:22 -07:00
4516685bb9
feat: add spicetify 2024-08-23 23:14:53 -07:00
6c200053b2
feat: add hamachi 2024-08-23 23:02:31 -07:00
ca88c64494
binds: add thunderbird bind 2024-08-23 21:49:26 -07:00
9e52ef6c28
style(hypr): add windowrule to pavucontrol and thunderbird 2024-08-23 13:06:42 -07:00
94a63f86ef
style(hypr): add windowrule to waypaper 2024-08-23 12:59:31 -07:00
783c65f2ff
fix(adrastea): use latest hyprland 2024-08-22 22:07:39 -07:00
ddab834b69
fix: build successfully on adrastea 2024-08-22 19:08:11 -07:00
a2a9e20ba8
bindings: retool some desktop keybinds 2024-08-22 13:46:47 -07:00
c164b0ece8
refactor: move machine specific monitor config 2024-08-22 13:20:21 -07:00
49c72907d9
refactor: move packages into modules 2024-08-22 01:54:15 -07:00
23f6326c2b
binds: change directional keys 2024-08-22 01:40:22 -07:00
675f37c5b1
feat: add spotifyd module 2024-08-22 01:38:05 -07:00
f05231223b
refactor: remove neofetch-asahi module and set in hosts 2024-08-21 21:49:38 -07:00
88dd424203
chore: re-enable vesktop 2024-08-21 18:43:04 -07:00
c1257d3ba1 chore: adjust laptop trackpad sensitivity 2024-08-21 18:31:13 -07:00
2a92bc9e69 chore: adjust sensitivity 2024-08-21 17:14:46 -07:00
598736167a fix: use updated values of input.sensitivity 2024-08-21 17:02:09 -07:00
a97e676fb7 refactor: change home manager overrides name 2024-08-21 16:52:53 -07:00
4a6b3a895d pkgs: use stable hyprland for demeter 2024-08-21 16:52:11 -07:00
9fbf576165 Squash merge asahi-fix into main 2024-08-21 16:48:17 -07:00
e5a4f927a3
fix: librewolf-wayland 2024-08-20 15:54:42 -07:00
2353431515
update system*
*added overlay to build typst-lsp
2024-08-19 20:15:18 -07:00
955e517597
feat(nvim): disable diagnostic lines by default 2024-08-19 18:29:10 -07:00
793ce9aad2
fix: add fourmolu to closure 2024-08-19 13:26:55 -07:00
a0473a0338
fix: correct command to toggle lsp lines 2024-08-19 02:30:38 -07:00
c2993c4102
feat: add nix-direnv 2024-08-19 02:29:19 -07:00
bc6eac3bf2
feat: add keybinding to toggle lsp lines 2024-08-19 02:27:51 -07:00
ec60a62e4f
chore: configure fourmolu for haskell 2024-08-19 01:45:03 -07:00
0a5b76c290
fix: use correct conform formatter for rust 2024-08-19 00:54:38 -07:00
b1c8959a85
feat: add harpoon config for neovim 2024-08-19 00:21:53 -07:00
80741b7f7b
feat: add lsp rename feat 2024-08-18 20:48:20 -07:00
a44b125f4a
feat: add some vim config 2024-08-18 19:39:44 -07:00
46bce37908
deps: specify all deps for plugins 2024-08-18 19:03:57 -07:00
5463fb9487
feat: move yazi and add image previews 2024-08-18 19:02:21 -07:00
997cdb92d2
feat: reorganize and add code action view 2024-08-18 18:22:20 -07:00
77708927da
chore: remove all development tools (cargo,npm,etc) from global packages 2024-08-18 14:23:20 -07:00
bbe6adc498
feat: reorganize some stuff 2024-08-18 14:21:23 -07:00
37caaa036d
fix: configure and enable yazi 2024-08-18 03:44:22 -07:00
b3c0ab342c
feat: configure yazi file viewer 2024-08-18 03:36:57 -07:00
30ba3c5580
feat: add yanky binds 2024-08-18 03:00:10 -07:00
267ccb6279
vim: switch to rose-pine 2024-08-18 01:23:26 -07:00
635c5c4e2d
feat: use haskell-tools.nvim instead of direct hls 2024-08-18 01:16:32 -07:00
bde2160dfa
feat(vim): working baseline config with LSP + completion + treesitter 2024-08-17 15:52:27 -07:00
fee4623629
feat: add neovim configuration by nixvim 2024-08-17 04:49:37 -07:00
16ca570751
Revert "ci: add cachix build action"
This reverts commit b43cc04ea7.
2024-08-16 16:23:31 -07:00
6f8505f1b9
Revert "ci: test building demeter image"
This reverts commit ba022c35b7.
2024-08-16 16:23:25 -07:00
6f543f19b3
Revert "fix(ci): correctly build system"
This reverts commit 1d44a94079.
2024-08-16 16:23:17 -07:00
1d44a94079
fix(ci): correctly build system 2024-08-16 16:16:56 -07:00
ba022c35b7
ci: test building demeter image 2024-08-16 16:13:47 -07:00
Youwen Wu
b43cc04ea7
ci: add cachix build action 2024-08-16 16:08:11 -07:00
586b4a27cd
add badge to readme 2024-08-16 06:59:00 -07:00
26439134dd
chore: switch to alejandra and format 2024-08-16 06:42:35 -07:00
9062a9d3ed
feat: enable direnv 2024-08-16 05:09:55 -07:00
1d50e3276a
docs: add todos 2024-08-16 00:37:48 -07:00
b928431067
packages(linux): add bitwarden-cli 2024-08-15 16:15:12 -07:00
d049aa90ee
feat: enable flatpaks temporarily for sober 2024-08-15 14:54:22 -07:00
f61adf8ad4
chore: add placeholder core nixos module 2024-08-15 00:51:43 -07:00
53 changed files with 1642 additions and 1934 deletions

View file

@ -3,8 +3,11 @@
This is a repository that implements liminalOS, my personal Linux distribution This is a repository that implements liminalOS, my personal Linux distribution
based on [NixOS](https://nixos.org/). based on [NixOS](https://nixos.org/).
Time wasted writing Nix code:
![](https://wakatime.com/badge/user/018dc5b8-ba5a-4572-a38a-b526d1b28240/project/c59b3d5e-0c9c-4bd5-a752-e75522ab0cdc.svg)
<!-- prettier-ignore --> <!-- prettier-ignore -->
> **lim·i·nal** > **lim·i·nal**
> 1. between or belonging to two different places, states, etc. > 1. between or belonging to two different places, states, etc.
The goal of liminalOS is to allow my computing environment to exist in different The goal of liminalOS is to allow my computing environment to exist in different
@ -102,21 +105,23 @@ The [flake.nix](/flake.nix) currently contains my configuration for four hosts:
## Keybinds ## Keybinds
Non-exhaustive.
| Shortcut | Action | | Shortcut | Action |
| -------------------------------------------------------------------------------------------------------- | -------------------------------- | | -------------------------------------------------------------------------------------------------------- | -------------------------------- |
| <kbd>Super</kbd> + <kbd>W</kbd> | Toggle floating | | <kbd>Super</kbd> + <kbd>W</kbd> | Toggle floating |
| <kbd>Super</kbd> + <kbd>J</kbd> | Toggle layout | | <kbd>Super</kbd> + <kbd>K</kbd> | Toggle layout |
| <kbd>Super</kbd> + <kbd>E</kbd> | Open Dolphin | | <kbd>Super</kbd> + <kbd>E</kbd> | Open Dolphin |
| <kbd>Super</kbd> + <kbd>T</kbd> | Open kitty | | <kbd>Super</kbd> + <kbd>T</kbd> | Open kitty |
| <kbd>Super</kbd> + <kbd>F</kbd> | Open librewolf | | <kbd>Super</kbd> + <kbd>F</kbd> | Open librewolf |
| <kbd>Super</kbd> + <kbd>R</kbd> | Open pavucontrol | | <kbd>Super</kbd> + <kbd>R</kbd> | Open pavucontrol |
| <kbd>Super</kbd> + <kbd>Space</kbd> | Open rofi | | <kbd>Super</kbd> + <kbd>Space</kbd> | Open rofi |
| <kbd>Super</kbd> + <kbd>Backspace</kbd> | Open logout menu | | <kbd>Super</kbd> + <kbd>Backspace</kbd> | Open logout menu |
| <kbd>Super</kbd> + <kbd>P</kbd> | Screenshot region | | <kbd>Super</kbd> + <kbd>L</kbd> | Screenshot region |
| <kbd>Super</kbd> + <kbd>Y</kbd><kbd>U</kbd><kbd>I</kbd><kbd>O</kbd> | Move around | | <kbd>Super</kbd> + <kbd>H</kbd><kbd>J</kbd><kbd>K</kbd><kbd>L</kbd> | Move around |
| <kbd>Super</kbd> + <kbd>Ctrl</kbd> + <kbd>Y</kbd><kbd>O</kbd> | Move workspaces | | <kbd>Super</kbd> + <kbd>Ctrl</kbd> + <kbd>H</kbd><kbd>L</kbd> | Move workspaces |
| <kbd>Super</kbd> + <kbd>Alt</kbd> + <kbd>Ctrl</kbd> + <kbd>Y</kbd><kbd>U</kbd><kbd>I</kbd><kbd>O</kbd> | Move windows around workspaces | | <kbd>Super</kbd> + <kbd>Alt</kbd> + <kbd>Ctrl</kbd> + <kbd>H</kbd><kbd>J</kbd><kbd>K</kbd><kbd>L</kbd> | Move windows around workspaces |
| <kbd>Super</kbd> + <kbd>Shift</kbd> + <kbd>Ctrl</kbd> + <kbd>Y</kbd><kbd>U</kbd><kbd>I</kbd><kbd>O</kbd> | Move windows around | | <kbd>Super</kbd> + <kbd>Shift</kbd> + <kbd>Ctrl</kbd> + <kbd>H</kbd><kbd>J</kbd><kbd>K</kbd><kbd>L</kbd> | Move windows around |
| <kbd>Super</kbd> + <kbd>S</kbd> | Open Special Workspace | | <kbd>Super</kbd> + <kbd>S</kbd> | Open Special Workspace |
| <kbd>Super</kbd> + <kbd>Enter</kbd> | Fullscreen Window | | <kbd>Super</kbd> + <kbd>Enter</kbd> | Fullscreen Window |
| <kbd>Super</kbd> + <kbd>Alt</kbd> + <kbd>S</kbd> | Move Window to Special Workspace | | <kbd>Super</kbd> + <kbd>Alt</kbd> + <kbd>S</kbd> | Move Window to Special Workspace |

15
TODOS.md Normal file
View file

@ -0,0 +1,15 @@
# To Do
## P1
## P2
- [ ] Move wallpapers to submodule
- [ ] Move Neovim to submodule
## Done
- [x] Add Nvidia-specific config options for Hyprland (blocked by P1)
- [x] Massively refactor module system

View file

@ -24,11 +24,11 @@
}, },
"bleedingpkgs": { "bleedingpkgs": {
"locked": { "locked": {
"lastModified": 1723688039, "lastModified": 1724581532,
"narHash": "sha256-/QVv3/9gnukdsUZRR5eJQLhcuXBCLe0rGrF5O6w6jA0=", "narHash": "sha256-h9a24T9AE4/kIsK1m6zoeEo8XyRDI83sVXQS4OOmVfk=",
"owner": "nixos", "owner": "nixos",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "1ad352fd9ea96cebc7862782fa8d0d295c68ff15", "rev": "cefe8a71e78741c16e88181c8cdf467d07a4b401",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -57,11 +57,11 @@
}, },
"catppuccin": { "catppuccin": {
"locked": { "locked": {
"lastModified": 1722997334, "lastModified": 1724469296,
"narHash": "sha256-vE5FcKVQ3E0txJKt5w3vOlfcN1XoTAlxK9PnQ/CJavA=", "narHash": "sha256-p3R4LUNk6gC+fTKRUm9ByXaoRIocnQMwVuJSIxECQ8o=",
"owner": "catppuccin", "owner": "catppuccin",
"repo": "nix", "repo": "nix",
"rev": "66f4ea170093b62f319f41cebd2337a51b225c5a", "rev": "874e668ddaf3687e8d38ccd0188a641ffefe1cfb",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -91,6 +91,28 @@
"type": "github" "type": "github"
} }
}, },
"devshell": {
"inputs": {
"nixpkgs": [
"personal-neovim",
"nixvim",
"nixpkgs"
]
},
"locked": {
"lastModified": 1722113426,
"narHash": "sha256-Yo/3loq572A8Su6aY5GP56knpuKYRvM2a1meP9oJZCw=",
"owner": "numtide",
"repo": "devshell",
"rev": "67cce7359e4cd3c45296fb4aaf6a19e2a9c757ae",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "devshell",
"type": "github"
}
},
"flake-compat": { "flake-compat": {
"locked": { "locked": {
"lastModified": 1688025799, "lastModified": 1688025799,
@ -122,6 +144,36 @@
"type": "github" "type": "github"
} }
}, },
"flake-compat_3": {
"locked": {
"lastModified": 1696426674,
"narHash": "sha256-kvjfFW7WAETZlt09AgDn1MrtKzP7t90Vf7vypd3OL1U=",
"rev": "0f9255e01c2351cc7d116c072cb317785dd33b33",
"revCount": 57,
"type": "tarball",
"url": "https://api.flakehub.com/f/pinned/edolstra/flake-compat/1.0.1/018afb31-abd1-7bff-a5e4-cff7e18efb7a/source.tar.gz"
},
"original": {
"type": "tarball",
"url": "https://flakehub.com/f/edolstra/flake-compat/1.tar.gz"
}
},
"flake-compat_4": {
"flake": false,
"locked": {
"lastModified": 1696426674,
"narHash": "sha256-kvjfFW7WAETZlt09AgDn1MrtKzP7t90Vf7vypd3OL1U=",
"owner": "edolstra",
"repo": "flake-compat",
"rev": "0f9255e01c2351cc7d116c072cb317785dd33b33",
"type": "github"
},
"original": {
"owner": "edolstra",
"repo": "flake-compat",
"type": "github"
}
},
"flake-parts": { "flake-parts": {
"inputs": { "inputs": {
"nixpkgs-lib": [ "nixpkgs-lib": [
@ -143,6 +195,46 @@
"type": "github" "type": "github"
} }
}, },
"flake-parts_2": {
"inputs": {
"nixpkgs-lib": "nixpkgs-lib"
},
"locked": {
"lastModified": 1722555600,
"narHash": "sha256-XOQkdLafnb/p9ij77byFQjDf5m5QYl9b2REiVClC+x4=",
"owner": "hercules-ci",
"repo": "flake-parts",
"rev": "8471fe90ad337a8074e957b69ca4d0089218391d",
"type": "github"
},
"original": {
"owner": "hercules-ci",
"repo": "flake-parts",
"type": "github"
}
},
"flake-parts_3": {
"inputs": {
"nixpkgs-lib": [
"personal-neovim",
"nixvim",
"nixpkgs"
]
},
"locked": {
"lastModified": 1722555600,
"narHash": "sha256-XOQkdLafnb/p9ij77byFQjDf5m5QYl9b2REiVClC+x4=",
"owner": "hercules-ci",
"repo": "flake-parts",
"rev": "8471fe90ad337a8074e957b69ca4d0089218391d",
"type": "github"
},
"original": {
"owner": "hercules-ci",
"repo": "flake-parts",
"type": "github"
}
},
"flake-utils": { "flake-utils": {
"inputs": { "inputs": {
"systems": "systems" "systems": "systems"
@ -197,6 +289,24 @@
"type": "github" "type": "github"
} }
}, },
"flake-utils_4": {
"inputs": {
"systems": "systems_4"
},
"locked": {
"lastModified": 1710146030,
"narHash": "sha256-SZ5L6eA7HJ/nmkzGG7/ISclqe6oZdOZTNoesiInkXPQ=",
"owner": "numtide",
"repo": "flake-utils",
"rev": "b1d9ab70662946ef0850d488da1c9019f3a9752a",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "flake-utils",
"type": "github"
}
},
"flakey-profile": { "flakey-profile": {
"locked": { "locked": {
"lastModified": 1712898590, "lastModified": 1712898590,
@ -212,6 +322,39 @@
"type": "github" "type": "github"
} }
}, },
"git-hooks": {
"inputs": {
"flake-compat": [
"personal-neovim",
"nixvim",
"flake-compat"
],
"gitignore": "gitignore_2",
"nixpkgs": [
"personal-neovim",
"nixvim",
"nixpkgs"
],
"nixpkgs-stable": [
"personal-neovim",
"nixvim",
"nixpkgs"
]
},
"locked": {
"lastModified": 1724440431,
"narHash": "sha256-9etXEOUtzeMgqg1u0wp+EdwG7RpmrAZ2yX516bMj2aE=",
"owner": "cachix",
"repo": "git-hooks.nix",
"rev": "c8a54057aae480c56e28ef3e14e4960628ac495b",
"type": "github"
},
"original": {
"owner": "cachix",
"repo": "git-hooks.nix",
"type": "github"
}
},
"gitignore": { "gitignore": {
"inputs": { "inputs": {
"nixpkgs": [ "nixpkgs": [
@ -234,6 +377,29 @@
"type": "github" "type": "github"
} }
}, },
"gitignore_2": {
"inputs": {
"nixpkgs": [
"personal-neovim",
"nixvim",
"git-hooks",
"nixpkgs"
]
},
"locked": {
"lastModified": 1709087332,
"narHash": "sha256-HG2cCnktfHsKV0s4XW83gU3F57gaTljL9KNSuG6bnQs=",
"owner": "hercules-ci",
"repo": "gitignore.nix",
"rev": "637db329424fd7e46cf4185293b9cc8c88c95394",
"type": "github"
},
"original": {
"owner": "hercules-ci",
"repo": "gitignore.nix",
"type": "github"
}
},
"home-manager": { "home-manager": {
"inputs": { "inputs": {
"nixpkgs": [ "nixpkgs": [
@ -241,11 +407,33 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1723399884, "lastModified": 1724435763,
"narHash": "sha256-97wn0ihhGqfMb8WcUgzzkM/TuAxce2Gd20A8oiruju4=", "narHash": "sha256-UNky3lJNGQtUEXT2OY8gMxejakSWPTfWKvpFkpFlAfM=",
"owner": "nix-community", "owner": "nix-community",
"repo": "home-manager", "repo": "home-manager",
"rev": "086f619dd991a4d355c07837448244029fc2d9ab", "rev": "c2cd2a52e02f1dfa1c88f95abeb89298d46023be",
"type": "github"
},
"original": {
"owner": "nix-community",
"repo": "home-manager",
"type": "github"
}
},
"home-manager_2": {
"inputs": {
"nixpkgs": [
"personal-neovim",
"nixvim",
"nixpkgs"
]
},
"locked": {
"lastModified": 1724435763,
"narHash": "sha256-UNky3lJNGQtUEXT2OY8gMxejakSWPTfWKvpFkpFlAfM=",
"owner": "nix-community",
"repo": "home-manager",
"rev": "c2cd2a52e02f1dfa1c88f95abeb89298d46023be",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -257,11 +445,11 @@
"homebrew-cask": { "homebrew-cask": {
"flake": false, "flake": false,
"locked": { "locked": {
"lastModified": 1723687108, "lastModified": 1724579842,
"narHash": "sha256-yS7kiSJyJzd+mpzAQ1ntrfejGICEhScev6NA0F5rsDE=", "narHash": "sha256-izixjuJn9JjWhmfRXCSVSODosdNcK0nEZVDWzk8+vJ0=",
"owner": "homebrew", "owner": "homebrew",
"repo": "homebrew-cask", "repo": "homebrew-cask",
"rev": "5feec29994320afeeb5a1a74860a57d9f845bc30", "rev": "f3046f799c32d169398e9940d00018c3535ec8f6",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -273,11 +461,11 @@
"homebrew-core": { "homebrew-core": {
"flake": false, "flake": false,
"locked": { "locked": {
"lastModified": 1723681288, "lastModified": 1724581596,
"narHash": "sha256-uU0etusCLcip1KNB2FA8/Zpi+hGwAzKX9X32fdFnTNw=", "narHash": "sha256-/IEFvoNS7LM3mVIUvmKyekFTByORdTkcTWrmCz3gja8=",
"owner": "homebrew", "owner": "homebrew",
"repo": "homebrew-core", "repo": "homebrew-core",
"rev": "5bf3c1c505315f0adff00ce8921169fbf7df217c", "rev": "0f996959e7c025eb54aa1ada8b43dad0737e78a6",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -355,11 +543,11 @@
] ]
}, },
"locked": { "locked": {
"lastModified": 1722924007, "lastModified": 1724561770,
"narHash": "sha256-+CQDamNwqO33REJLft8c26NbUi2Td083hq6SvAm2xkU=", "narHash": "sha256-zv8C9RNa86CIpyHwPIVO/k+5TfM8ZbjGwOOpTe1grls=",
"owner": "LnL7", "owner": "LnL7",
"repo": "nix-darwin", "repo": "nix-darwin",
"rev": "91010a5613ffd7ee23ee9263213157a1c422b705", "rev": "ac5694a0b855a981e81b4d9f14052e3ff46ca39e",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -386,6 +574,28 @@
"type": "github" "type": "github"
} }
}, },
"nix-darwin_3": {
"inputs": {
"nixpkgs": [
"personal-neovim",
"nixvim",
"nixpkgs"
]
},
"locked": {
"lastModified": 1724469941,
"narHash": "sha256-+U5152FwmDD9EUOiFi5CFxCK6/yFESyDei9jEIlmUtI=",
"owner": "lnl7",
"repo": "nix-darwin",
"rev": "ea319a737939094b48fda9063fa3201ef2479aac",
"type": "github"
},
"original": {
"owner": "lnl7",
"repo": "nix-darwin",
"type": "github"
}
},
"nix-homebrew": { "nix-homebrew": {
"inputs": { "inputs": {
"brew-src": "brew-src", "brew-src": "brew-src",
@ -420,6 +630,18 @@
"type": "indirect" "type": "indirect"
} }
}, },
"nixpkgs-lib": {
"locked": {
"lastModified": 1722555339,
"narHash": "sha256-uFf2QeW7eAHlYXuDktm9c25OxOyCoUOQmh5SZ9amE5Q=",
"type": "tarball",
"url": "https://github.com/NixOS/nixpkgs/archive/a5d394176e64ab29c852d03346c1fc9b0b7d33eb.tar.gz"
},
"original": {
"type": "tarball",
"url": "https://github.com/NixOS/nixpkgs/archive/a5d394176e64ab29c852d03346c1fc9b0b7d33eb.tar.gz"
}
},
"nixpkgs-stable": { "nixpkgs-stable": {
"locked": { "locked": {
"lastModified": 1710695816, "lastModified": 1710695816,
@ -454,11 +676,11 @@
}, },
"nixpkgs_3": { "nixpkgs_3": {
"locked": { "locked": {
"lastModified": 1723362943, "lastModified": 1724224976,
"narHash": "sha256-dFZRVSgmJkyM0bkPpaYRtG/kRMRTorUIDj8BxoOt1T4=", "narHash": "sha256-Z/ELQhrSd7bMzTO8r7NZgi9g5emh+aRKoCdaAv5fiO0=",
"owner": "nixos", "owner": "nixos",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "a58bc8ad779655e790115244571758e8de055e3d", "rev": "c374d94f1536013ca8e92341b540eba4c22f9c62",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -468,6 +690,94 @@
"type": "github" "type": "github"
} }
}, },
"nixpkgs_4": {
"locked": {
"lastModified": 1724224976,
"narHash": "sha256-Z/ELQhrSd7bMzTO8r7NZgi9g5emh+aRKoCdaAv5fiO0=",
"owner": "nixos",
"repo": "nixpkgs",
"rev": "c374d94f1536013ca8e92341b540eba4c22f9c62",
"type": "github"
},
"original": {
"owner": "nixos",
"ref": "nixos-unstable",
"repo": "nixpkgs",
"type": "github"
}
},
"nixvim": {
"inputs": {
"devshell": "devshell",
"flake-compat": "flake-compat_3",
"flake-parts": "flake-parts_3",
"git-hooks": "git-hooks",
"home-manager": "home-manager_2",
"nix-darwin": "nix-darwin_3",
"nixpkgs": [
"personal-neovim",
"nixpkgs"
],
"nuschtosSearch": "nuschtosSearch",
"treefmt-nix": "treefmt-nix"
},
"locked": {
"lastModified": 1724528976,
"narHash": "sha256-5W13nD/5ySIsxSvDqXHlj4bg2F3tNcYGKCGudWzpNzw=",
"owner": "nix-community",
"repo": "nixvim",
"rev": "8234ee85eaa2c8b7f2c74f5b4cdf02c4965b07fc",
"type": "github"
},
"original": {
"owner": "nix-community",
"repo": "nixvim",
"type": "github"
}
},
"nuschtosSearch": {
"inputs": {
"flake-utils": "flake-utils_4",
"nixpkgs": [
"personal-neovim",
"nixvim",
"nixpkgs"
]
},
"locked": {
"lastModified": 1723969429,
"narHash": "sha256-BuewfNEXEf11MIkJY+uvWsdLu1dIvgJqntWChvNdALg=",
"owner": "NuschtOS",
"repo": "search",
"rev": "a05d1805f2a2bc47d230e5e92aecbf69f784f3d0",
"type": "github"
},
"original": {
"owner": "NuschtOS",
"repo": "search",
"type": "github"
}
},
"personal-neovim": {
"inputs": {
"flake-parts": "flake-parts_2",
"nixpkgs": "nixpkgs_4",
"nixvim": "nixvim"
},
"locked": {
"lastModified": 1724569831,
"narHash": "sha256-GwBiSvqGOlkWqRfsgv9A+e+v6dPDd8J3YEwtez3jnkI=",
"owner": "youwen5",
"repo": "neovim-flake",
"rev": "e78144554b191f08a05c7e3d0cb7966c363fcdbb",
"type": "github"
},
"original": {
"owner": "youwen5",
"repo": "neovim-flake",
"type": "github"
}
},
"pre-commit-hooks-nix": { "pre-commit-hooks-nix": {
"inputs": { "inputs": {
"flake-compat": [ "flake-compat": [
@ -508,6 +818,8 @@
"nix-darwin": "nix-darwin", "nix-darwin": "nix-darwin",
"nix-homebrew": "nix-homebrew", "nix-homebrew": "nix-homebrew",
"nixpkgs": "nixpkgs_3", "nixpkgs": "nixpkgs_3",
"personal-neovim": "personal-neovim",
"spicetify": "spicetify",
"stablepkgs": "stablepkgs" "stablepkgs": "stablepkgs"
} }
}, },
@ -552,13 +864,34 @@
"type": "github" "type": "github"
} }
}, },
"spicetify": {
"inputs": {
"flake-compat": "flake-compat_4",
"nixpkgs": [
"nixpkgs"
]
},
"locked": {
"lastModified": 1724559309,
"narHash": "sha256-9y3yreHjQyyn8bIQmTx1ZkiNGgq1og/PDUZLiE96iJA=",
"owner": "Gerg-L",
"repo": "spicetify-nix",
"rev": "8d823dea059ec5de57f276360acbd0601b20e433",
"type": "github"
},
"original": {
"owner": "Gerg-L",
"repo": "spicetify-nix",
"type": "github"
}
},
"stablepkgs": { "stablepkgs": {
"locked": { "locked": {
"lastModified": 1723556749, "lastModified": 1724316499,
"narHash": "sha256-+CHVZnTnIYRLYsARInHYoWkujzcRkLY/gXm3s5bE52o=", "narHash": "sha256-Qb9MhKBUTCfWg/wqqaxt89Xfi6qTD3XpTzQ9eXi3JmE=",
"owner": "nixos", "owner": "nixos",
"repo": "nixpkgs", "repo": "nixpkgs",
"rev": "4a92571f9207810b559c9eac203d1f4d79830073", "rev": "797f7dc49e0bc7fab4b57c021cdf68f595e47841",
"type": "github" "type": "github"
}, },
"original": { "original": {
@ -612,6 +945,43 @@
"repo": "default", "repo": "default",
"type": "github" "type": "github"
} }
},
"systems_4": {
"locked": {
"lastModified": 1681028828,
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
"owner": "nix-systems",
"repo": "default",
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
"type": "github"
},
"original": {
"owner": "nix-systems",
"repo": "default",
"type": "github"
}
},
"treefmt-nix": {
"inputs": {
"nixpkgs": [
"personal-neovim",
"nixvim",
"nixpkgs"
]
},
"locked": {
"lastModified": 1724338379,
"narHash": "sha256-kKJtaiU5Ou+e/0Qs7SICXF22DLx4V/WhG1P6+k4yeOE=",
"owner": "numtide",
"repo": "treefmt-nix",
"rev": "070f834771efa715f3e74cd8ab93ecc96fabc951",
"type": "github"
},
"original": {
"owner": "numtide",
"repo": "treefmt-nix",
"type": "github"
}
} }
}, },
"root": "root", "root": "root",

202
flake.nix
View file

@ -3,178 +3,108 @@
inputs = { inputs = {
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable"; nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
home-manager = { home-manager = {
url = "github:nix-community/home-manager"; url = "github:nix-community/home-manager";
inputs.nixpkgs.follows = "nixpkgs"; inputs.nixpkgs.follows = "nixpkgs";
}; };
stablepkgs.url = "github:nixos/nixpkgs/nixos-24.05"; stablepkgs.url = "github:nixos/nixpkgs/nixos-24.05";
bleedingpkgs.url = "github:nixos/nixpkgs/master"; bleedingpkgs.url = "github:nixos/nixpkgs/master";
nix-darwin.url = "github:LnL7/nix-darwin";
nix-darwin.inputs.nixpkgs.follows = "nixpkgs"; nix-darwin = {
url = "github:LnL7/nix-darwin";
inputs.nixpkgs.follows = "nixpkgs";
};
nix-homebrew.url = "github:zhaofengli-wip/nix-homebrew"; nix-homebrew.url = "github:zhaofengli-wip/nix-homebrew";
homebrew-core = { homebrew-core = {
url = "github:homebrew/homebrew-core"; url = "github:homebrew/homebrew-core";
flake = false; flake = false;
}; };
homebrew-cask = { homebrew-cask = {
url = "github:homebrew/homebrew-cask"; url = "github:homebrew/homebrew-cask";
flake = false; flake = false;
}; };
catppuccin.url = "github:catppuccin/nix"; catppuccin.url = "github:catppuccin/nix";
lanzaboote = { lanzaboote = {
url = "github:nix-community/lanzaboote/v0.4.1"; url = "github:nix-community/lanzaboote/v0.4.1";
# Optional but recommended to limit the size of your system closure. # Optional but recommended to limit the size of your system closure.
inputs.nixpkgs.follows = "nixpkgs"; inputs.nixpkgs.follows = "nixpkgs";
}; };
lix-module = { lix-module = {
url = url = "https://git.lix.systems/lix-project/nixos-module/archive/2.90.0.tar.gz";
"https://git.lix.systems/lix-project/nixos-module/archive/2.90.0.tar.gz";
inputs.nixpkgs.follows = "nixpkgs"; inputs.nixpkgs.follows = "nixpkgs";
}; };
apple-silicon = { apple-silicon = {
url = "github:tpwrules/nixos-apple-silicon"; url = "github:tpwrules/nixos-apple-silicon";
inputs.nixpkgs.follows = "nixpkgs"; inputs.nixpkgs.follows = "nixpkgs";
}; };
spicetify = {
url = "github:Gerg-L/spicetify-nix";
inputs.nixpkgs.follows = "nixpkgs";
};
personal-neovim.url = "github:youwen5/neovim-flake";
}; };
outputs = { self, nixpkgs, home-manager, catppuccin, lanzaboote, stablepkgs outputs = {
, bleedingpkgs, lix-module, nix-darwin, nix-homebrew, apple-silicon, ... nixpkgs,
}@inputs: rec { nix-darwin,
formatter.x86_64-linux = nixpkgs.legacyPackages.x86_64-linux.nixfmt; ...
nixosConfigurations = { } @ inputs: let
demeter = nixpkgs.lib.nixosSystem { in {
specialArgs = { inherit inputs; }; formatter = with nixpkgs.legacyPackages; {
x86_64-linux = x86_64-linux.alejandra;
aarch64-linux = aarch64-linux.alejandra;
aarch64-darwin = aarch64-darwin.alejandra;
};
nixosConfigurations = {
demeter = nixpkgs.lib.nixosSystem {
system = "x86_64-linux";
specialArgs = {
inherit inputs;
system = "x86_64-linux"; system = "x86_64-linux";
modules = [
./hosts/demeter
./modules/nixos/gaming
./modules/nixos/audio
./modules/nixos/networking
./modules/nixos/fonts
./modules/nixos/greeter
catppuccin.nixosModules.catppuccin
lix-module.nixosModules.default
lanzaboote.nixosModules.lanzaboote
home-manager.nixosModules.home-manager
{
home-manager.useGlobalPkgs = true;
home-manager.useUserPackages = true;
home-manager.backupFileExtension = "backup";
home-manager.users.youwen = {
imports = [
./users/youwen/linux/desktop
./users/youwen/linux/packages/x86_64
./users/youwen/linux/programs
./users/youwen/common/neofetch
./users/youwen/common
inputs.catppuccin.homeManagerModules.catppuccin
];
};
}
];
}; };
callisto = nixpkgs.lib.nixosSystem {
specialArgs = { inherit inputs; };
system = "aarch64-linux";
modules = [
./hosts/callisto
./modules/nixos/audio
./modules/nixos/networking
./modules/nixos/fonts
./modules/nixos/greeter
apple-silicon.nixosModules.apple-silicon-support
catppuccin.nixosModules.catppuccin
lix-module.nixosModules.default
home-manager.nixosModules.home-manager
{
home-manager.useGlobalPkgs = true;
home-manager.useUserPackages = true;
home-manager.backupFileExtension = "backup";
home-manager.users.youwen = {
imports = [
./users/youwen/common
./users/youwen/common/neofetch/asahi-only.nix
./users/youwen/linux/laptop
./users/youwen/linux/packages/aarch-64
inputs.catppuccin.homeManagerModules.catppuccin
];
};
}
{
nixpkgs.overlays = [
(self: super: {
signal-desktop =
bleedingpkgs.legacyPackages.${self.system}.signal-desktop;
})
];
}
];
};
adrastea = nixpkgs.lib.nixosSystem {
specialArgs = { inherit inputs; };
system = "x86_64-linux";
modules = [
./hosts/adrastea
./modules/nixos/gaming
./modules/nixos/audio
./modules/nixos/networking
./modules/nixos/fonts
./modules/nixos/greeter
catppuccin.nixosModules.catppuccin
lix-module.nixosModules.default
# lanzaboote.nixosModules.lanzaboote
home-manager.nixosModules.home-manager
{
home-manager.useGlobalPkgs = true;
home-manager.useUserPackages = true;
home-manager.backupFileExtension = "backup";
home-manager.users.youwen = {
imports = [
./users/youwen/linux/laptop
./users/youwen/linux/packages/x86_64
./users/youwen/linux/programs
./users/youwen/common
./users/youwen/common/neofetch
./hosts/adrastea/home-manager-overrides.nix
inputs.catppuccin.homeManagerModules.catppuccin
];
};
}
];
};
};
formatter.aarch64-darwin = nixpkgs.legacyPackages.aarch64-darwin.nixfmt;
formatter.aarch64-linux = nixpkgs.legacyPackages.aarch64-linux.nixfmt;
# Build darwin flake using:
# $ darwin-rebuild build --flake .#Youwens-MacBook-Pro
darwinConfigurations.phobos = nix-darwin.lib.darwinSystem {
specialArgs = { inherit inputs; };
modules = [ modules = [
./hosts/phobos ./hosts/demeter
home-manager.darwinModules.home-manager ];
{ };
home-manager.useGlobalPkgs = true;
home-manager.useUserPackages = true;
home-manager.users.youwen.imports = [
./users/youwen/darwin/darwin-home.nix
./users/youwen/common/core.nix
./users/youwen/common/neofetch
];
home-manager.backupFileExtension = "backup";
# Optionally, use home-manager.extraSpecialArgs to pass callisto = nixpkgs.lib.nixosSystem {
# arguments to home.nix specialArgs = {
} inherit inputs;
nix-homebrew.darwinModules.nix-homebrew system = "aarch64-linux";
./modules/darwin/homebrew.nix };
./modules/darwin/yabai.nix modules = [
./modules/darwin/skhd.nix ./hosts/callisto
];
};
adrastea = nixpkgs.lib.nixosSystem {
specialArgs = {
inherit inputs;
system = "x86_64-linux";
};
modules = [
./hosts/adrastea
]; ];
}; };
}; };
darwinConfigurations.phobos = nix-darwin.lib.darwinSystem {
specialArgs = {inherit inputs;};
modules = [
./hosts/phobos
];
};
};
} }

190
hosts/adrastea/configuration.nix Executable file
View file

@ -0,0 +1,190 @@
# Edit this configuration file to define what should be installed on
# your system. Help is available in the configuration.nix(5) man page
# and in the NixOS manual (accessible by running nixos-help).
{
config,
inputs,
pkgs,
lib,
...
}: {
imports = [
# Include the results of the hardware scan.
./hardware-configuration.nix
];
# Bootloader.
boot.loader = {
efi.canTouchEfiVariables = true;
timeout = 15;
# Lanzaboote currently replaces the systemd-boot module.
# This setting is usually set to true in configuration.nix
# generated at installation time. So we force it to false
# for now.
systemd-boot = {
enable = true;
consoleMode = "auto";
};
};
# boot.lanzaboote = {
# enable = false;
# pkiBundle = "/etc/secureboot";
# };
services.keyd = {
enable = true;
keyboards = {
default = {
ids = ["*"];
settings = {
main = {
capslock = "esc";
leftalt = "leftcontrol";
leftcontrol = "leftalt";
};
};
};
};
};
boot.initrd.luks.devices."luks-52d1be6d-b32f-41e0-a6d7-2ff52599fe7c".device = "/dev/disk/by-uuid/52d1be6d-b32f-41e0-a6d7-2ff52599fe7c";
services.tlp.enable = true;
networking.hostName = "adrastea"; # Define your hostname.
# networking.wireless.enable = true; # Enables wireless support via wpa_supplicant.
# select kernel
boot.kernelPackages = pkgs.linuxPackages_zen;
# Configure network proxy if necessary
# networking.proxy.default = "http://user:password@proxy:port/";
# networking.proxy.noProxy = "127.0.0.1,localhost,internal.domain";
# Enable networking
networking.networkmanager.enable = true;
# Set your time zone.
time.timeZone = "America/Los_Angeles";
# Select internationalisation properties.
i18n.defaultLocale = "en_US.UTF-8";
i18n.extraLocaleSettings = {
LC_ADDRESS = "en_US.UTF-8";
LC_IDENTIFICATION = "en_US.UTF-8";
LC_MEASUREMENT = "en_US.UTF-8";
LC_MONETARY = "en_US.UTF-8";
LC_NAME = "en_US.UTF-8";
LC_NUMERIC = "en_US.UTF-8";
LC_PAPER = "en_US.UTF-8";
LC_TELEPHONE = "en_US.UTF-8";
LC_TIME = "en_US.UTF-8";
};
systemd.services = {NetworkManager-wait-online.enable = false;};
# Enable the X11 windowing system.
# You can disable this if you're only using the Wayland session.
services.xserver.enable = false;
programs.nix-ld = {
enable = true;
libraries = with pkgs; [icu xorg.libXtst xorg.libXi];
};
hardware.nvidia = {
modesetting.enable = true;
powerManagement.enable = true;
powerManagement.finegrained = false;
open = false;
nvidiaSettings = true;
prime = {
amdgpuBusId = "PCI:4:0:0";
nvidiaBusId = "PCI:1:0:0";
offload = {
enable = true;
enableOffloadCmd = true;
};
};
};
hardware.graphics.enable = true;
hardware.nvidia.package = config.boot.kernelPackages.nvidiaPackages.stable;
services.xserver.videoDrivers = ["nvidia"];
# services.desktopManager.plasma6.enable = true;
# Configure keymap in X11
services.xserver = {
xkb.layout = "us";
xkb.variant = "";
};
# Enable CUPS to print documents.
services.printing.enable = true;
# Enable touchpad support (enabled default in most desktopManager).
# services.xserver.libinput.enable = true;
# Define a user account. Don't forget to set a password with passwd.
users.users.youwen = {
isNormalUser = true;
description = "Youwen Wu";
extraGroups = ["networkmanager"];
};
nix.settings = {
trusted-users = ["root" "youwen"];
experimental-features = ["nix-command" "flakes"];
};
services.udev.extraRules = ''
KERNEL=="cpu_dma_latency", GROUP="realtime"
'';
# Allow unfree packages
nixpkgs.config.allowUnfree = true;
# List packages installed in system profile. To search, run:
# $ nix search wget
environment.systemPackages = with pkgs; [
wget
git
curl
];
environment.variables = {
EDITOR = "nvim";
NIX_AUTO_RUN = 1;
};
# tells electron apps to use Wayland
environment.sessionVariables.NIXOS_OZONE_WL = "1";
# Some programs need SUID wrappers, can be configured further or are
# started in user sessions.
# programs.mtr.enable = true;
programs.gnupg.agent = {
enable = true;
enableSSHSupport = true;
};
programs.dconf.enable = true;
programs.hyprland.enable = true;
programs.zsh.enable = false;
programs.fish.enable = true;
users.users.youwen.shell = pkgs.fish;
# This value determines the NixOS release from which the default
# settings for stateful data, like file locations and database versions
# on your system were taken. Its perfectly fine and recommended to leave
# this value at the release version of the first install of this system.
# Before changing this value read the documentation for this option
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
system.stateVersion = "24.05"; # Did you read the comment?
}

254
hosts/adrastea/default.nix Executable file → Normal file
View file

@ -1,228 +1,40 @@
# Edit this configuration file to define what should be installed on
# your system. Help is available in the configuration.nix(5) man page
# and in the NixOS manual (accessible by running nixos-help).
{ config, inputs, pkgs, lib, ... }:
{ {
imports = [ # Include the results of the hardware scan. inputs,
./hardware-configuration.nix system,
]; ...
}: {
imports = with inputs; [
./configuration.nix
../../modules/linux/gaming
../../modules/linux/audio
../../modules/linux/networking
../../modules/linux/fonts
../../modules/linux/greeter
../../modules/linux/core
../../overlays
# Bootloader. catppuccin.nixosModules.catppuccin
boot.loader = { lix-module.nixosModules.default
efi.canTouchEfiVariables = true; home-manager.nixosModules.home-manager
timeout = 15; {
# Lanzaboote currently replaces the systemd-boot module. home-manager.useGlobalPkgs = true;
# This setting is usually set to true in configuration.nix home-manager.useUserPackages = true;
# generated at installation time. So we force it to false home-manager.backupFileExtension = "backup";
# for now. home-manager.extraSpecialArgs = {
systemd-boot = { inherit inputs;
enable = true; inherit system;
consoleMode = "auto";
};
};
# boot.lanzaboote = {
# enable = false;
# pkiBundle = "/etc/secureboot";
# };
services.keyd = {
enable = true;
keyboards = {
default = {
ids = [ "*" ];
settings = {
main = {
capslock = "esc";
leftalt = "leftcontrol";
leftcontrol = "leftalt";
};
};
}; };
}; home-manager.users.youwen = {
}; imports = [
./home-manager-extras
boot.initrd.luks.devices."luks-52d1be6d-b32f-41e0-a6d7-2ff52599fe7c".device = ../../users/youwen/linux/laptop
"/dev/disk/by-uuid/52d1be6d-b32f-41e0-a6d7-2ff52599fe7c"; ../../users/youwen/linux/packages/x86_64
../../users/youwen/linux/programs
services.tlp.enable = true; ../../users/youwen/common
../../users/youwen/common/neofetch
networking.hostName = "adrastea"; # Define your hostname. catppuccin.homeManagerModules.catppuccin
# networking.wireless.enable = true; # Enables wireless support via wpa_supplicant. ];
# select kernel
boot.kernelPackages = pkgs.linuxPackages_zen;
# Configure network proxy if necessary
# networking.proxy.default = "http://user:password@proxy:port/";
# networking.proxy.noProxy = "127.0.0.1,localhost,internal.domain";
# Enable networking
networking.networkmanager.enable = true;
# Set your time zone.
time.timeZone = "America/Los_Angeles";
# Select internationalisation properties.
i18n.defaultLocale = "en_US.UTF-8";
i18n.extraLocaleSettings = {
LC_ADDRESS = "en_US.UTF-8";
LC_IDENTIFICATION = "en_US.UTF-8";
LC_MEASUREMENT = "en_US.UTF-8";
LC_MONETARY = "en_US.UTF-8";
LC_NAME = "en_US.UTF-8";
LC_NUMERIC = "en_US.UTF-8";
LC_PAPER = "en_US.UTF-8";
LC_TELEPHONE = "en_US.UTF-8";
LC_TIME = "en_US.UTF-8";
};
systemd.services = { NetworkManager-wait-online.enable = false; };
# Enable the X11 windowing system.
# You can disable this if you're only using the Wayland session.
services.xserver.enable = false;
programs.nix-ld = {
enable = true;
libraries = with pkgs; [ icu xorg.libXtst xorg.libXi ];
};
hardware.nvidia = {
modesetting.enable = true;
powerManagement.enable = true;
powerManagement.finegrained = false;
open = false;
nvidiaSettings = true;
prime = {
amdgpuBusId = "PCI:4:0:0";
nvidiaBusId = "PCI:1:0:0";
offload = {
enable = true;
enableOffloadCmd = true;
}; };
};
};
hardware.graphics.enable = true;
hardware.nvidia.package = config.boot.kernelPackages.nvidiaPackages.stable;
services.xserver.videoDrivers = [ "nvidia" ];
# services.desktopManager.plasma6.enable = true;
# Configure keymap in X11
services.xserver = {
xkb.layout = "us";
xkb.variant = "";
};
# Enable CUPS to print documents.
services.printing.enable = true;
# Enable touchpad support (enabled default in most desktopManager).
# services.xserver.libinput.enable = true;
# Define a user account. Don't forget to set a password with passwd.
users.users.youwen = {
isNormalUser = true;
description = "Youwen Wu";
extraGroups = [ "networkmanager" "wheel" "nixos" "realtime" ];
};
users.groups.realtime = { };
nix.settings = {
trusted-users = [ "root" "youwen" ];
experimental-features = [ "nix-command" "flakes" ];
};
services.udev.extraRules = ''
KERNEL=="cpu_dma_latency", GROUP="realtime"
'';
security.pam.loginLimits = [
{
domain = "@realtime";
type = "-";
item = "rtprio";
value = 98;
}
{
domain = "@realtime";
type = "-";
item = "memlock";
value = "unlimited";
}
{
domain = "@realtime";
type = "-";
item = "nice";
value = -11;
} }
]; ];
# Allow unfree packages
nixpkgs.config.allowUnfree = true;
# List packages installed in system profile. To search, run:
# $ nix search wget
environment.systemPackages = with pkgs; [
neovim
wget
git
curl
librewolf
gnumake
clang
gcc
cachix
nodejs_22
cargo
rustc
gnupg
openssh
python3
steam-run
# deps for neovim compilation
lua51Packages.lua
lua51Packages.luarocks
tree-sitter
];
environment.variables = {
EDITOR = "nvim";
NIX_AUTO_RUN = 1;
};
# tells electron apps to use Wayland
environment.sessionVariables.NIXOS_OZONE_WL = "1";
# Some programs need SUID wrappers, can be configured further or are
# started in user sessions.
# programs.mtr.enable = true;
programs.gnupg.agent = {
enable = true;
enableSSHSupport = true;
};
programs.dconf.enable = true;
programs.hyprland.enable = true;
programs.zsh.enable = false;
programs.fish.enable = true;
users.users.youwen.shell = pkgs.fish;
# This value determines the NixOS release from which the default
# settings for stateful data, like file locations and database versions
# on your system were taken. Its perfectly fine and recommended to leave
# this value at the release version of the first install of this system.
# Before changing this value read the documentation for this option
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
system.stateVersion = "24.05"; # Did you read the comment?
} }

View file

@ -1,33 +1,34 @@
# Do not modify this file! It was generated by nixos-generate-config # Do not modify this file! It was generated by nixos-generate-config
# and may be overwritten by future invocations. Please make changes # and may be overwritten by future invocations. Please make changes
# to /etc/nixos/configuration.nix instead. # to /etc/nixos/configuration.nix instead.
{ config, lib, pkgs, modulesPath, ... }:
{ {
imports = [ (modulesPath + "/installer/scan/not-detected.nix") ]; config,
lib,
pkgs,
modulesPath,
...
}: {
imports = [(modulesPath + "/installer/scan/not-detected.nix")];
boot.initrd.availableKernelModules = boot.initrd.availableKernelModules = ["nvme" "xhci_pci" "usbhid" "usb_storage" "sd_mod"];
[ "nvme" "xhci_pci" "usbhid" "usb_storage" "sd_mod" ]; boot.initrd.kernelModules = [];
boot.initrd.kernelModules = [ ]; boot.kernelModules = ["kvm-amd"];
boot.kernelModules = [ "kvm-amd" ]; boot.extraModulePackages = [];
boot.extraModulePackages = [ ];
fileSystems."/" = { fileSystems."/" = {
device = "/dev/disk/by-uuid/01983a52-5693-4cda-ad2e-5a406776bfb9"; device = "/dev/disk/by-uuid/01983a52-5693-4cda-ad2e-5a406776bfb9";
fsType = "ext4"; fsType = "ext4";
}; };
boot.initrd.luks.devices."luks-f169a679-d70b-4dff-a344-7131f3303813".device = boot.initrd.luks.devices."luks-f169a679-d70b-4dff-a344-7131f3303813".device = "/dev/disk/by-uuid/f169a679-d70b-4dff-a344-7131f3303813";
"/dev/disk/by-uuid/f169a679-d70b-4dff-a344-7131f3303813";
fileSystems."/boot" = { fileSystems."/boot" = {
device = "/dev/disk/by-uuid/3FCB-9D60"; device = "/dev/disk/by-uuid/3FCB-9D60";
fsType = "vfat"; fsType = "vfat";
options = [ "fmask=0022" "dmask=0022" ]; options = ["fmask=0022" "dmask=0022"];
}; };
swapDevices = swapDevices = [{device = "/dev/disk/by-uuid/f28d0752-feab-4591-899e-e5deac3712d0";}];
[{ device = "/dev/disk/by-uuid/f28d0752-feab-4591-899e-e5deac3712d0"; }];
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking # Enables DHCP on each ethernet and wireless interface. In case of scripted networking
# (the default) this is the recommended approach. When using systemd-networkd it's # (the default) this is the recommended approach. When using systemd-networkd it's

View file

@ -1,4 +1,3 @@
{ pkgs, ... }: {pkgs, ...}: {
{ wayland.windowManager.hyprland.settings.monitor = pkgs.lib.mkForce ["eDP-1,2560x1440@165,0x0,1.6"];
wayland.windowManager.hyprland.settings.monitor = pkgs.lib.mkForce [ "eDP-1,2560x1440@165,0x0,1.6" ];
} }

View file

@ -0,0 +1,15 @@
diff --git a/src/protocols/LinuxDMABUF.cpp b/src/protocols/LinuxDMABUF.cpp
index 0fbf832e..c6077114 100644
--- a/src/protocols/LinuxDMABUF.cpp
+++ b/src/protocols/LinuxDMABUF.cpp
@@ -492,9 +492,8 @@ CLinuxDMABufV1Protocol::CLinuxDMABufV1Protocol(const wl_interface* iface, const
return;
}
} else {
- protoLog(ERR, "DRM device {} has no render node, disabling linux dmabuf", device->nodes[DRM_NODE_PRIMARY] ? device->nodes[DRM_NODE_PRIMARY] : "null");
+ protoLog(ERR, "DRM device {} has no render node, disabling linux dmabuf checks", device->nodes[DRM_NODE_PRIMARY] ? device->nodes[DRM_NODE_PRIMARY] : "null");
drmFreeDevice(&device);
- removeGlobal();
}
});
}

231
hosts/callisto/configuration.nix Executable file
View file

@ -0,0 +1,231 @@
# Edit this configuration file to define what should be installed on
# your system. Help is available in the configuration.nix(5) man page
# and in the NixOS manual (accessible by running nixos-help).
{
config,
inputs,
pkgs,
...
}: {
imports = [
# Include the results of the hardware scan.
./hardware-configuration.nix
# ./apple-silicon-support
];
boot.loader.systemd-boot.enable = true;
boot.loader.efi.canTouchEfiVariables = false;
hardware.asahi = {
peripheralFirmwareDirectory = ./firmware;
useExperimentalGPUDriver = true;
experimentalGPUInstallMode = "overlay";
};
boot.extraModprobeConfig = ''
options hid_apple iso_layout=0
'';
boot.kernelParams = ["apple_dcp.show_notch=1"];
networking.hostName = "callisto"; # Define your hostname.
# networking.wireless.enable = true; # Enables wireless support via wpa_supplicant.
networking.wireless.iwd = {
enable = true;
settings.General.EnableNetworkConfiguration = true;
};
nixpkgs.overlays = let
stablepkgs = inputs.stablepkgs.legacyPackages.${pkgs.system};
in [
inputs.apple-silicon.overlays.apple-silicon-overlay
(final: prev: {
hyprland = prev.hyprland.overrideAttrs (oldAttrs: {
src = oldAttrs.src;
patches =
oldAttrs.patches
or []
++ [
./0001-linux-dmabuf-allow-on-split-node-systems.patch
];
});
vesktop = with pkgs; let
pname = "vesktop";
version = "1.5.3";
src = fetchurl {
url = "https://github.com/Vencord/Vesktop/releases/download/v${version}/${pname}-${version}-arm64.AppImage";
hash = "sha256-4F1oR2nc54EZ2heGVkz4vqZzmwn0exa2+AcYHpeTb98=";
};
appimageContents = appimageTools.extract {
inherit pname version src;
};
desktopItem = makeDesktopItem {
name = pname;
desktopName = "Vesktop";
exec = "vesktop %U --ozone-platform-hint=wayland --enable-features=WaylandWindowDecorations --enable-wayland-ime";
icon = "vesktop";
startupWMClass = "Vesktop";
genericName = "Internet Messenger";
keywords = [
"discord"
];
categories = [
"Network"
"InstantMessaging"
"Chat"
];
};
in
appimageTools.wrapType2 {
inherit pname version src;
extraInstallCommands = ''
mkdir -p $out/share
cp -rt $out/share ${desktopItem}/share/applications ${appimageContents}/usr/share/icons
chmod -R +w $out/share
mv $out/share/icons/hicolor/{16x16,256x256}
'';
};
})
];
programs.light.enable = true;
# Configure network proxy if necessary
# networking.proxy.default = "http://user:password@proxy:port/";
# networking.proxy.noProxy = "127.0.0.1,localhost,internal.domain";
# Enable networking
# networking.networkmanager.enable = true;
# Set your time zone.
time.timeZone = "America/Los_Angeles";
# Select internationalisation properties.
i18n.defaultLocale = "en_US.UTF-8";
i18n.extraLocaleSettings = {
LC_ADDRESS = "en_US.UTF-8";
LC_IDENTIFICATION = "en_US.UTF-8";
LC_MEASUREMENT = "en_US.UTF-8";
LC_MONETARY = "en_US.UTF-8";
LC_NAME = "en_US.UTF-8";
LC_NUMERIC = "en_US.UTF-8";
LC_PAPER = "en_US.UTF-8";
LC_TELEPHONE = "en_US.UTF-8";
LC_TIME = "en_US.UTF-8";
};
# Enable the X11 windowing system.
# You can disable this if you're only using the Wayland session.
services.xserver.enable = false;
programs.nix-ld = {
enable = true;
libraries = with pkgs; [icu xorg.libXtst xorg.libXi];
};
# Configure keymap in X11
services.xserver = {
xkb.layout = "us";
xkb.variant = "";
};
# Enable CUPS to print documents.
services.printing.enable = true;
# Enable touchpad support (enabled default in most desktopManager).
# services.xserver.libinput.enable = true;
# Define a user account. Don't forget to set a password with passwd.
users.users.youwen = {
isNormalUser = true;
description = "Youwen Wu";
extraGroups = ["networkmanager"];
};
nix.settings = {
trusted-users = ["root" "youwen"];
experimental-features = ["nix-command" "flakes"];
};
services.udev.extraRules = ''
KERNEL=="cpu_dma_latency", GROUP="realtime"
KERNEL=="macsmc-battery", SUBSYSTEM=="power_supply", ATTR{charge_control_end_threshold}="80", ATTR{charge_control_start_threshold}="70"
'';
# Allow unfree packages
nixpkgs.config.allowUnfree = true;
# List packages installed in system profile. To search, run:
# $ nix search wget
environment.systemPackages = with pkgs; [
wget
git
curl
];
environment.variables = {
EDITOR = "nvim";
NIX_AUTO_RUN = 1;
};
services.keyd = {
enable = true;
keyboards = {
default = {
ids = ["*"];
settings = {
main = {
capslock = "esc";
leftmeta = "leftcontrol";
leftalt = "leftmeta";
leftcontrol = "leftalt";
rightmeta = "leftalt";
rightalt = "layer(rightalt)";
};
rightalt = {
i = "up";
j = "left";
k = "down";
l = "right";
};
};
};
};
};
services.tlp.enable = true;
# tells electron apps to use Wayland
environment.sessionVariables.NIXOS_OZONE_WL = "1";
# Some programs need SUID wrappers, can be configured further or are
# started in user sessions.
# programs.mtr.enable = true;
programs.gnupg.agent = {
enable = true;
enableSSHSupport = true;
};
programs.dconf.enable = true;
programs.hyprland.enable = true;
# programs.hyprland.package = inputs.stablepkgs.legacyPackages.${pkgs.stdenv.hostPlatform.system}.hyprland;
# This value determines the NixOS release from which the default
# settings for stateful data, like file locations and database versions
# on your system were taken. Its perfectly fine and recommended to leave
# this value at the release version of the first install of this system.
# Before changing this value read the documentation for this option
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
system.stateVersion = "24.11"; # Did you read the comment?
programs.zsh.enable = false;
programs.fish.enable = true;
users.users.youwen.shell = pkgs.fish;
}

241
hosts/callisto/default.nix Executable file → Normal file
View file

@ -1,213 +1,38 @@
# Edit this configuration file to define what should be installed on
# your system. Help is available in the configuration.nix(5) man page
# and in the NixOS manual (accessible by running nixos-help).
{ config, inputs, pkgs, ... }:
{ {
imports = [ # Include the results of the hardware scan. inputs,
./hardware-configuration.nix system,
# ./apple-silicon-support ...
]; }: {
imports = with inputs; [
./configuration.nix
../../modules/linux/audio
../../modules/linux/networking
../../modules/linux/fonts
../../modules/linux/greeter
../../modules/linux/core
../../overlays
boot.loader.systemd-boot.enable = true; apple-silicon.nixosModules.apple-silicon-support
boot.loader.efi.canTouchEfiVariables = false; catppuccin.nixosModules.catppuccin
lix-module.nixosModules.default
hardware.asahi = { home-manager.nixosModules.home-manager
peripheralFirmwareDirectory = ./firmware;
useExperimentalGPUDriver = true;
experimentalGPUInstallMode = "overlay";
};
boot.extraModprobeConfig = ''
options hid_apple iso_layout=0
'';
boot.kernelParams = [ "apple_dcp.show_notch=1" ];
networking.hostName = "callisto"; # Define your hostname.
# networking.wireless.enable = true; # Enables wireless support via wpa_supplicant.
networking.wireless.iwd = {
enable = true;
settings.General.EnableNetworkConfiguration = true;
};
nixpkgs.overlays = [ inputs.apple-silicon.overlays.apple-silicon-overlay ];
programs.light.enable = true;
# Configure network proxy if necessary
# networking.proxy.default = "http://user:password@proxy:port/";
# networking.proxy.noProxy = "127.0.0.1,localhost,internal.domain";
# Enable networking
# networking.networkmanager.enable = true;
# Set your time zone.
time.timeZone = "America/Los_Angeles";
# Select internationalisation properties.
i18n.defaultLocale = "en_US.UTF-8";
i18n.extraLocaleSettings = {
LC_ADDRESS = "en_US.UTF-8";
LC_IDENTIFICATION = "en_US.UTF-8";
LC_MEASUREMENT = "en_US.UTF-8";
LC_MONETARY = "en_US.UTF-8";
LC_NAME = "en_US.UTF-8";
LC_NUMERIC = "en_US.UTF-8";
LC_PAPER = "en_US.UTF-8";
LC_TELEPHONE = "en_US.UTF-8";
LC_TIME = "en_US.UTF-8";
};
# Enable the X11 windowing system.
# You can disable this if you're only using the Wayland session.
services.xserver.enable = false;
programs.nix-ld = {
enable = true;
libraries = with pkgs; [ icu xorg.libXtst xorg.libXi ];
};
# Configure keymap in X11
services.xserver = {
xkb.layout = "us";
xkb.variant = "";
};
# Enable CUPS to print documents.
services.printing.enable = true;
# Enable touchpad support (enabled default in most desktopManager).
# services.xserver.libinput.enable = true;
# Define a user account. Don't forget to set a password with passwd.
users.users.youwen = {
isNormalUser = true;
description = "Youwen Wu";
extraGroups = [ "networkmanager" "wheel" "nixos" "realtime" ];
};
users.groups.realtime = { };
nix.settings = {
trusted-users = [ "root" "youwen" ];
experimental-features = [ "nix-command" "flakes" ];
};
services.udev.extraRules = ''
KERNEL=="cpu_dma_latency", GROUP="realtime"
KERNEL=="macsmc-battery", SUBSYSTEM=="power_supply", ATTR{charge_control_end_threshold}="80", ATTR{charge_control_start_threshold}="70"
'';
security.pam.loginLimits = [
{ {
domain = "@realtime"; home-manager.useGlobalPkgs = true;
type = "-"; home-manager.useUserPackages = true;
item = "rtprio"; home-manager.backupFileExtension = "backup";
value = 98; home-manager.extraSpecialArgs = {
} inherit inputs;
{ inherit system;
domain = "@realtime";
type = "-";
item = "memlock";
value = "unlimited";
}
{
domain = "@realtime";
type = "-";
item = "nice";
value = -11;
}
];
# Allow unfree packages
nixpkgs.config.allowUnfree = true;
# List packages installed in system profile. To search, run:
# $ nix search wget
environment.systemPackages = with pkgs; [
neovim
wget
git
curl
# librewolf
# gnumake
# clang
# gcc
# cachix
# nodejs_22
# cargo
# rustc
# gnupg
# openssh
# python3
# steam-run
# # deps for neovim compilation
# lua51Packages.lua
# lua51Packages.luarocks
# tree-sitter
];
environment.variables = {
EDITOR = "nvim";
NIX_AUTO_RUN = 1;
};
services.keyd = {
enable = true;
keyboards = {
default = {
ids = [ "*" ];
settings = {
main = {
capslock = "esc";
leftmeta = "leftcontrol";
leftalt = "leftmeta";
leftcontrol = "leftalt";
rightmeta = "leftalt";
rightalt = "layer(rightalt)";
};
rightalt = {
i = "up";
j = "left";
k = "down";
l = "right";
};
};
}; };
}; home-manager.users.youwen = {
}; imports = [
../../users/youwen/common
services.tlp.enable = true; ../../users/youwen/linux/laptop
../../users/youwen/linux/packages/aarch-64
# tells electron apps to use Wayland ./home-manager-extras
environment.sessionVariables.NIXOS_OZONE_WL = "1"; catppuccin.homeManagerModules.catppuccin
];
# Some programs need SUID wrappers, can be configured further or are };
# started in user sessions. }
# programs.mtr.enable = true; ];
programs.gnupg.agent = {
enable = true;
enableSSHSupport = true;
};
programs.dconf.enable = true;
programs.hyprland.enable = true;
# This value determines the NixOS release from which the default
# settings for stateful data, like file locations and database versions
# on your system were taken. Its perfectly fine and recommended to leave
# this value at the release version of the first install of this system.
# Before changing this value read the documentation for this option
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
system.stateVersion = "24.11"; # Did you read the comment?
programs.zsh.enable = false;
programs.fish.enable = true;
users.users.youwen.shell = pkgs.fish;
} }

28
hosts/callisto/hardware-configuration.nix Executable file → Normal file
View file

@ -1,28 +1,36 @@
# Do not modify this file! It was generated by nixos-generate-config # Do not modify this file! It was generated by nixos-generate-config
# and may be overwritten by future invocations. Please make changes # and may be overwritten by future invocations. Please make changes
# to /etc/nixos/configuration.nix instead. # to /etc/nixos/configuration.nix instead.
{ config, lib, pkgs, modulesPath, ... }:
{ {
imports = [ (modulesPath + "/installer/scan/not-detected.nix") ]; config,
lib,
pkgs,
modulesPath,
...
}: {
imports = [
(modulesPath + "/installer/scan/not-detected.nix")
];
boot.initrd.availableKernelModules = [ "usb_storage" "sdhci_pci" ]; boot.initrd.availableKernelModules = ["usb_storage" "sdhci_pci"];
boot.initrd.kernelModules = [ ]; boot.initrd.kernelModules = [];
boot.kernelModules = [ ]; boot.kernelModules = [];
boot.extraModulePackages = [ ]; boot.extraModulePackages = [];
fileSystems."/" = { fileSystems."/" = {
device = "/dev/disk/by-uuid/bc88058e-6e3a-4987-b78e-e19cb5611608"; device = "/dev/mapper/crypted";
fsType = "ext4"; fsType = "ext4";
}; };
boot.initrd.luks.devices."crypted".device = "/dev/disk/by-uuid/f4c552be-a4c2-4ca0-aec6-ed692d78fe24";
fileSystems."/boot" = { fileSystems."/boot" = {
device = "/dev/disk/by-uuid/852F-07F1"; device = "/dev/disk/by-uuid/852F-07F1";
fsType = "vfat"; fsType = "vfat";
options = [ "fmask=0022" "dmask=0022" ]; options = ["fmask=0022" "dmask=0022"];
}; };
swapDevices = [ ]; swapDevices = [];
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking # Enables DHCP on each ethernet and wireless interface. In case of scripted networking
# (the default) this is the recommended approach. When using systemd-networkd it's # (the default) this is the recommended approach. When using systemd-networkd it's

View file

@ -0,0 +1,4 @@
{pkgs, ...}: {
wayland.windowManager.hyprland.package = pkgs.lib.mkForce pkgs.hyprland;
home.file.".config/neofetch/config.conf".source = ./neofetch-asahi.conf;
}

173
hosts/demeter/configuration.nix Executable file
View file

@ -0,0 +1,173 @@
# Edit this configuration file to define what should be installed on
# your system. Help is available in the configuration.nix(5) man page
# and in the NixOS manual (accessible by running nixos-help).
{
config,
inputs,
pkgs,
lib,
...
}: {
imports = [
# Include the results of the hardware scan.
./hardware-configuration.nix
];
# Bootloader.
boot.loader = {
efi.canTouchEfiVariables = true;
timeout = 15;
# Lanzaboote currently replaces the systemd-boot module.
# This setting is usually set to true in configuration.nix
# generated at installation time. So we force it to false
# for now.
systemd-boot = {
enable = false;
consoleMode = "auto";
};
};
boot.lanzaboote = {
enable = true;
pkiBundle = "/etc/secureboot";
};
boot.initrd.luks.devices."luks-af320a0f-b388-43f5-b5a3-af2b47cfc716".device = "/dev/disk/by-uuid/af320a0f-b388-43f5-b5a3-af2b47cfc716";
networking.hostName = "demeter"; # Define your hostname.
# networking.wireless.enable = true; # Enables wireless support via wpa_supplicant.
# select kernel
boot.kernelPackages = pkgs.linuxPackages_zen;
# Configure network proxy if necessary
# networking.proxy.default = "http://user:password@proxy:port/";
# networking.proxy.noProxy = "127.0.0.1,localhost,internal.domain";
# Enable networking
networking.networkmanager.enable = true;
# Set your time zone.
time.timeZone = "America/Los_Angeles";
# Select internationalisation properties.
i18n.defaultLocale = "en_US.UTF-8";
i18n.extraLocaleSettings = {
LC_ADDRESS = "en_US.UTF-8";
LC_IDENTIFICATION = "en_US.UTF-8";
LC_MEASUREMENT = "en_US.UTF-8";
LC_MONETARY = "en_US.UTF-8";
LC_NAME = "en_US.UTF-8";
LC_NUMERIC = "en_US.UTF-8";
LC_PAPER = "en_US.UTF-8";
LC_TELEPHONE = "en_US.UTF-8";
LC_TIME = "en_US.UTF-8";
};
systemd.services = {NetworkManager-wait-online.enable = false;};
# Enable the X11 windowing system.
# You can disable this if you're only using the Wayland session.
services.xserver.enable = false;
programs.nix-ld = {
enable = true;
libraries = with pkgs; [icu xorg.libXtst xorg.libXi];
};
hardware.nvidia = {
modesetting.enable = true;
powerManagement.enable = true;
powerManagement.finegrained = false;
open = false;
nvidiaSettings = true;
};
hardware.bluetooth = {
enable = true;
powerOnBoot = true;
};
services.blueman.enable = true;
hardware.graphics.enable = true;
hardware.nvidia.package = config.boot.kernelPackages.nvidiaPackages.stable;
services.xserver.videoDrivers = ["nvidia"];
services.flatpak.enable = true;
# services.desktopManager.plasma6.enable = true;
# Configure keymap in X11
services.xserver = {
xkb.layout = "us";
xkb.variant = "";
};
# Enable CUPS to print documents.
services.printing.enable = true;
# Enable touchpad support (enabled default in most desktopManager).
# services.xserver.libinput.enable = true;
# Define a user account. Don't forget to set a password with passwd.
users.users.youwen = {
isNormalUser = true;
description = "Youwen Wu";
extraGroups = ["networkmanager"];
};
nix.settings = {
trusted-users = ["root" "youwen"];
experimental-features = ["nix-command" "flakes"];
};
services.udev.extraRules = ''
KERNEL=="cpu_dma_latency", GROUP="realtime"
'';
# Allow unfree packages
nixpkgs.config.allowUnfree = true;
# List packages installed in system profile. To search, run:
# $ nix search wget
environment.systemPackages = with pkgs; [
wget
git
curl
];
environment.variables = {
EDITOR = "nvim";
NIX_AUTO_RUN = 1;
};
# tells electron apps to use Wayland
environment.sessionVariables.NIXOS_OZONE_WL = "1";
# Some programs need SUID wrappers, can be configured further or are
# started in user sessions.
# programs.mtr.enable = true;
programs.gnupg.agent = {
enable = true;
enableSSHSupport = true;
};
programs.dconf.enable = true;
programs.hyprland.enable = true;
programs.zsh.enable = false;
programs.fish.enable = true;
users.users.youwen.shell = pkgs.fish;
# This value determines the NixOS release from which the default
# settings for stateful data, like file locations and database versions
# on your system were taken. Its perfectly fine and recommended to leave
# this value at the release version of the first install of this system.
# Before changing this value read the documentation for this option
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
system.stateVersion = "24.05"; # Did you read the comment?
}

239
hosts/demeter/default.nix Executable file → Normal file
View file

@ -1,208 +1,43 @@
# Edit this configuration file to define what should be installed on
# your system. Help is available in the configuration.nix(5) man page
# and in the NixOS manual (accessible by running nixos-help).
{ config, inputs, pkgs, lib, ... }:
{ {
imports = [ # Include the results of the hardware scan. inputs,
./hardware-configuration.nix system,
]; ...
}: {
imports = with inputs; [
./configuration.nix
../../modules/linux/gaming
../../modules/linux/audio
../../modules/linux/networking
../../modules/linux/fonts
../../modules/linux/greeter
../../modules/linux/core
../../modules/linux/hamachi
../../overlays
# Bootloader. catppuccin.nixosModules.catppuccin
boot.loader = { lix-module.nixosModules.default
efi.canTouchEfiVariables = true; lanzaboote.nixosModules.lanzaboote
timeout = 15; home-manager.nixosModules.home-manager
# Lanzaboote currently replaces the systemd-boot module.
# This setting is usually set to true in configuration.nix
# generated at installation time. So we force it to false
# for now.
systemd-boot = {
enable = false;
consoleMode = "auto";
};
};
boot.lanzaboote = {
enable = true;
pkiBundle = "/etc/secureboot";
};
boot.initrd.luks.devices."luks-af320a0f-b388-43f5-b5a3-af2b47cfc716".device = "/dev/disk/by-uuid/af320a0f-b388-43f5-b5a3-af2b47cfc716";
networking.hostName = "demeter"; # Define your hostname.
# networking.wireless.enable = true; # Enables wireless support via wpa_supplicant.
# select kernel
boot.kernelPackages = pkgs.linuxPackages_zen;
# Configure network proxy if necessary
# networking.proxy.default = "http://user:password@proxy:port/";
# networking.proxy.noProxy = "127.0.0.1,localhost,internal.domain";
# Enable networking
networking.networkmanager.enable = true;
# Set your time zone.
time.timeZone = "America/Los_Angeles";
# Select internationalisation properties.
i18n.defaultLocale = "en_US.UTF-8";
i18n.extraLocaleSettings = {
LC_ADDRESS = "en_US.UTF-8";
LC_IDENTIFICATION = "en_US.UTF-8";
LC_MEASUREMENT = "en_US.UTF-8";
LC_MONETARY = "en_US.UTF-8";
LC_NAME = "en_US.UTF-8";
LC_NUMERIC = "en_US.UTF-8";
LC_PAPER = "en_US.UTF-8";
LC_TELEPHONE = "en_US.UTF-8";
LC_TIME = "en_US.UTF-8";
};
systemd.services = { NetworkManager-wait-online.enable = false; };
# Enable the X11 windowing system.
# You can disable this if you're only using the Wayland session.
services.xserver.enable = false;
programs.nix-ld = {
enable = true;
libraries = with pkgs; [ icu xorg.libXtst xorg.libXi ];
};
hardware.nvidia = {
modesetting.enable = true;
powerManagement.enable = true;
powerManagement.finegrained = false;
open = false;
nvidiaSettings = true;
};
hardware.bluetooth = {
enable = true;
powerOnBoot = true;
};
services.blueman.enable = true;
hardware.graphics.enable = true;
hardware.nvidia.package = config.boot.kernelPackages.nvidiaPackages.stable;
services.xserver.videoDrivers = [ "nvidia" ];
# services.desktopManager.plasma6.enable = true;
# Configure keymap in X11
services.xserver = {
xkb.layout = "us";
xkb.variant = "";
};
# Enable CUPS to print documents.
services.printing.enable = true;
# Enable touchpad support (enabled default in most desktopManager).
# services.xserver.libinput.enable = true;
# Define a user account. Don't forget to set a password with passwd.
users.users.youwen = {
isNormalUser = true;
description = "Youwen Wu";
extraGroups = [ "networkmanager" "wheel" "nixos" "realtime" ];
};
users.groups.realtime = { };
nix.settings = {
trusted-users = [ "root" "youwen" ];
experimental-features = [ "nix-command" "flakes" ];
};
services.udev.extraRules = ''
KERNEL=="cpu_dma_latency", GROUP="realtime"
'';
security.pam.loginLimits = [
{ {
domain = "@realtime"; home-manager.useGlobalPkgs = true;
type = "-"; home-manager.useUserPackages = true;
item = "rtprio"; home-manager.backupFileExtension = "backup";
value = 98; home-manager.extraSpecialArgs = {
} inherit inputs;
{ inherit system;
domain = "@realtime"; };
type = "-"; home-manager.users.youwen = {
item = "memlock"; imports = [
value = "unlimited"; ../../users/youwen/linux/desktop
} ../../users/youwen/linux/packages/x86_64
{ ../../users/youwen/linux/programs
domain = "@realtime"; ../../users/youwen/common/neofetch
type = "-"; ../../users/youwen/common
item = "nice"; ../../users/youwen/linux/spicetify
value = -11; ./home-manager-extras
catppuccin.homeManagerModules.catppuccin
];
};
} }
]; ];
# Allow unfree packages
nixpkgs.config.allowUnfree = true;
# List packages installed in system profile. To search, run:
# $ nix search wget
environment.systemPackages = with pkgs; [
neovim
wget
git
curl
librewolf
gnumake
clang
gcc
cachix
nodejs_22
cargo
rustc
gnupg
openssh
python3
steam-run
# deps for neovim compilation
lua51Packages.lua
lua51Packages.luarocks
tree-sitter
];
environment.variables = {
EDITOR = "nvim";
NIX_AUTO_RUN = 1;
};
# tells electron apps to use Wayland
environment.sessionVariables.NIXOS_OZONE_WL = "1";
# Some programs need SUID wrappers, can be configured further or are
# started in user sessions.
# programs.mtr.enable = true;
programs.gnupg.agent = {
enable = true;
enableSSHSupport = true;
};
programs.dconf.enable = true;
programs.hyprland.enable = true;
programs.zsh.enable = false;
programs.fish.enable = true;
users.users.youwen.shell = pkgs.fish;
# This value determines the NixOS release from which the default
# settings for stateful data, like file locations and database versions
# on your system were taken. Its perfectly fine and recommended to leave
# this value at the release version of the first install of this system.
# Before changing this value read the documentation for this option
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
system.stateVersion = "24.05"; # Did you read the comment?
} }

View file

@ -1,34 +1,38 @@
# Do not modify this file! It was generated by nixos-generate-config # Do not modify this file! It was generated by nixos-generate-config
# and may be overwritten by future invocations. Please make changes # and may be overwritten by future invocations. Please make changes
# to /etc/nixos/configuration.nix instead. # to /etc/nixos/configuration.nix instead.
{ config, lib, pkgs, modulesPath, ... }:
{ {
imports = config,
[ (modulesPath + "/installer/scan/not-detected.nix") lib,
]; pkgs,
modulesPath,
...
}: {
imports = [
(modulesPath + "/installer/scan/not-detected.nix")
];
boot.initrd.availableKernelModules = [ "xhci_pci" "ahci" "nvme" "usbhid" "usb_storage" "sd_mod" ]; boot.initrd.availableKernelModules = ["xhci_pci" "ahci" "nvme" "usbhid" "usb_storage" "sd_mod"];
boot.initrd.kernelModules = [ ]; boot.initrd.kernelModules = [];
boot.kernelModules = [ "kvm-intel" ]; boot.kernelModules = ["kvm-intel"];
boot.extraModulePackages = [ ]; boot.extraModulePackages = [];
fileSystems."/" = fileSystems."/" = {
{ device = "/dev/disk/by-uuid/5a339a7f-8668-42d7-9ecc-d7a8f1d3f7b2"; device = "/dev/disk/by-uuid/5a339a7f-8668-42d7-9ecc-d7a8f1d3f7b2";
fsType = "ext4"; fsType = "ext4";
}; };
boot.initrd.luks.devices."luks-362ec972-7c5e-4c9f-ba5d-b8f2ed083509".device = "/dev/disk/by-uuid/362ec972-7c5e-4c9f-ba5d-b8f2ed083509"; boot.initrd.luks.devices."luks-362ec972-7c5e-4c9f-ba5d-b8f2ed083509".device = "/dev/disk/by-uuid/362ec972-7c5e-4c9f-ba5d-b8f2ed083509";
fileSystems."/boot" = fileSystems."/boot" = {
{ device = "/dev/disk/by-uuid/27EE-D950"; device = "/dev/disk/by-uuid/27EE-D950";
fsType = "vfat"; fsType = "vfat";
options = [ "fmask=0022" "dmask=0022" ]; options = ["fmask=0022" "dmask=0022"];
}; };
swapDevices = swapDevices = [
[ { device = "/dev/disk/by-uuid/670fc084-d593-44b3-aed9-78d95fec71de"; } {device = "/dev/disk/by-uuid/670fc084-d593-44b3-aed9-78d95fec71de";}
]; ];
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking # Enables DHCP on each ethernet and wireless interface. In case of scripted networking
# (the default) this is the recommended approach. When using systemd-networkd it's # (the default) this is the recommended approach. When using systemd-networkd it's

View file

@ -1,39 +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" "ahci" "nvme" "usbhid" "usb_storage" "sd_mod" ];
boot.initrd.kernelModules = [ ];
boot.kernelModules = [ "kvm-intel" ];
boot.extraModulePackages = [ ];
fileSystems."/" = {
device = "/dev/disk/by-uuid/2616d86c-aac2-4780-9527-7b11192e783f";
fsType = "ext4";
};
fileSystems."/boot" = {
device = "/dev/disk/by-uuid/B826-E14B";
fsType = "vfat";
options = [ "fmask=0022" "dmask=0022" ];
};
swapDevices = [ ];
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
# (the default) this is the recommended approach. When using systemd-networkd it's
# still possible to use this option, but it's recommended to use it in conjunction
# with explicit per-interface declarations with `networking.interfaces.<interface>.useDHCP`.
networking.useDHCP = lib.mkDefault true;
# networking.interfaces.enp6s0.useDHCP = lib.mkDefault true;
# networking.interfaces.wlo1.useDHCP = lib.mkDefault true;
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
hardware.cpu.intel.updateMicrocode =
lib.mkDefault config.hardware.enableRedistributableFirmware;
}

View file

@ -0,0 +1,8 @@
{
inputs,
system,
...
}: {
wayland.windowManager.hyprland.settings.monitor = ["DP-1,2560x1440@165,1920x0,auto" "HDMI-A-1,1920x1080@60,0x0,1"];
wayland.windowManager.hyprland.package = inputs.stablepkgs.legacyPackages.${system}.hyprland;
}

57
hosts/phobos/configuration.nix Executable file
View file

@ -0,0 +1,57 @@
{
inputs,
config,
pkgs,
...
}: {
# Expose the package set, including overlays, for convenience.
# darwinPackages = inputs.self.darwinConfigurations."Youwens-MacBook-Pro".pkgs;
# List packages installed in system profile. To search by name, run:
# $ nix-env -qaP | grep wget
environment.systemPackages = with pkgs; [];
# Use a custom configuration.nix location.
# $ darwin-rebuild switch -I darwin-config=$HOME/.config/nixpkgs/darwin/configuration.nix
# environment.darwinConfig = "$HOME/.config/nixpkgs/darwin/configuration.nix";
# Auto upgrade nix package and the daemon service.
services.nix-daemon.enable = true;
# nix.package = pkgs.nix;
nix.settings.experimental-features = "nix-command flakes";
nixpkgs.config.allowUnfree = true;
# Create /etc/zshrc that loads the nix-darwin environment.
programs.zsh.enable = true; # default shell on catalina
programs.fish.enable = true;
programs.bash.enable = true;
system.configurationRevision =
config.self.rev or config.self.dirtyRev or null;
nixpkgs.hostPlatform = "aarch64-darwin";
# Used for backwards compatibility, please read the changelog before changing.
# $ darwin-rebuild changelog
system.stateVersion = 4;
users.users.youwen = {
home = "/Users/youwen";
description = "Youwen Wu";
shell = pkgs.fish;
};
security.pam.enableSudoTouchIdAuth = true;
fonts = {
packages = with pkgs; [
noto-fonts
noto-fonts-cjk
noto-fonts-emoji
(nerdfonts.override {fonts = ["CascadiaCode"];})
(google-fonts.override {fonts = ["Lora"];})
];
};
}

71
hosts/phobos/default.nix Executable file → Normal file
View file

@ -1,52 +1,21 @@
{ inputs, config, pkgs, ... }: { {inputs, ...}: {
# Expose the package set, including overlays, for convenience. imports = with inputs; [
# darwinPackages = inputs.self.darwinConfigurations."Youwens-MacBook-Pro".pkgs; ./configuration.nix
home-manager.darwinModules.home-manager
# List packages installed in system profile. To search by name, run: {
# $ nix-env -qaP | grep wget extraSpecialArgs = {inherit inputs;};
environment.systemPackages = with pkgs; [ ]; home-manager.useGlobalPkgs = true;
home-manager.useUserPackages = true;
# Use a custom configuration.nix location. home-manager.users.youwen.imports = [
# $ darwin-rebuild switch -I darwin-config=$HOME/.config/nixpkgs/darwin/configuration.nix ../../users/youwen/darwin/darwin-home.nix
# environment.darwinConfig = "$HOME/.config/nixpkgs/darwin/configuration.nix"; ../../users/youwen/common/core.nix
../../users/youwen/common/neofetch
# Auto upgrade nix package and the daemon service. ];
services.nix-daemon.enable = true; home-manager.backupFileExtension = "backup";
# nix.package = pkgs.nix; }
nix-homebrew.darwinModules.nix-homebrew
nix.settings.experimental-features = "nix-command flakes"; ../../modules/darwin/homebrew.nix
../../modules/darwin/yabai.nix
nixpkgs.config.allowUnfree = true; ../../modules/darwin/skhd.nix
];
# Create /etc/zshrc that loads the nix-darwin environment.
programs.zsh.enable = true; # default shell on catalina
programs.fish.enable = true;
programs.bash.enable = true;
system.configurationRevision =
config.self.rev or config.self.dirtyRev or null;
nixpkgs.hostPlatform = "aarch64-darwin";
# Used for backwards compatibility, please read the changelog before changing.
# $ darwin-rebuild changelog
system.stateVersion = 4;
users.users.youwen = {
home = "/Users/youwen";
description = "Youwen Wu";
shell = pkgs.fish;
};
security.pam.enableSudoTouchIdAuth = true;
fonts = {
packages = with pkgs; [
noto-fonts
noto-fonts-cjk
noto-fonts-emoji
(nerdfonts.override { fonts = [ "CascadiaCode" ]; })
(google-fonts.override { fonts = [ "Lora" ]; })
];
};
} }

View file

@ -1,4 +1,4 @@
{ inputs, ... }: { {inputs, ...}: {
nix-homebrew = { nix-homebrew = {
enable = true; enable = true;
enableRosetta = true; enableRosetta = true;

View file

@ -1,4 +1,8 @@
{ config, pkgs, ... }: { {
config,
pkgs,
...
}: {
services.yabai = { services.yabai = {
enable = true; enable = true;
enableScriptingAddition = true; enableScriptingAddition = true;
@ -28,4 +32,3 @@
blur_radius = 5.0; blur_radius = 5.0;
}; };
} }

View file

@ -0,0 +1,22 @@
{
inputs,
system,
...
}: {
environment.systemPackages = [
inputs.personal-neovim.packages.${system}.default
];
security.sudo.enable = false;
security.doas = {
enable = true;
extraRules = [
{
users = ["youwen"];
keepEnv = true;
persist = true;
}
];
};
}

View file

@ -1,18 +1,18 @@
{ pkgs, ... }: { {pkgs, ...}: {
fonts = { fonts = {
enableDefaultPackages = true; enableDefaultPackages = true;
fontconfig = { fontconfig = {
defaultFonts = { defaultFonts = {
serif = [ "Noto Serif" ]; serif = ["Noto Serif"];
sansSerif = [ "Noto Sans" ]; sansSerif = ["Noto Sans"];
}; };
}; };
packages = with pkgs; [ packages = with pkgs; [
noto-fonts noto-fonts
noto-fonts-cjk noto-fonts-cjk
noto-fonts-emoji noto-fonts-emoji
(nerdfonts.override { fonts = [ "CascadiaCode" ]; }) (nerdfonts.override {fonts = ["CascadiaCode"];})
(google-fonts.override { fonts = [ "Lora" ]; }) (google-fonts.override {fonts = ["Lora"];})
]; ];
}; };
} }

View file

@ -1,5 +1,4 @@
{pkgs, ...}: {pkgs, ...}: {
{
services.greetd = { services.greetd = {
enable = true; enable = true;
settings = { settings = {

View file

@ -0,0 +1,4 @@
{
services.logmein-hamachi.enable = true;
programs.haguichi.enable = true;
}

View file

@ -0,0 +1,19 @@
let
universalAllowedPorts = [27016 42805];
universalAllowedRanges = [
{
from = 42852;
to = 42872;
}
];
in {
services.openssh.enable = true;
networking.firewall = {
allowedTCPPorts = universalAllowedPorts;
allowedUDPPorts = universalAllowedPorts;
allowedUDPPortRanges = universalAllowedRanges;
allowedTCPPortRanges = universalAllowedRanges;
};
networking.firewall.enable = true;
networking.nameservers = ["1.1.1.1" "1.0.0.1"];
}

View file

@ -0,0 +1,9 @@
{pkgs, ...}: {
services.spotifyd = {
enable = true;
# settings = {global = 320;};
};
environment.systemPackages = [
pkgs.spotify-player
];
}

View file

@ -1,6 +0,0 @@
{
services.openssh.enable = true;
# networking.firewall.allowedTCPPorts = [ ... ];
# networking.firewall.allowedUDPPorts = [ ... ];
networking.nameservers = [ "1.1.1.1" "1.0.0.1" ];
}

14
overlays/default.nix Normal file
View file

@ -0,0 +1,14 @@
{
inputs,
pkgs,
...
}: let
stablepkgs = inputs.stablepkgs.legacyPackages.${pkgs.system};
bleedingpkgs = inputs.bleedingpkgs.legacyPackages.${pkgs.system};
in {
nixpkgs.overlays = [
(self: super: {
librewolf = stablepkgs.librewolf;
})
];
}

View file

@ -1,4 +1,4 @@
{ pkgs, ... }: { {pkgs, ...}: {
home.file.".essentials" = { home.file.".essentials" = {
source = ./essentials; source = ./essentials;
recursive = true; recursive = true;
@ -15,7 +15,7 @@
''; '';
}; };
programs.fzf = { enable = true; }; programs.fzf = {enable = true;};
programs.git = { programs.git = {
enable = true; enable = true;
@ -26,6 +26,7 @@
init.defaultBranch = "main"; init.defaultBranch = "main";
commit.gpgsign = pkgs.lib.mkDefault "true"; commit.gpgsign = pkgs.lib.mkDefault "true";
user.signingkey = "8F5E6C1AF90976CA7102917A865658ED1FE61EC3"; user.signingkey = "8F5E6C1AF90976CA7102917A865658ED1FE61EC3";
safe.directory = "/etc/nixos/.git";
}; };
}; };
@ -57,7 +58,7 @@
programs.gh = { programs.gh = {
enable = true; enable = true;
extensions = [ pkgs.github-copilot-cli ]; extensions = [pkgs.github-copilot-cli];
}; };
programs.oh-my-posh = { programs.oh-my-posh = {
@ -68,27 +69,22 @@
useTheme = "gruvbox"; useTheme = "gruvbox";
}; };
programs.direnv = {
enable = true;
nix-direnv.enable = true;
};
programs.fish = { programs.fish = {
enable = true; enable = true;
shellAliases = { shellAliases = {
rebuild = "sudo nixos-rebuild switch";
ls = "eza -l --icons=auto"; ls = "eza -l --icons=auto";
}; };
functions = { shellInit = ''
update-nixos = { oh-my-posh disable notice
description = '';
"Update the system flake and attempt to build and switch to the new configuration.";
body = ''
cd /etc/nixos
nix flake update
sudo nixos-rebuild switch
'';
};
};
interactiveShellInit = '' interactiveShellInit = ''
fish_vi_key_bindings fish_vi_key_bindings
set -g fish_greeting set -g fish_greeting
oh-my-posh disable notice
''; '';
plugins = [ plugins = [
{ {
@ -147,10 +143,31 @@
enableBashIntegration = true; enableBashIntegration = true;
}; };
programs.neovim = { programs.yazi = {
enable = true; enable = true;
defaultEditor = true; enableBashIntegration = true;
viAlias = true; enableFishIntegration = true;
vimAlias = true; plugins = {
mediainfo = pkgs.fetchFromGitHub {
owner = "Ape";
repo = "mediainfo.yazi";
rev = "c69314e80f5b45fe87a0e06a10d064ed54110439";
hash = "sha256-8xdBPdKSiwB7iRU8DJdTHY+BjfR9D3FtyVtDL9tNiy4=";
};
};
settings = {
plugin = {
prepend_previewers = [
{
mime = "{image,audio,video}/*";
run = "mediainfo";
}
{
mime = "application/x-subrip";
run = "mediainfo";
}
];
};
};
}; };
} }

View file

@ -1 +1 @@
{ imports = [ ./core.nix ]; } {imports = [./core.nix];}

View file

@ -1,828 +0,0 @@
# See this wiki page for more info:
# https://github.com/dylanaraps/neofetch/wiki/Customizing-Info
print_info() {
# prin " $(color 6) ​コンピューター"
prin "$(color 16)┌──────────────────────────────────────────┐"
info " $(color 1)  OS " distro
info " $(color 1)  Host " model
info " $(color 1)  Kernel " kernel
# info " $(color 1)  Uptime " uptime
info " $(color 2) 󰏗 Packages " packages
info " $(color 2)  Shell " shell
info " $(color 2)  Resolution " resolution
info " $(color 3)  DE " de
# info " $(color 3) 缾WM " wm
# info " $(color 12)  WM Theme " wm_theme
# info "$(color 13)  Theme " theme
# info "$(color 14)  Icons " icons
info " $(color 3)  Terminal " term
# info " Font " font
# info " Terminal Font " term_font
prin "$(color 16)└──────────────────────────────────────────┘"
prin " "
info " $(color 6) " title
prin "$(color 16)┌──────────────────────────────────────────┐"
info " $(color 12)  CPU " cpu
info " $(color 12)  GPU " gpu
info " $(color 13)  GPU Driver " gpu_driver # Linux/macOS only
info " $(color 13) ﬙ Memory " memory
# info "CPU Usage" cpu_usage
# info "Disk" disk
# info "Battery" battery
# info "Song" song
# [[ "$player" ]] && prin "Music Player" "$player"
# info "Local IP" local_ip
# info "Public IP" public_ip
# info "Users" users
# info "Locale" locale # This only works on glibc systems.
prin "$(color 16)└──────────────────────────────────────────┘"
prin " "
prin " $(color 1)​ $(color 2)​ $(color 3)​ $(color 4)​ $(color 5)​ $(color 6)​ $(color 7)​ $(color 8)​ $(color 16)"
}
# Title
# Hide/Show Fully qualified domain name.
#
# Default: 'off'
# Values: 'on', 'off'
# Flag: --title_fqdn
title_fqdn="off"
# Kernel
# Shorten the output of the kernel function.
#
# Default: 'on'
# Values: 'on', 'off'
# Flag: --kernel_shorthand
# Supports: Everything except *BSDs (except PacBSD and PC-BSD)
#
# Example:
# on: '4.8.9-1-ARCH'
# off: 'Linux 4.8.9-1-ARCH'
kernel_shorthand="false"
# Distro
# Shorten the output of the distro function
#
# Default: 'off'
# Values: 'on', 'tiny', 'off'
# Flag: --distro_shorthand
# Supports: Everything except Windows and Haiku
distro_shorthand="on"
# Show/Hide OS Architecture.
# Show 'x86_64', 'x86' and etc in 'Distro:' output.
#
# Default: 'on'
# Values: 'on', 'off'
# Flag: --os_arch
#
# Example:
# on: 'Arch Linux x86_64'
# off: 'Arch Linux'
os_arch="on"
# Uptime
# Shorten the output of the uptime function
#
# Default: 'on'
# Values: 'on', 'tiny', 'off'
# Flag: --uptime_shorthand
#
# Example:
# on: '2 days, 10 hours, 3 mins'
# tiny: '2d 10h 3m'
# off: '2 days, 10 hours, 3 minutes'
uptime_shorthand="on"
# Memory
# Show memory pecentage in output.
#
# Default: 'off'
# Values: 'on', 'off'
# Flag: --memory_percent
#
# Example:
# on: '1801MiB / 7881MiB (22%)'
# off: '1801MiB / 7881MiB'
memory_percent="off"
# Change memory output unit.
#
# Default: 'mib'
# Values: 'kib', 'mib', 'gib'
# Flag: --memory_unit
#
# Example:
# kib '1020928KiB / 7117824KiB'
# mib '1042MiB / 6951MiB'
# gib: ' 0.98GiB / 6.79GiB'
memory_unit="mib"
# Packages
# Show/Hide Package Manager names.
#
# Default: 'tiny'
# Values: 'on', 'tiny' 'off'
# Flag: --package_managers
#
# Example:
# on: '998 (pacman), 8 (flatpak), 4 (snap)'
# tiny: '908 (pacman, flatpak, snap)'
# off: '908'
package_managers="tiny"
# Shell
# Show the path to $SHELL
#
# Default: 'off'
# Values: 'on', 'off'
# Flag: --shell_path
#
# Example:
# on: '/bin/bash'
# off: 'bash'
shell_path="off"
# Show $SHELL version
#
# Default: 'on'
# Values: 'on', 'off'
# Flag: --shell_version
#
# Example:
# on: 'bash 4.4.5'
# off: 'bash'
shell_version="on"
# CPU
# CPU speed type
#
# Default: 'bios_limit'
# Values: 'scaling_cur_freq', 'scaling_min_freq', 'scaling_max_freq', 'bios_limit'.
# Flag: --speed_type
# Supports: Linux with 'cpufreq'
# NOTE: Any file in '/sys/devices/system/cpu/cpu0/cpufreq' can be used as a value.
speed_type="bios_limit"
# CPU speed shorthand
#
# Default: 'off'
# Values: 'on', 'off'.
# Flag: --speed_shorthand
# NOTE: This flag is not supported in systems with CPU speed less than 1 GHz
#
# Example:
# on: 'i7-6500U (4) @ 3.1GHz'
# off: 'i7-6500U (4) @ 3.100GHz'
speed_shorthand="off"
# Enable/Disable CPU brand in output.
#
# Default: 'on'
# Values: 'on', 'off'
# Flag: --cpu_brand
#
# Example:
# on: 'Intel i7-6500U'
# off: 'i7-6500U (4)'
cpu_brand="on"
# CPU Speed
# Hide/Show CPU speed.
#
# Default: 'on'
# Values: 'on', 'off'
# Flag: --cpu_speed
#
# Example:
# on: 'Intel i7-6500U (4) @ 3.1GHz'
# off: 'Intel i7-6500U (4)'
cpu_speed="on"
# CPU Cores
# Display CPU cores in output
#
# Default: 'logical'
# Values: 'logical', 'physical', 'off'
# Flag: --cpu_cores
# Support: 'physical' doesn't work on BSD.
#
# Example:
# logical: 'Intel i7-6500U (4) @ 3.1GHz' (All virtual cores)
# physical: 'Intel i7-6500U (2) @ 3.1GHz' (All physical cores)
# off: 'Intel i7-6500U @ 3.1GHz'
cpu_cores="logical"
# CPU Temperature
# Hide/Show CPU temperature.
# Note the temperature is added to the regular CPU function.
#
# Default: 'off'
# Values: 'C', 'F', 'off'
# Flag: --cpu_temp
# Supports: Linux, BSD
# NOTE: For FreeBSD and NetBSD-based systems, you'll need to enable
# coretemp kernel module. This only supports newer Intel processors.
#
# Example:
# C: 'Intel i7-6500U (4) @ 3.1GHz [27.2°C]'
# F: 'Intel i7-6500U (4) @ 3.1GHz [82.0°F]'
# off: 'Intel i7-6500U (4) @ 3.1GHz'
cpu_temp="off"
# GPU
# Enable/Disable GPU Brand
#
# Default: 'on'
# Values: 'on', 'off'
# Flag: --gpu_brand
#
# Example:
# on: 'AMD HD 7950'
# off: 'HD 7950'
gpu_brand="on"
# Which GPU to display
#
# Default: 'all'
# Values: 'all', 'dedicated', 'integrated'
# Flag: --gpu_type
# Supports: Linux
#
# Example:
# all:
# GPU1: AMD HD 7950
# GPU2: Intel Integrated Graphics
#
# dedicated:
# GPU1: AMD HD 7950
#
# integrated:
# GPU1: Intel Integrated Graphics
gpu_type="all"
# Resolution
# Display refresh rate next to each monitor
# Default: 'off'
# Values: 'on', 'off'
# Flag: --refresh_rate
# Supports: Doesn't work on Windows.
#
# Example:
# on: '1920x1080 @ 60Hz'
# off: '1920x1080'
refresh_rate="off"
# Gtk Theme / Icons / Font
# Shorten output of GTK Theme / Icons / Font
#
# Default: 'off'
# Values: 'on', 'off'
# Flag: --gtk_shorthand
#
# Example:
# on: 'Numix, Adwaita'
# off: 'Numix [GTK2], Adwaita [GTK3]'
gtk_shorthand="off"
# Enable/Disable gtk2 Theme / Icons / Font
#
# Default: 'on'
# Values: 'on', 'off'
# Flag: --gtk2
#
# Example:
# on: 'Numix [GTK2], Adwaita [GTK3]'
# off: 'Adwaita [GTK3]'
gtk2="on"
# Enable/Disable gtk3 Theme / Icons / Font
#
# Default: 'on'
# Values: 'on', 'off'
# Flag: --gtk3
#
# Example:
# on: 'Numix [GTK2], Adwaita [GTK3]'
# off: 'Numix [GTK2]'
gtk3="on"
# IP Address
# Website to ping for the public IP
#
# Default: 'http://ident.me'
# Values: 'url'
# Flag: --ip_host
public_ip_host="http://ident.me"
# Public IP timeout.
#
# Default: '2'
# Values: 'int'
# Flag: --ip_timeout
public_ip_timeout=2
# Desktop Environment
# Show Desktop Environment version
#
# Default: 'on'
# Values: 'on', 'off'
# Flag: --de_version
de_version="on"
# Disk
# Which disks to display.
# The values can be any /dev/sdXX, mount point or directory.
# NOTE: By default we only show the disk info for '/'.
#
# Default: '/'
# Values: '/', '/dev/sdXX', '/path/to/drive'.
# Flag: --disk_show
#
# Example:
# disk_show=('/' '/dev/sdb1'):
# 'Disk (/): 74G / 118G (66%)'
# 'Disk (/mnt/Videos): 823G / 893G (93%)'
#
# disk_show=('/'):
# 'Disk (/): 74G / 118G (66%)'
#
disk_show=('/')
# Disk subtitle.
# What to append to the Disk subtitle.
#
# Default: 'mount'
# Values: 'mount', 'name', 'dir', 'none'
# Flag: --disk_subtitle
#
# Example:
# name: 'Disk (/dev/sda1): 74G / 118G (66%)'
# 'Disk (/dev/sdb2): 74G / 118G (66%)'
#
# mount: 'Disk (/): 74G / 118G (66%)'
# 'Disk (/mnt/Local Disk): 74G / 118G (66%)'
# 'Disk (/mnt/Videos): 74G / 118G (66%)'
#
# dir: 'Disk (/): 74G / 118G (66%)'
# 'Disk (Local Disk): 74G / 118G (66%)'
# 'Disk (Videos): 74G / 118G (66%)'
#
# none: 'Disk: 74G / 118G (66%)'
# 'Disk: 74G / 118G (66%)'
# 'Disk: 74G / 118G (66%)'
disk_subtitle="mount"
# Disk percent.
# Show/Hide disk percent.
#
# Default: 'on'
# Values: 'on', 'off'
# Flag: --disk_percent
#
# Example:
# on: 'Disk (/): 74G / 118G (66%)'
# off: 'Disk (/): 74G / 118G'
disk_percent="on"
# Song
# Manually specify a music player.
#
# Default: 'auto'
# Values: 'auto', 'player-name'
# Flag: --music_player
#
# Available values for 'player-name':
#
# amarok
# audacious
# banshee
# bluemindo
# clementine
# cmus
# deadbeef
# deepin-music
# dragon
# elisa
# exaile
# gnome-music
# gmusicbrowser
# gogglesmm
# guayadeque
# io.elementary.music
# iTunes
# juk
# lollypop
# mocp
# mopidy
# mpd
# muine
# netease-cloud-music
# olivia
# playerctl
# pogo
# pragha
# qmmp
# quodlibet
# rhythmbox
# sayonara
# smplayer
# spotify
# strawberry
# tauonmb
# tomahawk
# vlc
# xmms2d
# xnoise
# yarock
music_player="auto"
# Format to display song information.
#
# Default: '%artist% - %album% - %title%'
# Values: '%artist%', '%album%', '%title%'
# Flag: --song_format
#
# Example:
# default: 'Song: Jet - Get Born - Sgt Major'
song_format="%artist% - %album% - %title%"
# Print the Artist, Album and Title on separate lines
#
# Default: 'off'
# Values: 'on', 'off'
# Flag: --song_shorthand
#
# Example:
# on: 'Artist: The Fratellis'
# 'Album: Costello Music'
# 'Song: Chelsea Dagger'
#
# off: 'Song: The Fratellis - Costello Music - Chelsea Dagger'
song_shorthand="off"
# 'mpc' arguments (specify a host, password etc).
#
# Default: ''
# Example: mpc_args=(-h HOST -P PASSWORD)
mpc_args=()
# Text Colors
# Text Colors
#
# Default: 'distro'
# Values: 'distro', 'num' 'num' 'num' 'num' 'num' 'num'
# Flag: --colors
#
# Each number represents a different part of the text in
# this order: 'title', '@', 'underline', 'subtitle', 'colon', 'info'
#
# Example:
# colors=(distro) - Text is colored based on Distro colors.
# colors=(4 6 1 8 8 6) - Text is colored in the order above.
colors=(distro)
# Text Options
# Toggle bold text
#
# Default: 'on'
# Values: 'on', 'off'
# Flag: --bold
bold="on"
# Enable/Disable Underline
#
# Default: 'on'
# Values: 'on', 'off'
# Flag: --underline
underline_enabled="on"
# Underline character
#
# Default: '-'
# Values: 'string'
# Flag: --underline_char
underline_char="-"
# Info Separator
# Replace the default separator with the specified string.
#
# Default: ':'
# Flag: --separator
#
# Example:
# separator="->": 'Shell-> bash'
# separator=" =": 'WM = dwm'
separator=":"
# Color Blocks
# Color block range
# The range of colors to print.
#
# Default: '0', '15'
# Values: 'num'
# Flag: --block_range
#
# Example:
#
# Display colors 0-7 in the blocks. (8 colors)
# neofetch --block_range 0 7
#
# Display colors 0-15 in the blocks. (16 colors)
# neofetch --block_range 0 15
block_range=(0 15)
# Toggle color blocks
#
# Default: 'on'
# Values: 'on', 'off'
# Flag: --color_blocks
color_blocks="on"
# Color block width in spaces
#
# Default: '3'
# Values: 'num'
# Flag: --block_width
block_width=3
# Color block height in lines
#
# Default: '1'
# Values: 'num'
# Flag: --block_height
block_height=1
# Color Alignment
#
# Default: 'auto'
# Values: 'auto', 'num'
# Flag: --col_offset
#
# Number specifies how far from the left side of the terminal (in spaces) to
# begin printing the columns, in case you want to e.g. center them under your
# text.
# Example:
# col_offset="auto" - Default behavior of neofetch
# col_offset=7 - Leave 7 spaces then print the colors
col_offset="auto"
# Progress Bars
# Bar characters
#
# Default: '-', '='
# Values: 'string', 'string'
# Flag: --bar_char
#
# Example:
# neofetch --bar_char 'elapsed' 'total'
# neofetch --bar_char '-' '='
bar_char_elapsed="-"
bar_char_total="="
# Toggle Bar border
#
# Default: 'on'
# Values: 'on', 'off'
# Flag: --bar_border
bar_border="on"
# Progress bar length in spaces
# Number of chars long to make the progress bars.
#
# Default: '15'
# Values: 'num'
# Flag: --bar_length
bar_length=15
# Progress bar colors
# When set to distro, uses your distro's logo colors.
#
# Default: 'distro', 'distro'
# Values: 'distro', 'num'
# Flag: --bar_colors
#
# Example:
# neofetch --bar_colors 3 4
# neofetch --bar_colors distro 5
bar_color_elapsed="distro"
bar_color_total="distro"
# Info display
# Display a bar with the info.
#
# Default: 'off'
# Values: 'bar', 'infobar', 'barinfo', 'off'
# Flags: --cpu_display
# --memory_display
# --battery_display
# --disk_display
#
# Example:
# bar: '[---=======]'
# infobar: 'info [---=======]'
# barinfo: '[---=======] info'
# off: 'info'
cpu_display="off"
memory_display="off"
battery_display="off"
disk_display="off"
# Backend Settings
# Image backend.
#
# Default: 'ascii'
# Values: 'ascii', 'caca', 'chafa', 'jp2a', 'iterm2', 'off',
# 'pot', 'termpix', 'pixterm', 'tycat', 'w3m', 'kitty'
# Flag: --backend
image_backend="kitty"
# Image Source
#
# Which image or ascii file to display.
#
# Default: 'auto'
# Values: 'auto', 'ascii', 'wallpaper', '/path/to/img', '/path/to/ascii', '/path/to/dir/'
# 'command output (neofetch --ascii "$(fortune | cowsay -W 30)")'
# Flag: --source
#
# NOTE: 'auto' will pick the best image source for whatever image backend is used.
# In ascii mode, distro ascii art will be used and in an image mode, your
# wallpaper will be used.
# image_source=$(find "${XDG_CONFIG_HOME:-$HOME/.config}/neofetch/pngs/" -name "*.png" | sort -R | head -1)
# Ascii Options
# Ascii distro
# Which distro's ascii art to display.
#
# Default: 'auto'
# Values: 'auto', 'distro_name'
# Flag: --ascii_distro
# NOTE: AIX, Alpine, Anarchy, Android, Antergos, antiX, "AOSC OS",
# "AOSC OS/Retro", Apricity, ArcoLinux, ArchBox, ARCHlabs,
# ArchStrike, XFerience, ArchMerge, Arch, Artix, Arya, Bedrock,
# Bitrig, BlackArch, BLAG, BlankOn, BlueLight, bonsai, BSD,
# BunsenLabs, Calculate, Carbs, CentOS, Chakra, ChaletOS,
# Chapeau, Chrom*, Cleanjaro, ClearOS, Clear_Linux, Clover,
# Condres, Container_Linux, CRUX, Cucumber, Debian, Deepin,
# DesaOS, Devuan, DracOS, DarkOs, DragonFly, Drauger, Elementary,
# EndeavourOS, Endless, EuroLinux, Exherbo, Fedora, Feren, FreeBSD,
# FreeMiNT, Frugalware, Funtoo, GalliumOS, Garuda, Gentoo, Pentoo,
# gNewSense, GNOME, GNU, GoboLinux, Grombyang, Guix, Haiku, Huayra,
# Hyperbola, janus, Kali, KaOS, KDE_neon, Kibojoe, Kogaion,
# Korora, KSLinux, Kubuntu, LEDE, LFS, Linux_Lite,
# LMDE, Lubuntu, Lunar, macos, Mageia, MagpieOS, Mandriva,
# Manjaro, Maui, Mer, Minix, LinuxMint, MX_Linux, Namib,
# Neptune, NetBSD, Netrunner, Nitrux, NixOS, Nurunner,
# NuTyX, OBRevenge, OpenBSD, openEuler, OpenIndiana, openmamba,
# OpenMandriva, OpenStage, OpenWrt, osmc, Oracle, OS Elbrus, PacBSD,
# Parabola, Pardus, Parrot, Parsix, TrueOS, PCLinuxOS, Peppermint,
# popos, Porteus, PostMarketOS, Proxmox, Puppy, PureOS, Qubes, Radix,
# Raspbian, Reborn_OS, Redstar, Redcore, Redhat, Refracted_Devuan,
# Regata, Rosa, sabotage, Sabayon, Sailfish, SalentOS, Scientific,
# Septor, SereneLinux, SharkLinux, Siduction, Slackware, SliTaz,
# SmartOS, Solus, Source_Mage, Sparky, Star, SteamOS, SunOS,
# openSUSE_Leap, openSUSE_Tumbleweed, openSUSE, SwagArch, Tails,
# Trisquel, Ubuntu-Budgie, Ubuntu-GNOME, Ubuntu-MATE, Ubuntu-Studio,
# Ubuntu, Venom, Void, Obarun, windows10, Windows7, Xubuntu, Zorin,
# and IRIX have ascii logos
# NOTE: Arch, Ubuntu, Redhat, and Dragonfly have 'old' logo variants.
# Use '{distro name}_old' to use the old logos.
# NOTE: Ubuntu has flavor variants.
# Change this to Lubuntu, Kubuntu, Xubuntu, Ubuntu-GNOME,
# Ubuntu-Studio, Ubuntu-Mate or Ubuntu-Budgie to use the flavors.
# NOTE: Arcolinux, Dragonfly, Fedora, Alpine, Arch, Ubuntu,
# CRUX, Debian, Gentoo, FreeBSD, Mac, NixOS, OpenBSD, android,
# Antrix, CentOS, Cleanjaro, ElementaryOS, GUIX, Hyperbola,
# Manjaro, MXLinux, NetBSD, Parabola, POP_OS, PureOS,
# Slackware, SunOS, LinuxLite, OpenSUSE, Raspbian,
# postmarketOS, and Void have a smaller logo variant.
# Use '{distro name}_small' to use the small variants.
ascii_distro="auto"
# Ascii Colors
#
# Default: 'distro'
# Values: 'distro', 'num' 'num' 'num' 'num' 'num' 'num'
# Flag: --ascii_colors
#
# Example:
# ascii_colors=(distro) - Ascii is colored based on Distro colors.
# ascii_colors=(4 6 1 8 8 6) - Ascii is colored using these colors.
ascii_colors=(distro)
# Bold ascii logo
# Whether or not to bold the ascii logo.
#
# Default: 'on'
# Values: 'on', 'off'
# Flag: --ascii_bold
ascii_bold="on"
# Image Options
# Image loop
# Setting this to on will make neofetch redraw the image constantly until
# Ctrl+C is pressed. This fixes display issues in some terminal emulators.
#
# Default: 'off'
# Values: 'on', 'off'
# Flag: --loop
image_loop="off"
# Thumbnail directory
#
# Default: '~/.cache/thumbnails/neofetch'
# Values: 'dir'
thumbnail_dir="${XDG_CACHE_HOME:-${HOME}/.cache}/thumbnails/neofetch"
# Crop mode
#
# Default: 'normal'
# Values: 'normal', 'fit', 'fill'
# Flag: --crop_mode
#
# See this wiki page to learn about the fit and fill options.
# https://github.com/dylanaraps/neofetch/wiki/What-is-Waifu-Crop%3F
crop_mode="normal"
# Crop offset
# Note: Only affects 'normal' crop mode.
#
# Default: 'center'
# Values: 'northwest', 'north', 'northeast', 'west', 'center'
# 'east', 'southwest', 'south', 'southeast'
# Flag: --crop_offset
crop_offset="northwest"
# Image size
# The image is half the terminal width by default.
#
# Default: 'auto'
# Values: 'auto', '00px', '00%', 'none'
# Flags: --image_size
# --size
image_size="270px"
# Gap between image and text
#
# Default: '3'
# Values: 'num', '-num'
# Flag: --gap
gap=8
# Image offsets
# Only works with the w3m backend.
#
# Default: '0'
# Values: 'px'
# Flags: --xoffset
# --yoffset
yoffset=0
xoffset=2
# Image background color
# Only works with the w3m backend.
#
# Default: ''
# Values: 'color', 'blue'
# Flag: --bg_color
background_color=
# Misc Options
# Stdout mode
# Turn off all colors and disables image backend (ASCII/Image).
# Useful for piping into another command.
# Default: 'off'
# Values: 'on', 'off'
stdout="off"

View file

@ -1,3 +0,0 @@
{
home.file.".config/neofetch/config.conf".source = ./neofetch-asahi.conf;
}

View file

@ -1,6 +1,9 @@
{ inputs, config, pkgs, ... }:
{ {
inputs,
config,
pkgs,
...
}: {
home.username = "youwen"; home.username = "youwen";
home.homeDirectory = "/Users/youwen"; home.homeDirectory = "/Users/youwen";
@ -37,11 +40,6 @@
# it provides the command `nom` works just like `nix` # it provides the command `nom` works just like `nix`
# with more details log output # with more details log output
nix-output-monitor nix-output-monitor
# dev tools
nodePackages_latest.pnpm
rustfmt
rust-analyzer
]; ];
programs.git.extraConfig.commit.gpgsign = "false"; programs.git.extraConfig.commit.gpgsign = "false";
@ -79,5 +77,4 @@
# Let home Manager install and manage itself. # Let home Manager install and manage itself.
programs.home-manager.enable = true; programs.home-manager.enable = true;
} }

View file

@ -7,4 +7,3 @@
../waybar/desktop ../waybar/desktop
]; ];
} }

View file

@ -1,6 +1,8 @@
{ config, pkgs, ... }:
{ {
config,
pkgs,
...
}: {
home.username = "youwen"; home.username = "youwen";
home.homeDirectory = "/home/youwen"; home.homeDirectory = "/home/youwen";

View file

@ -1,14 +1,36 @@
{ pkgs, ... }:
{ {
pkgs,
inputs,
system,
...
}: {
home.packages = with pkgs; [
wl-clipboard
grim
slurp
swappy
pavucontrol
waypaper
swaybg
pamixer
brightnessctl
bibata-cursors
libsForQt5.qtstyleplugin-kvantum
libsForQt5.qt5ct
papirus-icon-theme
libsForQt5.qt5ct
];
wayland.windowManager.hyprland = { wayland.windowManager.hyprland = {
enable = true; enable = true;
settings = { settings = {
exec-once = [ "waypaper --restore" ]; exec-once = ["waypaper --restore"];
"$mod" = "SUPER"; "$mod" = "SUPER";
"$Left" = "Y"; "$Left" = "H";
"$Right" = "O"; "$Right" = "L";
"$Up" = "I"; "$Up" = "K";
"$Down" = "U"; "$Down" = "J";
env = [ env = [
"HYPRCURSOR_THEME,Bibata-Modern-Ice" "HYPRCURSOR_THEME,Bibata-Modern-Ice"
"HYPRCURSOR_SIZE,26" "HYPRCURSOR_SIZE,26"
@ -21,11 +43,12 @@
"$mod, T, exec, kitty" "$mod, T, exec, kitty"
"$mod, E, exec, dolphin" "$mod, E, exec, dolphin"
"$mod, R, exec, pavucontrol" "$mod, R, exec, pavucontrol"
"$mod, M, exec, thunderbird"
# Window actions # Window actions
"$mod, Q, killactive" "$mod, Q, killactive"
"$mod, W, togglefloating" "$mod, W, togglefloating"
"$mod, J, togglesplit" "$mod, V, togglesplit"
"$mod, Return, fullscreen" "$mod, Return, fullscreen"
# Move around # Move around
@ -45,36 +68,49 @@
"$mod, 9, workspace, 9" "$mod, 9, workspace, 9"
"$mod, 0, workspace, 10" "$mod, 0, workspace, 10"
# Move active window to a workspace with mainMod + SHIFT + [0-9]
"$mod+Shift, 1, movetoworkspace, 1"
"$mod+Shift, 2, movetoworkspace, 2"
"$mod+Shift, 3, movetoworkspace, 3"
"$mod+Shift, 4, movetoworkspace, 4"
"$mod+Shift, 5, movetoworkspace, 5"
"$mod+Shift, 6, movetoworkspace, 6"
"$mod+Shift, 7, movetoworkspace, 7"
"$mod+Shift, 8, movetoworkspace, 8"
"$mod+Shift, 9, movetoworkspace, 9"
"$mod+Shift, 0, movetoworkspace, 10"
# move to the first empty workspace instantly
"$mod+Ctrl, $Down, workspace, empty"
"$mod+Ctrl, $Up, movetoworkspace, empty"
# Special workspace
"$mod, S, togglespecialworkspace" "$mod, S, togglespecialworkspace"
"$mod+Alt, S, movetoworkspacesilent, special"
# Move windows around # Move windows around
"$mod+Shift+Ctrl, $Left, movewindow, l" "$mod+Shift, $Left, movewindow, l"
"$mod+Shift+Ctrl, $Right, movewindow, r" "$mod+Shift, $Right, movewindow, r"
"$mod+Shift+Ctrl, $Up, movewindow, u" "$mod+Shift, $Up, movewindow, u"
"$mod+Shift+Ctrl, $Down, movewindow, d" "$mod+Shift, $Down, movewindow, d"
"$mod+Ctrl+Alt, $Right, movetoworkspace, r+1" "$mod+Ctrl+Shift, $Right, movetoworkspace, r+1"
"$mod+Ctrl+Alt, $Left, movetoworkspace, r-1" "$mod+Ctrl+Shift, $Left, movetoworkspace, r-1"
"$mod+Ctrl, $Right, workspace, r+1" "$mod+Ctrl, $Right, workspace, r+1"
"$mod+Ctrl, $Left, workspace, r-1" "$mod+Ctrl, $Left, workspace, r-1"
"$mod+Alt, S, movetoworkspacesilent, special"
# Utilities # Utilities
"$mod, Space, exec, pkill -x rofi || rofi -show drun" # Run rofi "$mod, Space, exec, pkill -x rofi || rofi -show drun" # Run rofi application launcher
"$mod, G, exec, pkill -x rofi || rofi -show window" # Run rofi window switcher
''$mod, P, exec, grim -g "$(slurp)" - | swappy -f -'' # Screenshot ''$mod, P, exec, grim -g "$(slurp)" - | swappy -f -'' # Screenshot
"$mod, Backspace, exec, wlogout" # show logout menu "$mod, Backspace, exec, wlogout" # show logout menu
"$mod, L, exec, hyprlock" "$mod, I, exec, hyprlock"
# System control # System control
",XF86MonBrightnessDown, exec, brightnessctl set 5%-"
",XF86MonBrightnessUp, exec, brightnessctl set 5%+"
",XF86AudioRaiseVolume, exec, pamixer -i 5"
",XF86AudioLowerVolume, exec, pamixer -d 5"
",XF86AudioMute, exec, pamixer -t" ",XF86AudioMute, exec, pamixer -t"
]; ];
bindm = [ bindm = [
@ -83,6 +119,19 @@
"$mod, Z, movewindow" "$mod, Z, movewindow"
"$mod, X, resizewindow" "$mod, X, resizewindow"
]; ];
bindel = [
",XF86MonBrightnessDown, exec, brightnessctl set 5%-"
",XF86MonBrightnessUp, exec, brightnessctl set 5%+"
",XF86AudioRaiseVolume, exec, pamixer -i 5"
",XF86AudioLowerVolume, exec, pamixer -d 5"
];
binde = [
# Resize windows
"$mod+Alt, $Right, resizeactive, 30 0"
"$mod+Alt, $Left, resizeactive, -30 0"
"$mod+Alt, $Up, resizeactive, 0 -30"
"$mod+Alt, $Down, resizeactive, 0 30"
];
windowrulev2 = [ windowrulev2 = [
"opacity 0.90 0.90,class:^(librewolf)$" "opacity 0.90 0.90,class:^(librewolf)$"
"opacity 0.90 0.90,class:^(Brave-browser)$" "opacity 0.90 0.90,class:^(Brave-browser)$"
@ -103,6 +152,9 @@
"opacity 0.80 0.80,class:^(qt5ct)$" "opacity 0.80 0.80,class:^(qt5ct)$"
"opacity 0.80 0.80,class:^(qt6ct)$" "opacity 0.80 0.80,class:^(qt6ct)$"
"opacity 0.80 0.80,class:^(kvantummanager)$" "opacity 0.80 0.80,class:^(kvantummanager)$"
"opacity 0.80 0.80,class:^(waypaper)$"
"opacity 0.80 0.80,class:^(org.pulseaudio.pavucontrol)$"
"opacity 0.80 0.80,class:^(thunderbird)$"
"opacity 0.90 0.90,class:^(com.github.rafostar.Clapper)$ # Clapper-Gtk" "opacity 0.90 0.90,class:^(com.github.rafostar.Clapper)$ # Clapper-Gtk"
"opacity 0.80 0.80,class:^(com.github.tchx84.Flatseal)$ # Flatseal-Gtk" "opacity 0.80 0.80,class:^(com.github.tchx84.Flatseal)$ # Flatseal-Gtk"
@ -137,6 +189,7 @@
"float,class:^(qt6ct)$" "float,class:^(qt6ct)$"
"float,class:^(nwg-look)$" "float,class:^(nwg-look)$"
"float,class:^(org.kde.ark)$" "float,class:^(org.kde.ark)$"
"float,class:^(org.pulseaudio.pavucontrol)$"
"float,class:^(com.github.rafostar.Clapper)$ # Clapper-Gtk" "float,class:^(com.github.rafostar.Clapper)$ # Clapper-Gtk"
"float,class:^(app.drey.Warp)$ # Warp-Gtk" "float,class:^(app.drey.Warp)$ # Warp-Gtk"
"float,class:^(net.davidotek.pupgui2)$ # ProtonUp-Qt" "float,class:^(net.davidotek.pupgui2)$ # ProtonUp-Qt"
@ -164,8 +217,6 @@
"ignorezero,swaync-control-center" "ignorezero,swaync-control-center"
"blur,logout_dialog" "blur,logout_dialog"
]; ];
monitor =
[ "DP-1,2560x1440@165,1920x0,auto" "HDMI-A-1,1920x1080@60,0x0,1" ];
dwindle = { dwindle = {
pseudotile = "yes"; pseudotile = "yes";
preserve_split = "yes"; preserve_split = "yes";
@ -189,7 +240,7 @@
"workspaces, 1, 5, wind" "workspaces, 1, 5, wind"
]; ];
}; };
general = { general = {
gaps_in = "3"; gaps_in = "3";
gaps_out = "8"; gaps_out = "8";
@ -200,7 +251,6 @@
"col.inactive_border" = "rgba(b4befecc) rgba(6c7086cc) 45deg"; "col.inactive_border" = "rgba(b4befecc) rgba(6c7086cc) 45deg";
layout = "dwindle"; layout = "dwindle";
resize_on_border = "true"; resize_on_border = "true";
sensitivity = "0.5";
}; };
misc = { misc = {
@ -226,6 +276,9 @@
special = true; special = true;
}; };
}; };
input = {
sensitivity = "-0.65";
};
}; };
}; };
@ -284,17 +337,15 @@
services.hypridle = { services.hypridle = {
enable = true; enable = true;
settings = { settings = {
lock_cmd = lock_cmd = "pidof hyprlock || hyprlock"; # avoid starting multiple hyprlock instances.
"pidof hyprlock || hyprlock"; # avoid starting multiple hyprlock instances.
before_sleep_cmd = "loginctl lock-session"; # lock before suspend. before_sleep_cmd = "loginctl lock-session"; # lock before suspend.
after_sleep_cmd = after_sleep_cmd = "hyprctl dispatch dpms on"; # to avoid having to press a key twice to turn on the display.
"hyprctl dispatch dpms on"; # to avoid having to press a key twice to turn on the display.
}; };
}; };
xdg.portal = { xdg.portal = {
enable = true; enable = true;
configPackages = [ pkgs.xdg-desktop-portal-hyprland ]; configPackages = [pkgs.xdg-desktop-portal-hyprland];
extraPortals = [ pkgs.xdg-desktop-portal-hyprland ]; extraPortals = [pkgs.xdg-desktop-portal-hyprland];
}; };
} }

View file

@ -1 +1 @@
{ imports = [ ../common.nix ]; } {imports = [../common.nix];}

View file

@ -1,5 +1,5 @@
{ lib, ... }: { {lib, ...}: {
imports = [ ../common.nix ]; imports = [../common.nix];
wayland.windowManager.hyprland.settings.input.touchpad = { wayland.windowManager.hyprland.settings.input.touchpad = {
natural_scroll = true; natural_scroll = true;
disable_while_typing = true; disable_while_typing = true;
@ -7,7 +7,7 @@
tap-to-click = false; tap-to-click = false;
scroll_factor = 0.5; scroll_factor = 0.5;
}; };
wayland.windowManager.hyprland.settings.general.sensitivity = lib.mkForce 1.0; wayland.windowManager.hyprland.settings.input.sensitivity = lib.mkForce "0.0";
wayland.windowManager.hyprland.settings.env = [ wayland.windowManager.hyprland.settings.env = [
"HYPRCURSOR_THEME,Bibata-Modern-Ice" "HYPRCURSOR_THEME,Bibata-Modern-Ice"
"HYPRCURSOR_SIZE,24" "HYPRCURSOR_SIZE,24"

View file

@ -1,8 +1,6 @@
{ pkgs, ... }: { {pkgs, ...}: {
imports = imports = [../theming ../home.nix ../programs ../hyprland/laptop ../waybar/laptop];
[ ../theming ../home.nix ../programs ../hyprland/laptop ../waybar/laptop ];
# some overrides for laptop specifically # some overrides for laptop specifically
programs.kitty.settings.font_size = pkgs.lib.mkForce 11; programs.kitty.settings.font_size = pkgs.lib.mkForce 11;
} }

View file

@ -1,3 +1,3 @@
{ pkgs, ... }: {pkgs, ...}: let
let createCommon = import ../common-packages.nix; createCommon = import ../common-packages.nix;
in { home.packages = ((createCommon pkgs) ++ [ ]); } in {home.packages = (createCommon pkgs) ++ [];}

View file

@ -22,15 +22,7 @@ with pkgs; [
usbutils # lsusb usbutils # lsusb
# desktop utils # desktop utils
wl-clipboard bitwarden-cli
grim
slurp
swappy
pavucontrol
waypaper
swaybg
pamixer
brightnessctl
# desktop apps # desktop apps
dolphin dolphin
@ -38,26 +30,5 @@ with pkgs; [
vesktop vesktop
signal-desktop signal-desktop
# dev tools
nodePackages_latest.pnpm
rustfmt
rust-analyzer
gcc gcc
lua51Packages.luarocks
lua
nodejs_22
python3
tree-sitter
cargo
rustc
# currently marked broken
# haskellPackages.stack
# haskellPackages.ghcup
# desktop ricing
bibata-cursors
libsForQt5.qtstyleplugin-kvantum
libsForQt5.qt5ct
papirus-icon-theme
libsForQt5.qt5ct
] ]

View file

@ -1,13 +1,14 @@
{ pkgs, ... }: {pkgs, ...}: let
let createCommon = import ../common-packages.nix; createCommon = import ../common-packages.nix;
in { in {
home.packages = ((createCommon pkgs) ++ (with pkgs; [ home.packages =
spotify (createCommon pkgs)
bitwarden-desktop ++ (with pkgs; [
modrinth-app bitwarden-desktop
lutris modrinth-app
wine lutris
sbctl wine
r2modman sbctl
])); r2modman
]);
} }

View file

@ -1,4 +1,4 @@
{ {pkgs, ...}: {
programs.kitty = { programs.kitty = {
enable = true; enable = true;
theme = "Tokyo Night"; theme = "Tokyo Night";
@ -12,11 +12,13 @@
background_opacity = "0.8"; background_opacity = "0.8";
allow_remote_control = "socket-only"; allow_remote_control = "socket-only";
listen_on = "unix:/tmp/kitty"; listen_on = "unix:/tmp/kitty";
action_alias = "kitty_scrollback_nvim kitten /home/youwen/.local/share/nvim/lazy/kitty-scrollback.nvim/python/kitty_scrollback_nvim.py"; # action_alias = "kitty_scrollback_nvim kitten /home/youwen/.local/share/nvim/lazy/kitty-scrollback.nvim/python/kitty_scrollback_nvim.py";
scrollback_pager = ''nvim --noplugin -c "set signcolumn=no showtabline=0" -c "silent write! /tmp/kitty_scrollback_buffer | te cat /tmp/kitty_scrollback_buffer - "'';
}; };
keybindings = { keybindings = {
"kitty_mod+h" = "kitty_scrollback_nvim"; # "kitty_mod+h" = "kitty_scrollback_nvim";
"kitty_mod+g" = "kitty_scrollback_nvim --config ksb_builtin_last_cmd_output"; # "kitty_mod+g" = "kitty_scrollback_nvim --config ksb_builtin_last_cmd_output";
"kitty_mod+h" = "show_scrollback";
}; };
}; };
@ -29,5 +31,6 @@
"privacy.clearOnShutdown.cookies" = false; "privacy.clearOnShutdown.cookies" = false;
"network.cookie.lifetimePolicy" = 0; "network.cookie.lifetimePolicy" = 0;
}; };
package = pkgs.librewolf-wayland;
}; };
} }

View file

@ -0,0 +1,24 @@
{
inputs,
pkgs,
...
}: let
spicepkgs = inputs.spicetify.legacyPackages.${pkgs.system};
in {
imports = [
inputs.spicetify.homeManagerModules.default
];
programs.spicetify = {
enable = true;
theme = spicepkgs.themes.dribbblish;
colorScheme = "rosepine";
enabledExtensions = with spicepkgs.extensions; [
lastfm
fullAppDisplayMod
];
enabledCustomApps = with spicepkgs.apps; [
lyricsPlus
];
};
}

View file

@ -15,4 +15,8 @@
enable = true; enable = true;
flavor = "mocha"; flavor = "mocha";
}; };
programs.yazi.catppuccin = {
enable = true;
flavor = "macchiato";
};
} }

View file

@ -1,5 +1,5 @@
{ pkgs, ... }: { {pkgs, ...}: {
imports = [ ./catppuccin.nix ]; imports = [./catppuccin.nix];
gtk = { gtk = {
enable = true; enable = true;
@ -8,7 +8,7 @@
name = "Bibata-Modern-Ice"; name = "Bibata-Modern-Ice";
size = 26; size = 26;
}; };
iconTheme = { name = "Papirus-Dark"; }; iconTheme = {name = "Papirus-Dark";};
}; };
qt = { qt = {
@ -23,8 +23,6 @@
theme=GraphiteNordDark theme=GraphiteNordDark
''; '';
"Kvantum/GraphiteNord".source = "Kvantum/GraphiteNord".source = "${pkgs.graphite-kde-theme}/share/Kvantum/GraphiteNord";
"${pkgs.graphite-kde-theme}/share/Kvantum/GraphiteNord";
}; };
} }

View file

@ -9,21 +9,21 @@
width = 1600; width = 1600;
reload-style-on-change = true; reload-style-on-change = true;
margin = "10px 0px 0px 0px"; margin = "10px 0px 0px 0px";
modules-left = [ "hyprland/window" "hyprland/workspaces" ]; modules-left = ["hyprland/window" "hyprland/workspaces"];
modules-right = [ "backlight" "group/adjustable" "custom/weather" ]; modules-right = ["backlight" "group/adjustable" "custom/weather"];
modules-center = [ "network" "group/hardware" "clock" ]; modules-center = ["network" "group/hardware" "clock"];
"hyprland/workspaces" = { "hyprland/workspaces" = {
active-only = false; active-only = false;
all-outputs = false; all-outputs = false;
format = "{icon}"; format = "{icon}";
persistent-workspaces = { persistent-workspaces = {
eDP-1 = [ 1 ]; eDP-1 = [1];
DP-1 = [ 2 3 4 5 ]; DP-1 = [2 3 4 5];
}; };
}; };
"group/hardware" = { "group/hardware" = {
orientation = "inherit"; orientation = "inherit";
modules = [ "cpu" "memory" "battery" ]; modules = ["cpu" "memory" "battery"];
}; };
"group/adjustable" = { "group/adjustable" = {
orientation = "inherit"; orientation = "inherit";
@ -31,7 +31,7 @@
transition-duration = 500; transition-duration = 500;
transition-left-to-right = true; transition-left-to-right = true;
}; };
modules = [ "pulseaudio" "mpris" ]; modules = ["pulseaudio" "mpris"];
}; };
"custom/weather" = { "custom/weather" = {
orientation = "horizontal"; orientation = "horizontal";
@ -51,12 +51,12 @@
# format-paused = " 󰏤 {title} "; # format-paused = " 󰏤 {title} ";
# format-stopped = "Nothing Playing"; # format-stopped = "Nothing Playing";
# }; # };
tray = { spacing = 10; }; tray = {spacing = 10;};
clock = { format = "{:%a %b %d, %I:%M %p} "; }; clock = {format = "{:%a %b %d, %I:%M %p} ";};
backlight = { backlight = {
device = "intel_backlight"; device = "intel_backlight";
format = "{percent}% {icon}"; format = "{percent}% {icon}";
format-icons = [ "󰃞" "󰃠" ]; format-icons = ["󰃞" "󰃠"];
}; };
battery = { battery = {
states = { states = {
@ -65,9 +65,9 @@
critical = 10; critical = 10;
}; };
format = "{capacity}% {icon}"; format = "{capacity}% {icon}";
format-icons = [ "󰁻" "󰁽" "󰁿" "󰂀" "󰁹" ]; format-icons = ["󰁻" "󰁽" "󰁿" "󰂀" "󰁹"];
}; };
"hyprland/window" = { format = "{class}"; }; "hyprland/window" = {format = "{class}";};
network = { network = {
format-wifi = "{essid} "; format-wifi = "{essid} ";
format-linked = "{ifname} (No IP) "; format-linked = "{ifname} (No IP) ";
@ -81,7 +81,7 @@
format-muted = " {format_source}"; format-muted = " {format_source}";
format-source = "{volume}% "; format-source = "{volume}% ";
format-source-muted = ""; format-source-muted = "";
format-icons = { default = [ "" "" "" ]; }; format-icons = {default = ["" "" ""];};
}; };
}; };
}; };

View file

@ -9,23 +9,21 @@
# width = 1000; # width = 1000;
reload-style-on-change = true; reload-style-on-change = true;
margin = "5px 0px 0px 0px"; margin = "5px 0px 0px 0px";
modules-left = modules-left = ["hyprland/window" "hyprland/workspaces" "network" "clock"];
[ "hyprland/window" "hyprland/workspaces" "network" "clock" ]; modules-right = ["group/hardware" "backlight" "group/adjustable" "custom/weather"];
modules-right =
[ "group/hardware" "backlight" "group/adjustable" "custom/weather" ];
# modules-center = [ "network" "group/hardware" "clock" ]; # modules-center = [ "network" "group/hardware" "clock" ];
"hyprland/workspaces" = { "hyprland/workspaces" = {
active-only = false; active-only = false;
all-outputs = false; all-outputs = false;
format = "{icon}"; format = "{icon}";
persistent-workspaces = { persistent-workspaces = {
eDP-1 = [ 1 ]; eDP-1 = [1];
DP-1 = [ 2 3 4 5 ]; DP-1 = [2 3 4 5];
}; };
}; };
"group/hardware" = { "group/hardware" = {
orientation = "inherit"; orientation = "inherit";
modules = [ "cpu" "battery" ]; modules = ["cpu" "battery"];
}; };
"group/adjustable" = { "group/adjustable" = {
orientation = "inherit"; orientation = "inherit";
@ -33,7 +31,7 @@
transition-duration = 500; transition-duration = 500;
transition-left-to-right = true; transition-left-to-right = true;
}; };
modules = [ "pulseaudio" "mpris" ]; modules = ["pulseaudio" "mpris"];
}; };
"custom/weather" = { "custom/weather" = {
orientation = "horizontal"; orientation = "horizontal";
@ -53,12 +51,12 @@
# format-paused = " 󰏤 {title} "; # format-paused = " 󰏤 {title} ";
# format-stopped = "Nothing Playing"; # format-stopped = "Nothing Playing";
# }; # };
tray = { spacing = 10; }; tray = {spacing = 10;};
clock = { format = "{:%a %b %d, %I:%M %p} "; }; clock = {format = "{:%a %b %d, %I:%M %p} ";};
backlight = { backlight = {
device = "intel_backlight"; device = "intel_backlight";
format = "{percent}% {icon}"; format = "{percent}% {icon}";
format-icons = [ "󰃞" "󰃠" ]; format-icons = ["󰃞" "󰃠"];
}; };
battery = { battery = {
states = { states = {
@ -67,9 +65,9 @@
critical = 10; critical = 10;
}; };
format = "{capacity}% {icon}"; format = "{capacity}% {icon}";
format-icons = [ "󰁻" "󰁽" "󰁿" "󰂀" "󰁹" ]; format-icons = ["󰁻" "󰁽" "󰁿" "󰂀" "󰁹"];
}; };
"hyprland/window" = { format = "{class}"; }; "hyprland/window" = {format = "{class}";};
network = { network = {
format-wifi = "{essid} "; format-wifi = "{essid} ";
format-linked = "{ifname} (No IP) "; format-linked = "{ifname} (No IP) ";
@ -83,7 +81,7 @@
format-muted = " {format_source}"; format-muted = " {format_source}";
format-source = "{volume}% "; format-source = "{volume}% ";
format-source-muted = ""; format-source-muted = "";
format-icons = { default = [ "" "" "" ]; }; format-icons = {default = ["" "" ""];};
}; };
}; };
}; };