Compare commits
107 Commits
412a5eb3d3
...
main
Author | SHA1 | Date | |
---|---|---|---|
9ed92a3f91
|
|||
28ba8e57bc
|
|||
ae6da0ecc4
|
|||
ae4462d98f
|
|||
b0c1be575b
|
|||
4f1f1dfa77
|
|||
a7b7f92d94
|
|||
fae38b30e1
|
|||
e1c6428218
|
|||
a2f5757a36
|
|||
8b67965f22
|
|||
71dffa98ad
|
|||
5dfaa1d593
|
|||
9da8bbeb37
|
|||
d7d2a131aa
|
|||
489e53b3ca
|
|||
2b7235f3e6
|
|||
3266df0ae9
|
|||
541a9e9d7b
|
|||
6149734aa3
|
|||
9a2ff5baf8
|
|||
23a3c153f5
|
|||
cb97b5c09c
|
|||
e1f9112222
|
|||
fae62232cc
|
|||
dcf00b71fe
|
|||
409eb0e4d9
|
|||
168460efff
|
|||
85ff8412a7
|
|||
f26f739f29
|
|||
5be09f440a
|
|||
254ae35c72
|
|||
6eff12ec36
|
|||
30c4ee388f
|
|||
bb14d0ed56
|
|||
229804be02
|
|||
625b1d0249
|
|||
9fe61160a8
|
|||
38a7200862
|
|||
eb85c39a96
|
|||
8809d6a5d4
|
|||
71d0c7a202
|
|||
8a352b287f
|
|||
a7bb2b53f9
|
|||
49c0c5fcc3
|
|||
62d2fd6779
|
|||
a463dec994
|
|||
052499525b
|
|||
9945f74cfa
|
|||
659efbcb3e
|
|||
9cc53818e3
|
|||
f7b84c1de6
|
|||
3beca553a2
|
|||
175171a3c1
|
|||
05d4fb2cf1
|
|||
4f064d5451
|
|||
9e10776439
|
|||
6111707cc0
|
|||
23179e6e92
|
|||
5384754f60
|
|||
4ccbc6e5bf
|
|||
ea4d8c172d
|
|||
53832e7687
|
|||
d26d2d5116
|
|||
a2cd8d467f
|
|||
de46bcead1
|
|||
331c1b5d81
|
|||
98730fbfee
|
|||
3ec72fc172
|
|||
bd4a1763b4
|
|||
d08b631304
|
|||
94f214ef12
|
|||
6411e64da0
|
|||
c7a3adabed
|
|||
3c75b4cb93
|
|||
6494828356
|
|||
4cf04fe0f7
|
|||
0f095e1996
|
|||
73df7f722f | |||
6eb397d3f4 | |||
2dc5b77471 | |||
77eb2ce7fb | |||
42abc2a62e | |||
a53756452f | |||
c31759fc5e | |||
78aab93bb3 | |||
c8a62320b9 | |||
df0af41033 | |||
6a6f369e29 | |||
d0632a4fba | |||
839c1bed3b | |||
6ebcd46468 | |||
cf1bce3de6 | |||
cf9b2896e0 | |||
9e1438f949 | |||
e0512196de | |||
70d894da26 | |||
402245c8ee | |||
6cf91542a2 | |||
6113c8891e | |||
49a621b985 | |||
d12bbd3787 | |||
1c2fa46bce | |||
91adefc48e | |||
0444229bb0 | |||
b49e4656f2 | |||
f80ae52d95 |
2
.gitignore
vendored
Normal file
2
.gitignore
vendored
Normal file
@ -0,0 +1,2 @@
|
|||||||
|
/.direnv/
|
||||||
|
/dconf.nix
|
85
README.md
Normal file
85
README.md
Normal file
@ -0,0 +1,85 @@
|
|||||||
|
# Home Manager Config
|
||||||
|
|
||||||
|
## Systems
|
||||||
|
|
||||||
|
Current available systems are:
|
||||||
|
|
||||||
|
* `pc`
|
||||||
|
My workstation PC running NixOS.
|
||||||
|
* `laptop`
|
||||||
|
My laptop, a Thinkpad X1 Carbon Gen 7, also running NixOS.
|
||||||
|
|
||||||
|
After
|
||||||
|
|
||||||
|
## dconf
|
||||||
|
|
||||||
|
It is possible to observe live changes to dconf via `dconf watch /`.
|
||||||
|
If you want to convert the current dconf to a nix expression enter the dev shell with `nix develop` and do
|
||||||
|
|
||||||
|
```txt
|
||||||
|
dconf dump / | dconf2nix > dconf.nix
|
||||||
|
```
|
||||||
|
|
||||||
|
Build with
|
||||||
|
|
||||||
|
```txt
|
||||||
|
home-manager switch --flake .#[configuration]
|
||||||
|
```
|
||||||
|
|
||||||
|
After first deployment it suffices to do `hms` for `home-manager switch ...`.
|
||||||
|
This relies on the flake being saved to `$HOME/.config/home-manager`.
|
||||||
|
|
||||||
|
## Laptop
|
||||||
|
|
||||||
|
Specific instructions for the `Lenovo Thinkpad Yoga C13 (Morphius)`
|
||||||
|
|
||||||
|
Install Mr.Chromebox's [Firmware Utility Script](https://mrchromebox.tech/#fwscript).
|
||||||
|
|
||||||
|
Download [Fedora Workstation](https://www.fedoraproject.org/en/workstation/download).
|
||||||
|
Boot the Live USB in `minimal graphics mode`.
|
||||||
|
Install like usual but before restarting do edit the machine's kernel boot params like so:
|
||||||
|
|
||||||
|
```txt
|
||||||
|
sudo nano /mnt/sysroot/etc/default/grub
|
||||||
|
```
|
||||||
|
|
||||||
|
Add `iommu=pt` to `GRUB_CMDLINE_LINUX`.
|
||||||
|
Example:
|
||||||
|
|
||||||
|
```txt
|
||||||
|
GRUB_CMDLINE_LINUX="rd.luks.uuid=luks-6ee676a5-8f57-4400-bde6-2f5ff7c1260d nomodeset rhgb iommu=pt quiet"
|
||||||
|
```
|
||||||
|
|
||||||
|
Disable SELinux, as Nix does not work with it enabled
|
||||||
|
|
||||||
|
```txt
|
||||||
|
sudo nano /etc/selinux/config
|
||||||
|
```
|
||||||
|
|
||||||
|
and change `SELINUX=enforcing` to `SELINUX=permissive`
|
||||||
|
|
||||||
|
Resize the `/tmp` directory to allow for building large packages like `nerdfonts`
|
||||||
|
|
||||||
|
```txt
|
||||||
|
mount -o remount,size=25G /tmp
|
||||||
|
systemctl daemon-reload
|
||||||
|
```
|
||||||
|
|
||||||
|
Download the current home-manager config from <https://git.krsnik.at/Kristian/home-manager>.
|
||||||
|
|
||||||
|
```txt
|
||||||
|
cd home-manager
|
||||||
|
nix shell nixpkgs#home-manager --extra-experimental-features "nix-command flakes"
|
||||||
|
home-manager switch --flake .#laptop --extra-experimental-features "nix-command flakes"
|
||||||
|
```
|
||||||
|
|
||||||
|
Configure the following:
|
||||||
|
|
||||||
|
* syncthing
|
||||||
|
* gpg
|
||||||
|
|
||||||
|
In case ssh does not work work do
|
||||||
|
|
||||||
|
```txt
|
||||||
|
gpgconf --kill gpg-agent
|
||||||
|
```
|
379
flake.lock
generated
379
flake.lock
generated
@ -1,13 +1,29 @@
|
|||||||
{
|
{
|
||||||
"nodes": {
|
"nodes": {
|
||||||
|
"appimage-runtime": {
|
||||||
|
"flake": false,
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1652289700,
|
||||||
|
"narHash": "sha256-uxQBDy/JA7uEboTOUmGaZ2FAKY/0dQ9c0A0N8+J+a7I=",
|
||||||
|
"owner": "AppImageCrafters",
|
||||||
|
"repo": "appimage-runtime",
|
||||||
|
"rev": "6500a1ef68e039caba2ebab1c7ed74c2ea9e67a5",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "AppImageCrafters",
|
||||||
|
"repo": "appimage-runtime",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
"flake-compat": {
|
"flake-compat": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1673956053,
|
"lastModified": 1650374568,
|
||||||
"narHash": "sha256-4gtG9iQuiKITOjNQQeQIpoIB6b16fm+504Ch3sNKLd8=",
|
"narHash": "sha256-Z+s0J8/r907g149rllvwhb4pKi8Wam5ij0st8PwAh+E=",
|
||||||
"owner": "edolstra",
|
"owner": "edolstra",
|
||||||
"repo": "flake-compat",
|
"repo": "flake-compat",
|
||||||
"rev": "35bb57c0c8d8b62bbfd284272c928ceb64ddbde9",
|
"rev": "b4a34015c698c7793d592d66adbab377907a2be8",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@ -32,13 +48,29 @@
|
|||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"flake-compat_3": {
|
||||||
|
"flake": false,
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1673956053,
|
||||||
|
"narHash": "sha256-4gtG9iQuiKITOjNQQeQIpoIB6b16fm+504Ch3sNKLd8=",
|
||||||
|
"owner": "edolstra",
|
||||||
|
"repo": "flake-compat",
|
||||||
|
"rev": "35bb57c0c8d8b62bbfd284272c928ceb64ddbde9",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "edolstra",
|
||||||
|
"repo": "flake-compat",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
"flake-utils": {
|
"flake-utils": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1667395993,
|
"lastModified": 1656928814,
|
||||||
"narHash": "sha256-nuEHfE/LcWyuSWnS8t12N1wc105Qtau+/OdUAjtQ0rA=",
|
"narHash": "sha256-RIFfgBuKz6Hp89yRr7+NR5tzIAbn52h8vT6vXkYjZoM=",
|
||||||
"owner": "numtide",
|
"owner": "numtide",
|
||||||
"repo": "flake-utils",
|
"repo": "flake-utils",
|
||||||
"rev": "5aed5285a952e0b949eb3ba02c12fa4fcfef535f",
|
"rev": "7e2a3b3dfd9af950a856d66b0a7d01e3c18aa249",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@ -48,12 +80,48 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"flake-utils_2": {
|
"flake-utils_2": {
|
||||||
|
"inputs": {
|
||||||
|
"systems": "systems"
|
||||||
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1659877975,
|
"lastModified": 1685518550,
|
||||||
"narHash": "sha256-zllb8aq3YO3h8B/U0/J1WBgAL8EX5yWf5pMj3G0NAmc=",
|
"narHash": "sha256-o2d0KcvaXzTrPRIo0kOLV0/QXHhDQ5DTi+OxcjO8xqY=",
|
||||||
"owner": "numtide",
|
"owner": "numtide",
|
||||||
"repo": "flake-utils",
|
"repo": "flake-utils",
|
||||||
"rev": "c0e246b9b83f637f4681389ecabcb2681b4f3af0",
|
"rev": "a1720a10a6cfe8234c0e93907ffe81be440f4cef",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "numtide",
|
||||||
|
"repo": "flake-utils",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"flake-utils_3": {
|
||||||
|
"inputs": {
|
||||||
|
"systems": "systems_2"
|
||||||
|
},
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1681202837,
|
||||||
|
"narHash": "sha256-H+Rh19JDwRtpVPAWp64F+rlEtxUWBAQW28eAi3SRSzg=",
|
||||||
|
"owner": "numtide",
|
||||||
|
"repo": "flake-utils",
|
||||||
|
"rev": "cfacdce06f30d2b68473a46042957675eebb3401",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "numtide",
|
||||||
|
"repo": "flake-utils",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"flake-utils_4": {
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1667395993,
|
||||||
|
"narHash": "sha256-nuEHfE/LcWyuSWnS8t12N1wc105Qtau+/OdUAjtQ0rA=",
|
||||||
|
"owner": "numtide",
|
||||||
|
"repo": "flake-utils",
|
||||||
|
"rev": "5aed5285a952e0b949eb3ba02c12fa4fcfef535f",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@ -91,48 +159,74 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1692099905,
|
"lastModified": 1706981411,
|
||||||
"narHash": "sha256-/pSusGhmIdSdAaywQRFA5dVbfdIzlWQTecM+E46+cJ0=",
|
"narHash": "sha256-cLbLPTL1CDmETVh4p0nQtvoF+FSEjsnJTFpTxhXywhQ=",
|
||||||
"owner": "nix-community",
|
"owner": "nix-community",
|
||||||
"repo": "home-manager",
|
"repo": "home-manager",
|
||||||
"rev": "2a6679aa9cc3872c29ba2a57fe1b71b3e3c5649f",
|
"rev": "652fda4ca6dafeb090943422c34ae9145787af37",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
"owner": "nix-community",
|
"owner": "nix-community",
|
||||||
"ref": "release-23.05",
|
"ref": "release-23.11",
|
||||||
"repo": "home-manager",
|
"repo": "home-manager",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
"nix-appimage": {
|
||||||
|
"inputs": {
|
||||||
|
"appimage-runtime": "appimage-runtime",
|
||||||
|
"flake-compat": "flake-compat",
|
||||||
|
"flake-utils": "flake-utils",
|
||||||
|
"nixpkgs": "nixpkgs_2",
|
||||||
|
"squashfuse": "squashfuse"
|
||||||
|
},
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1695276866,
|
||||||
|
"narHash": "sha256-/BBbYIoDhIPcVwhvau/g4lzrjTnudeRLW5qaTu7LAVs=",
|
||||||
|
"owner": "ralismark",
|
||||||
|
"repo": "nix-appimage",
|
||||||
|
"rev": "17dd6001ec228ea0b8505d6904fc5796d3de5012",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "ralismark",
|
||||||
|
"repo": "nix-appimage",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"nix-index-database": {
|
||||||
|
"inputs": {
|
||||||
|
"nixpkgs": [
|
||||||
|
"nixpkgs"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1707016097,
|
||||||
|
"narHash": "sha256-V4lHr6hFQ3rK650dh64Xffxsf4kse9vUYWsM+ldjkco=",
|
||||||
|
"owner": "Mic92",
|
||||||
|
"repo": "nix-index-database",
|
||||||
|
"rev": "3e3dad2808379c522138e2e8b0eb73500721a237",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "Mic92",
|
||||||
|
"repo": "nix-index-database",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
"nixpkgs": {
|
"nixpkgs": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1692794066,
|
"lastModified": 1707091808,
|
||||||
"narHash": "sha256-H0aG8r16dj0x/Wz6wQhQxc9V7AsObOiHPaKxQgH6Y08=",
|
"narHash": "sha256-LahKBAfGbY836gtpVNnWwBTIzN7yf/uYM/S0g393r0Y=",
|
||||||
"owner": "nixos",
|
"owner": "nixos",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "fc944919f743bb22379dddf18dcb72db6cff84aa",
|
"rev": "9f2ee8c91ac42da3ae6c6a1d21555f283458247e",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
"owner": "nixos",
|
"owner": "nixos",
|
||||||
"ref": "nixos-23.05",
|
"ref": "nixos-23.11",
|
||||||
"repo": "nixpkgs",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"nixpkgs-master": {
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1692973538,
|
|
||||||
"narHash": "sha256-BgwQ9LhSj8bRPlU4WVD9+q2dkQsWTD4ampHADbr2I20=",
|
|
||||||
"owner": "nixos",
|
|
||||||
"repo": "nixpkgs",
|
|
||||||
"rev": "9be946f3129e3aec29ff84d3b0230cf6014cdd9c",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "nixos",
|
|
||||||
"ref": "master",
|
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
@ -153,61 +247,28 @@
|
|||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"nixpkgs-unstable": {
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1692734709,
|
|
||||||
"narHash": "sha256-SCFnyHCyYjwEmgUsHDDuU0TsbVMKeU1vwkR+r7uS2Rg=",
|
|
||||||
"owner": "nixos",
|
|
||||||
"repo": "nixpkgs",
|
|
||||||
"rev": "b85ed9dcbf187b909ef7964774f8847d554fab3b",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "nixos",
|
|
||||||
"ref": "nixos-unstable",
|
|
||||||
"repo": "nixpkgs",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"nixpkgs_2": {
|
"nixpkgs_2": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1675309347,
|
"lastModified": 1659526864,
|
||||||
"narHash": "sha256-D3CQ6HRDT2m3XJlrzb5jKq4vNFR5xFTEFKC7iSjlFpM=",
|
"narHash": "sha256-XFzXrc1+6DZb9hBgHfEzfwylPUSqVFJbQPs8eOgYufU=",
|
||||||
"owner": "NixOS",
|
"owner": "NixOS",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "006c3bd4dd2f5d1d2094047f307cbf9e2b73d9c5",
|
"rev": "478f3cbc8448b5852539d785fbfe9a53304133be",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
"owner": "NixOS",
|
"id": "nixpkgs",
|
||||||
"ref": "nixpkgs-unstable",
|
"ref": "nixos-22.05",
|
||||||
"repo": "nixpkgs",
|
"type": "indirect"
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"nixpkgs_3": {
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1689088367,
|
|
||||||
"narHash": "sha256-Y2tl2TlKCWEHrOeM9ivjCLlRAKH3qoPUE/emhZECU14=",
|
|
||||||
"owner": "NixOS",
|
|
||||||
"repo": "nixpkgs",
|
|
||||||
"rev": "5c9ddb86679c400d6b7360797b8a22167c2053f8",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "NixOS",
|
|
||||||
"ref": "release-23.05",
|
|
||||||
"repo": "nixpkgs",
|
|
||||||
"type": "github"
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"nur": {
|
"nur": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1692971158,
|
"lastModified": 1707245063,
|
||||||
"narHash": "sha256-1dZ9WJaPs1lCnRRctDgKwOXIn/t+UaiwxwcVksFXwzQ=",
|
"narHash": "sha256-1E7kPslBZpGTmz7UTR/HnpCy8Rfc4Kv/njBiTTF1G2g=",
|
||||||
"owner": "nix-community",
|
"owner": "nix-community",
|
||||||
"repo": "NUR",
|
"repo": "NUR",
|
||||||
"rev": "ee2675bab6f3120ada6671204e9eca40da2fb180",
|
"rev": "cd11db9649316bcd231a6ab9c677284ee0d8c184",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@ -218,7 +279,7 @@
|
|||||||
},
|
},
|
||||||
"pre-commit-hooks": {
|
"pre-commit-hooks": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"flake-compat": "flake-compat",
|
"flake-compat": "flake-compat_3",
|
||||||
"flake-utils": [
|
"flake-utils": [
|
||||||
"wallpaper",
|
"wallpaper",
|
||||||
"flake-utils"
|
"flake-utils"
|
||||||
@ -247,18 +308,152 @@
|
|||||||
"root": {
|
"root": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"home-manager": "home-manager",
|
"home-manager": "home-manager",
|
||||||
|
"nix-index-database": "nix-index-database",
|
||||||
"nixpkgs": "nixpkgs",
|
"nixpkgs": "nixpkgs",
|
||||||
"nixpkgs-master": "nixpkgs-master",
|
|
||||||
"nixpkgs-unstable": "nixpkgs-unstable",
|
|
||||||
"nur": "nur",
|
"nur": "nur",
|
||||||
"wallpaper": "wallpaper",
|
"scanned-image-extractor": "scanned-image-extractor",
|
||||||
"zig": "zig"
|
"spicetify": "spicetify",
|
||||||
|
"starc": "starc",
|
||||||
|
"vscode-extensions": "vscode-extensions",
|
||||||
|
"wallpaper": "wallpaper"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"scanned-image-extractor": {
|
||||||
|
"inputs": {
|
||||||
|
"nix-appimage": "nix-appimage",
|
||||||
|
"nixpkgs": [
|
||||||
|
"nixpkgs"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1707220285,
|
||||||
|
"narHash": "sha256-JWXtWnw07xLTPeE51eiNS3MeMltP11DiS5cYsT1r1Tc=",
|
||||||
|
"ref": "refs/heads/main",
|
||||||
|
"rev": "846a94c50f089cafe49903ce6e157fe714520a8a",
|
||||||
|
"revCount": 11,
|
||||||
|
"type": "git",
|
||||||
|
"url": "https://git.krsnik.at/Kristian/scanned-image-extractor.git"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"type": "git",
|
||||||
|
"url": "https://git.krsnik.at/Kristian/scanned-image-extractor.git"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"spicetify": {
|
||||||
|
"inputs": {
|
||||||
|
"flake-utils": "flake-utils_2",
|
||||||
|
"nixpkgs": [
|
||||||
|
"nixpkgs"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1704167711,
|
||||||
|
"narHash": "sha256-kFDq+kf/Di/P8bq5sUP8pVwRkrSVrABksBjMPmLic3s=",
|
||||||
|
"owner": "the-argus",
|
||||||
|
"repo": "spicetify-nix",
|
||||||
|
"rev": "1325416f951d6a82cfddb1289864ad782e2b87c4",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "the-argus",
|
||||||
|
"repo": "spicetify-nix",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"squashfuse": {
|
||||||
|
"flake": false,
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1655253282,
|
||||||
|
"narHash": "sha256-RIhDXzpmrYUOwj5OYzjWKJw0cwE+L3t/9pIkg/hFXA0=",
|
||||||
|
"owner": "vasi",
|
||||||
|
"repo": "squashfuse",
|
||||||
|
"rev": "d1d7ddafb765098b34239eacaf2f9abee1fbc27c",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "vasi",
|
||||||
|
"repo": "squashfuse",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"starc": {
|
||||||
|
"inputs": {
|
||||||
|
"nixpkgs": [
|
||||||
|
"nixpkgs"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1707220280,
|
||||||
|
"narHash": "sha256-VBgd9wOebW7RWym52434Mgz5w2k1csgw35JAe28Buvs=",
|
||||||
|
"ref": "refs/heads/main",
|
||||||
|
"rev": "5586cecb4f76dea16f38b2c0678904edbcfb191b",
|
||||||
|
"revCount": 18,
|
||||||
|
"type": "git",
|
||||||
|
"url": "https://git.krsnik.at/Kristian/starc-flake.git"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"type": "git",
|
||||||
|
"url": "https://git.krsnik.at/Kristian/starc-flake.git"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"systems": {
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1681028828,
|
||||||
|
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
|
||||||
|
"owner": "nix-systems",
|
||||||
|
"repo": "default",
|
||||||
|
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "nix-systems",
|
||||||
|
"repo": "default",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"systems_2": {
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1681028828,
|
||||||
|
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
|
||||||
|
"owner": "nix-systems",
|
||||||
|
"repo": "default",
|
||||||
|
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "nix-systems",
|
||||||
|
"repo": "default",
|
||||||
|
"type": "github"
|
||||||
|
}
|
||||||
|
},
|
||||||
|
"vscode-extensions": {
|
||||||
|
"inputs": {
|
||||||
|
"flake-compat": "flake-compat_2",
|
||||||
|
"flake-utils": "flake-utils_3",
|
||||||
|
"nixpkgs": [
|
||||||
|
"nixpkgs"
|
||||||
|
]
|
||||||
|
},
|
||||||
|
"locked": {
|
||||||
|
"lastModified": 1707182119,
|
||||||
|
"narHash": "sha256-Egt1PmjNAbx2nS0h/iWpaTCcOzLPHpRXzTJBt3waEAs=",
|
||||||
|
"owner": "nix-community",
|
||||||
|
"repo": "nix-vscode-extensions",
|
||||||
|
"rev": "4e7767c214364217e0a7611dca3f3420555ceb20",
|
||||||
|
"type": "github"
|
||||||
|
},
|
||||||
|
"original": {
|
||||||
|
"owner": "nix-community",
|
||||||
|
"repo": "nix-vscode-extensions",
|
||||||
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"wallpaper": {
|
"wallpaper": {
|
||||||
"inputs": {
|
"inputs": {
|
||||||
"flake-utils": "flake-utils",
|
"flake-utils": "flake-utils_4",
|
||||||
"nixpkgs": "nixpkgs_2",
|
"nixpkgs": [
|
||||||
|
"nixpkgs"
|
||||||
|
],
|
||||||
"pre-commit-hooks": "pre-commit-hooks"
|
"pre-commit-hooks": "pre-commit-hooks"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
@ -274,26 +469,6 @@
|
|||||||
"repo": "nix-wallpaper",
|
"repo": "nix-wallpaper",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
|
||||||
"zig": {
|
|
||||||
"inputs": {
|
|
||||||
"flake-compat": "flake-compat_2",
|
|
||||||
"flake-utils": "flake-utils_2",
|
|
||||||
"nixpkgs": "nixpkgs_3"
|
|
||||||
},
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1692971964,
|
|
||||||
"narHash": "sha256-fvswEIz5R1jiuVHEII655I8PcNz/L+ED11YEZl0pqS0=",
|
|
||||||
"owner": "mitchellh",
|
|
||||||
"repo": "zig-overlay",
|
|
||||||
"rev": "d4ce4f679e360c87303075c1ff3e8496e9702348",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "mitchellh",
|
|
||||||
"repo": "zig-overlay",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"root": "root",
|
"root": "root",
|
||||||
|
138
flake.nix
138
flake.nix
@ -2,73 +2,137 @@
|
|||||||
description = "Home Manager configuration of kristian";
|
description = "Home Manager configuration of kristian";
|
||||||
|
|
||||||
inputs = {
|
inputs = {
|
||||||
nixpkgs.url = "github:nixos/nixpkgs/nixos-23.05";
|
nixpkgs.url = "github:nixos/nixpkgs/nixos-23.11";
|
||||||
nixpkgs-unstable.url = "github:nixos/nixpkgs/nixos-unstable";
|
# nixpkgs-unstable.url = "github:nixos/nixpkgs/nixos-unstable";
|
||||||
nixpkgs-master.url = "github:nixos/nixpkgs/master";
|
# nixpkgs-master.url = "github:nixos/nixpkgs/master";
|
||||||
|
|
||||||
home-manager = {
|
home-manager = {
|
||||||
url = "github:nix-community/home-manager/release-23.05";
|
url = "github:nix-community/home-manager/release-23.11";
|
||||||
inputs.nixpkgs.follows = "nixpkgs";
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
};
|
};
|
||||||
|
|
||||||
# Nix User Repository
|
nur = {
|
||||||
nur.url = "github:nix-community/NUR";
|
url = "github:nix-community/NUR";
|
||||||
|
};
|
||||||
|
|
||||||
# Zig
|
wallpaper = {
|
||||||
zig.url = "github:mitchellh/zig-overlay";
|
url = "github:lunik1/nix-wallpaper";
|
||||||
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
|
};
|
||||||
|
|
||||||
# Wallpaper
|
nix-index-database = {
|
||||||
wallpaper.url = "github:lunik1/nix-wallpaper";
|
url = "github:Mic92/nix-index-database";
|
||||||
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
|
};
|
||||||
|
|
||||||
|
vscode-extensions = {
|
||||||
|
url = "github:nix-community/nix-vscode-extensions";
|
||||||
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
|
};
|
||||||
|
|
||||||
|
spicetify = {
|
||||||
|
url = "github:the-argus/spicetify-nix";
|
||||||
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
|
};
|
||||||
|
|
||||||
|
starc = {
|
||||||
|
url = "git+https://git.krsnik.at/Kristian/starc-flake.git";
|
||||||
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
|
};
|
||||||
|
|
||||||
|
scanned-image-extractor = {
|
||||||
|
url = "git+https://git.krsnik.at/Kristian/scanned-image-extractor.git";
|
||||||
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
outputs = {
|
outputs = {
|
||||||
self,
|
self,
|
||||||
nixpkgs,
|
nixpkgs,
|
||||||
nixpkgs-unstable,
|
# nixpkgs-unstable,
|
||||||
nixpkgs-master,
|
# nixpkgs-master,
|
||||||
home-manager,
|
home-manager,
|
||||||
nur,
|
nur,
|
||||||
zig,
|
|
||||||
wallpaper,
|
wallpaper,
|
||||||
|
nix-index-database,
|
||||||
|
vscode-extensions,
|
||||||
|
spicetify,
|
||||||
|
starc,
|
||||||
|
scanned-image-extractor,
|
||||||
}: let
|
}: let
|
||||||
system = "x86_64-linux";
|
system = "x86_64-linux";
|
||||||
pkgs = nixpkgs.legacyPackages.${system};
|
pkgs = nixpkgs.legacyPackages.${system};
|
||||||
in {
|
in {
|
||||||
formatter.${system} = nixpkgs.legacyPackages.${system}.alejandra;
|
formatter.${system} = pkgs.alejandra;
|
||||||
|
|
||||||
homeConfigurations = {
|
homeConfigurations = let
|
||||||
kristian = home-manager.lib.homeManagerConfiguration {
|
commonModules = [
|
||||||
inherit pkgs;
|
./systems/common
|
||||||
|
|
||||||
modules = [
|
|
||||||
./home
|
|
||||||
{
|
{
|
||||||
_module.args.wallpaper = wallpaper.packages.${system}.default;
|
_module.args = {
|
||||||
|
inherit spicetify;
|
||||||
|
wallpaper = wallpaper.packages.${system}.default;
|
||||||
|
libs = import ./libs;
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
|
spicetify.homeManagerModule
|
||||||
|
|
||||||
nur.nixosModules.nur
|
nur.nixosModules.nur
|
||||||
|
|
||||||
|
nix-index-database.hmModules.nix-index
|
||||||
|
{
|
||||||
|
programs.nix-index-database.comma.enable = true;
|
||||||
|
}
|
||||||
|
|
||||||
{
|
{
|
||||||
nixpkgs.overlays = [
|
nixpkgs.overlays = [
|
||||||
zig.overlays.default # Adds zig
|
vscode-extensions.overlays.default
|
||||||
( # https://github.com/nix-community/home-manager/issues/1538#issuecomment-706627100
|
|
||||||
final: prev: {
|
starc.overlays.default
|
||||||
unstable = import nixpkgs-unstable {
|
scanned-image-extractor.overlays.default
|
||||||
system = final.system;
|
|
||||||
config.allowUnfreePredicate = _: true;
|
# ( # https://github.com/nix-community/home-manager/issues/1538#issuecomment-706627100
|
||||||
};
|
# final: prev: {
|
||||||
master = import nixpkgs-master {
|
# unstable = import nixpkgs-unstable {
|
||||||
system = final.system;
|
# system = final.system;
|
||||||
config.allowUnfreePredicate = _: true;
|
# config.allowUnfreePredicate = _: true;
|
||||||
};
|
# };
|
||||||
}
|
# master = import nixpkgs-master {
|
||||||
)
|
# system = final.system;
|
||||||
( # Overrides davinci-resolve with the unstable version because of https://github.com/NixOS/nixpkgs/pull/246074
|
# config.allowUnfreePredicate = _: true;
|
||||||
final: prev: {davinci-resolve = final.unstable.davinci-resolve;}
|
# };
|
||||||
)
|
# }
|
||||||
|
# )
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
];
|
];
|
||||||
|
in {
|
||||||
|
pc = home-manager.lib.homeManagerConfiguration {
|
||||||
|
inherit pkgs;
|
||||||
|
|
||||||
|
modules =
|
||||||
|
[
|
||||||
|
./systems/pc
|
||||||
|
]
|
||||||
|
++ commonModules;
|
||||||
};
|
};
|
||||||
|
|
||||||
|
laptop = home-manager.lib.homeManagerConfiguration {
|
||||||
|
inherit pkgs;
|
||||||
|
|
||||||
|
modules =
|
||||||
|
[
|
||||||
|
./systems/laptop
|
||||||
|
]
|
||||||
|
++ commonModules;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
devShells.${system}.default = pkgs.mkShellNoCC {
|
||||||
|
packages = [
|
||||||
|
pkgs.dconf2nix
|
||||||
|
];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
@ -1,8 +0,0 @@
|
|||||||
{enable}: {
|
|
||||||
inherit enable;
|
|
||||||
shellAliases = {
|
|
||||||
ll = "ls -lh";
|
|
||||||
la = "ls -lah";
|
|
||||||
".." = "cd ..";
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,77 +0,0 @@
|
|||||||
{
|
|
||||||
config,
|
|
||||||
pkgs,
|
|
||||||
lib,
|
|
||||||
options,
|
|
||||||
specialArgs,
|
|
||||||
modulesPath,
|
|
||||||
wallpaper,
|
|
||||||
}: {
|
|
||||||
nixpkgs.config.allowUnfreePredicate = _: true;
|
|
||||||
|
|
||||||
home.stateVersion = "23.05";
|
|
||||||
home.username = "kristian";
|
|
||||||
home.homeDirectory = "/home/kristian";
|
|
||||||
|
|
||||||
home.sessionVariables = {
|
|
||||||
# Electron programms won't render correctly under wayland without this
|
|
||||||
NIXOS_OZONE_WL = 1;
|
|
||||||
};
|
|
||||||
|
|
||||||
# TODO: Change for Laptop
|
|
||||||
targets.genericLinux.enable = false; # Enable on non-nixos ditros
|
|
||||||
|
|
||||||
# Keyboard Layout
|
|
||||||
home.keyboard.layout = "at"; # NOTE: Set by Hyprland config
|
|
||||||
|
|
||||||
# Programs (additional programs)
|
|
||||||
home.packages = import ./packages.nix {inherit pkgs;};
|
|
||||||
|
|
||||||
# Services
|
|
||||||
services = {
|
|
||||||
copyq.enable = true;
|
|
||||||
};
|
|
||||||
|
|
||||||
# Programs
|
|
||||||
programs = {
|
|
||||||
home-manager.enable = true; # Allow home-manager to manage itself
|
|
||||||
mpv.enable = true;
|
|
||||||
obs-studio.enable = true;
|
|
||||||
yt-dlp.enable = true;
|
|
||||||
|
|
||||||
bash = import ./bash.nix {enable = true;};
|
|
||||||
vscode = import ./vscode.nix {
|
|
||||||
enable = true;
|
|
||||||
inherit pkgs;
|
|
||||||
};
|
|
||||||
direnv = import ./direnv.nix {enable = true;};
|
|
||||||
git = import ./git.nix {enable = true;};
|
|
||||||
thunderbird = import ./thunderbird.nix {enable = true;};
|
|
||||||
|
|
||||||
neovim = import ./nvim {
|
|
||||||
enable = true;
|
|
||||||
inherit pkgs;
|
|
||||||
};
|
|
||||||
|
|
||||||
firefox = import ./firefox.nix {
|
|
||||||
enable = true;
|
|
||||||
nur = config.nur;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
xdg.mimeApps = {
|
|
||||||
enable = true;
|
|
||||||
defaultApplications = {
|
|
||||||
"image/png" = ["org.gnome.eog.desktop"];
|
|
||||||
"image/jpeg" = ["org.gnome.eog.desktop"];
|
|
||||||
"video/webm" = ["mpv.desktop"];
|
|
||||||
"application/pdf" = ["org.gnome.Evince.desktop"];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
# Gnome settings
|
|
||||||
dconf.settings = import ./gnome.nix {
|
|
||||||
inherit lib;
|
|
||||||
inherit wallpaper;
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,5 +0,0 @@
|
|||||||
{enable}: {
|
|
||||||
inherit enable;
|
|
||||||
nix-direnv.enable = enable;
|
|
||||||
enableBashIntegration = true;
|
|
||||||
}
|
|
@ -1,24 +0,0 @@
|
|||||||
{
|
|
||||||
nur,
|
|
||||||
enable,
|
|
||||||
}: {
|
|
||||||
inherit enable;
|
|
||||||
profiles.kristian = {
|
|
||||||
isDefault = true;
|
|
||||||
search.default = "DuckDuckGo";
|
|
||||||
search.force = true;
|
|
||||||
extensions = builtins.attrValues {
|
|
||||||
inherit
|
|
||||||
(nur.repos.rycee.firefox-addons)
|
|
||||||
ublock-origin
|
|
||||||
umatrix
|
|
||||||
sponsorblock
|
|
||||||
sidebery
|
|
||||||
;
|
|
||||||
};
|
|
||||||
settings = {
|
|
||||||
"extensions.pocket.enabled" = false;
|
|
||||||
"toolkit.legacyUserProfileCustomizations.stylesheets" = true;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,6 +0,0 @@
|
|||||||
{enable}: {
|
|
||||||
inherit enable;
|
|
||||||
userName = "Kristian Krsnik";
|
|
||||||
userEmail = "git@krsnik.at";
|
|
||||||
extraConfig = {init.defaultBranch = "main";};
|
|
||||||
}
|
|
@ -1,71 +0,0 @@
|
|||||||
{
|
|
||||||
lib,
|
|
||||||
wallpaper,
|
|
||||||
}: {
|
|
||||||
# Use `dconf watch /` to track stateful changes you are doing, then set them here.
|
|
||||||
"org/gnome/desktop/interface" = {
|
|
||||||
color-scheme = "prefer-dark";
|
|
||||||
gtk-theme = "Adwaita-dark";
|
|
||||||
};
|
|
||||||
"org/gnome/desktop/background" = let
|
|
||||||
width = 3840;
|
|
||||||
height = 2160;
|
|
||||||
in {
|
|
||||||
picture-uri = "file://${wallpaper.override {
|
|
||||||
preset = "nord-snow-aurora";
|
|
||||||
inherit width;
|
|
||||||
inherit height;
|
|
||||||
}}/share/wallpapers/nixos-wallpaper.png";
|
|
||||||
picture-uri-dark = "file://${wallpaper.override {
|
|
||||||
preset = "nord-night-aurora";
|
|
||||||
inherit width;
|
|
||||||
inherit height;
|
|
||||||
}}/share/wallpapers/nixos-wallpaper.png";
|
|
||||||
};
|
|
||||||
"org/gnome/desktop/wm/keybindings" = {
|
|
||||||
switch-to-workspace-left = ["<Alt>1"];
|
|
||||||
switch-to-workspace-right = ["<Alt>2"];
|
|
||||||
move-to-workspace-left = ["<Shift><Alt>1"];
|
|
||||||
move-to-workspace-right = ["<Shift><Alt>2"];
|
|
||||||
};
|
|
||||||
"org/gnome/settings-daemon/plugins/media-keys/custom-keybindings/custom0" = {
|
|
||||||
binding = "<Shift><Alt>a";
|
|
||||||
command = "kgx";
|
|
||||||
name = "Console";
|
|
||||||
};
|
|
||||||
"org/gnome/settings-daemon/plugins/media-keys/custom-keybindings/custom1" = {
|
|
||||||
binding = "<Shift><Alt>f";
|
|
||||||
command = "nautilus";
|
|
||||||
name = "File Manager";
|
|
||||||
};
|
|
||||||
"org/gnome/settings-daemon/plugins/media-keys" = {
|
|
||||||
custom-keybindings = [
|
|
||||||
"/org/gnome/settings-daemon/plugins/media-keys/custom-keybindings/custom0/"
|
|
||||||
"/org/gnome/settings-daemon/plugins/media-keys/custom-keybindings/custom1/"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
"org/gnome/settings-daemon/plugins/power" = {
|
|
||||||
sleep-inactive-ac-type = "nothing"; # Automatic suspend/hibernation creates a suspend/hibernation loop
|
|
||||||
power-button-action = "suspend";
|
|
||||||
};
|
|
||||||
"org/gnome/mutter" = {
|
|
||||||
edge-tiling = true;
|
|
||||||
dynamic-workspaces = true;
|
|
||||||
};
|
|
||||||
"org/gnome/Console" = {
|
|
||||||
theme = "auto";
|
|
||||||
};
|
|
||||||
"org/gnome/simple-scan" = {
|
|
||||||
text-dpi = 300;
|
|
||||||
};
|
|
||||||
"org/gnome/shell" = {
|
|
||||||
disable-user-extensions = false;
|
|
||||||
enabled-extensions = [
|
|
||||||
"quick-settings-audio-panel@rayzeq.github.io"
|
|
||||||
"places-menu@gnome-shell-extensions.gcampax.github.com"
|
|
||||||
"launch-new-instance@gnome-shell-extensions.gcampax.github.com"
|
|
||||||
"trayIconsReloaded@selfmade.pl"
|
|
||||||
"espresso@coadmunkee.github.com"
|
|
||||||
];
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,59 +0,0 @@
|
|||||||
{
|
|
||||||
pkgs,
|
|
||||||
enable,
|
|
||||||
}: {
|
|
||||||
inherit enable;
|
|
||||||
defaultEditor = true;
|
|
||||||
viAlias = true;
|
|
||||||
vimAlias = true;
|
|
||||||
vimdiffAlias = true;
|
|
||||||
|
|
||||||
plugins = builtins.attrValues ({
|
|
||||||
inherit
|
|
||||||
(pkgs.vimPlugins)
|
|
||||||
telescope-nvim # fuzzy finder
|
|
||||||
tokyonight-nvim # theme
|
|
||||||
undotree # undotree
|
|
||||||
vim-fugitive # git integration
|
|
||||||
nvim-treesitter # syntax highlighting
|
|
||||||
|
|
||||||
# Autocomplete and LSP
|
|
||||||
|
|
||||||
nvim-lspconfig
|
|
||||||
nvim-cmp
|
|
||||||
cmp-nvim-lsp
|
|
||||||
luasnip
|
|
||||||
;
|
|
||||||
}
|
|
||||||
// {
|
|
||||||
# Parsers for syntax highlighting
|
|
||||||
inherit
|
|
||||||
(pkgs.vimPlugins.nvim-treesitter-parsers)
|
|
||||||
nix
|
|
||||||
zig
|
|
||||||
python
|
|
||||||
vim
|
|
||||||
vimdoc
|
|
||||||
markdown
|
|
||||||
dockerfile
|
|
||||||
yaml
|
|
||||||
json
|
|
||||||
toml
|
|
||||||
lua
|
|
||||||
c
|
|
||||||
glsl
|
|
||||||
bash
|
|
||||||
;
|
|
||||||
});
|
|
||||||
extraPackages = [pkgs.nodePackages.pyright];
|
|
||||||
extraLuaConfig =
|
|
||||||
builtins.readFile ./keybinds.lua
|
|
||||||
+ builtins.readFile ./colors.lua
|
|
||||||
+ builtins.readFile ./undotree.lua
|
|
||||||
+ builtins.readFile ./fugitive.lua
|
|
||||||
+ builtins.readFile ./treesitter.lua
|
|
||||||
+ builtins.readFile ./telescope.lua
|
|
||||||
+ builtins.readFile ./cmp.lua
|
|
||||||
+ builtins.readFile ./lspconfig.lua;
|
|
||||||
extraConfig = "set number relativenumber";
|
|
||||||
}
|
|
@ -1,38 +0,0 @@
|
|||||||
{pkgs}:
|
|
||||||
with pkgs; [
|
|
||||||
# Basic utils
|
|
||||||
unzip
|
|
||||||
magic-wormhole
|
|
||||||
|
|
||||||
# Important graphical applications
|
|
||||||
keepassxc
|
|
||||||
logseq
|
|
||||||
xournalpp
|
|
||||||
onlyoffice-bin
|
|
||||||
|
|
||||||
# Communication
|
|
||||||
webcord
|
|
||||||
telegram-desktop
|
|
||||||
signal-desktop
|
|
||||||
element-desktop
|
|
||||||
|
|
||||||
# image editor
|
|
||||||
gimp
|
|
||||||
davinci-resolve
|
|
||||||
|
|
||||||
# games
|
|
||||||
osu-lazer
|
|
||||||
|
|
||||||
# Misc
|
|
||||||
nerdfonts # Font with glyphs for status bar
|
|
||||||
comma # Run any binary from the repos with a comma `, cowsay neato`
|
|
||||||
|
|
||||||
# Gnome extension
|
|
||||||
gnomeExtensions.quick-settings-audio-panel
|
|
||||||
gnomeExtensions.tray-icons-reloaded
|
|
||||||
gnomeExtensions.espresso
|
|
||||||
|
|
||||||
gnome-decoder
|
|
||||||
|
|
||||||
tor-browser-bundle-bin
|
|
||||||
]
|
|
@ -1,6 +0,0 @@
|
|||||||
{enable}: {
|
|
||||||
inherit enable;
|
|
||||||
profiles.kristian = {
|
|
||||||
isDefault = true;
|
|
||||||
};
|
|
||||||
}
|
|
@ -1,64 +0,0 @@
|
|||||||
{
|
|
||||||
enable,
|
|
||||||
pkgs,
|
|
||||||
}: {
|
|
||||||
inherit enable;
|
|
||||||
enableUpdateCheck = false;
|
|
||||||
enableExtensionUpdateCheck = false;
|
|
||||||
keybindings = [
|
|
||||||
{
|
|
||||||
key = "alt+a";
|
|
||||||
command = "editor.action.commentLine";
|
|
||||||
when = "editorTextFocus && !editorReadonly";
|
|
||||||
}
|
|
||||||
];
|
|
||||||
extensions = with pkgs.vscode-extensions; [
|
|
||||||
jnoortheen.nix-ide
|
|
||||||
arrterian.nix-env-selector
|
|
||||||
mkhl.direnv
|
|
||||||
ms-python.python
|
|
||||||
ms-python.vscode-pylance
|
|
||||||
james-yu.latex-workshop
|
|
||||||
github.copilot
|
|
||||||
davidanson.vscode-markdownlint
|
|
||||||
tamasfe.even-better-toml
|
|
||||||
asciidoctor.asciidoctor-vscode
|
|
||||||
];
|
|
||||||
userSettings = {
|
|
||||||
"window.menuBarVisibility" = "hidden";
|
|
||||||
"[nix]" = {
|
|
||||||
"editor.formatOnSave" = true;
|
|
||||||
"editor.formatOnSaveMode" = "file"; # modificationsIfAvailable does not work
|
|
||||||
};
|
|
||||||
"[python]" = {
|
|
||||||
"editor.formatOnSave" = true;
|
|
||||||
"editor.formatOnSaveMode" = "modificationsIfAvailable";
|
|
||||||
};
|
|
||||||
"[latex]" = {
|
|
||||||
"editor.formatOnSave" = true;
|
|
||||||
"editor.formatOnSaveMode" = "file"; # modificationsIfAvailable does not work
|
|
||||||
};
|
|
||||||
"[toml]" = {
|
|
||||||
"editor.formatOnSave" = true;
|
|
||||||
"editor.modificationsIfAvailable" = "file";
|
|
||||||
};
|
|
||||||
"python.formatting.autopep8Path" = "${pkgs.python311Packages.autopep8}/bin/autopep8";
|
|
||||||
"nix.enableLanguageServer" = true;
|
|
||||||
"nix.serverPath" = "${pkgs.nil}/bin/nil";
|
|
||||||
"nix.serverSettings" = {
|
|
||||||
nil = {
|
|
||||||
formatting = {command = ["${pkgs.alejandra}/bin/alejandra"];};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
"direnv.path.executable" = "${pkgs.direnv}/bin/direnv";
|
|
||||||
"latex-workshop.latex.outDir" = "%DIR%/out";
|
|
||||||
|
|
||||||
"terminal.integrated.profiles.linux" = {
|
|
||||||
"bash" = {
|
|
||||||
"path" = "${pkgs.bashInteractive}/bin/bash";
|
|
||||||
"args" = [];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
"terminal.integrated.defaultProfile.linux" = "bash";
|
|
||||||
};
|
|
||||||
}
|
|
16
libs/default.nix
Normal file
16
libs/default.nix
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
{
|
||||||
|
mkAutostart = {
|
||||||
|
pkgs,
|
||||||
|
name,
|
||||||
|
command,
|
||||||
|
}: {
|
||||||
|
source = "${
|
||||||
|
pkgs.makeDesktopItem {
|
||||||
|
name = "${name}-autostart";
|
||||||
|
desktopName = "${name}-autostart";
|
||||||
|
exec = command;
|
||||||
|
noDisplay = true;
|
||||||
|
}
|
||||||
|
}/share/applications/${name}-autostart.desktop";
|
||||||
|
};
|
||||||
|
}
|
16
systems/common/bash.nix
Normal file
16
systems/common/bash.nix
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
{...}: {
|
||||||
|
programs.bash = {
|
||||||
|
enable = true;
|
||||||
|
|
||||||
|
initExtra = ''
|
||||||
|
PS1='\[\033[1;32m\][\[\e]0;\u@\h: \w\a\]\w]\$\[\033[0m\] '
|
||||||
|
'';
|
||||||
|
|
||||||
|
shellAliases = {
|
||||||
|
code = "codium"; # Alias VSCode with VSCodium
|
||||||
|
ll = "ls -lh";
|
||||||
|
la = "ls -lah";
|
||||||
|
".." = "cd ..";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
57
systems/common/default.nix
Normal file
57
systems/common/default.nix
Normal file
@ -0,0 +1,57 @@
|
|||||||
|
{
|
||||||
|
config,
|
||||||
|
lib,
|
||||||
|
options,
|
||||||
|
specialArgs,
|
||||||
|
modulesPath,
|
||||||
|
}: {
|
||||||
|
home.stateVersion = "23.05";
|
||||||
|
home.username = "kristian";
|
||||||
|
home.homeDirectory = "/home/kristian";
|
||||||
|
|
||||||
|
home.sessionVariables = {
|
||||||
|
# Electron programms won't render correctly under wayland without this
|
||||||
|
NIXOS_OZONE_WL = 1;
|
||||||
|
};
|
||||||
|
|
||||||
|
# Keyboard Layout
|
||||||
|
home.keyboard.layout = "at";
|
||||||
|
|
||||||
|
imports = [
|
||||||
|
./bash.nix
|
||||||
|
./direnv.nix
|
||||||
|
./firefox.nix
|
||||||
|
./fonts.nix
|
||||||
|
./git.nix
|
||||||
|
./gnome.nix
|
||||||
|
./gpg.nix
|
||||||
|
./nvim
|
||||||
|
./obs.nix
|
||||||
|
./packages.nix
|
||||||
|
./spiceify.nix
|
||||||
|
./thunderbird.nix
|
||||||
|
./vscode.nix
|
||||||
|
./mpv.nix
|
||||||
|
];
|
||||||
|
|
||||||
|
# Programs
|
||||||
|
programs = {
|
||||||
|
home-manager.enable = true; # Allow home-manager to manage itself
|
||||||
|
yt-dlp.enable = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
xdg.mimeApps = {
|
||||||
|
enable = true;
|
||||||
|
|
||||||
|
defaultApplications = let
|
||||||
|
imageViewer = ["org.gnome.Loupe.desktop"];
|
||||||
|
videoViewer = ["mpv.desktop"];
|
||||||
|
documentViewer = ["org.gnome.Evince.desktop"];
|
||||||
|
in {
|
||||||
|
"image/png" = imageViewer;
|
||||||
|
"image/jpeg" = imageViewer;
|
||||||
|
"video/webm" = videoViewer;
|
||||||
|
"application/pdf" = documentViewer;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
8
systems/common/direnv.nix
Normal file
8
systems/common/direnv.nix
Normal file
@ -0,0 +1,8 @@
|
|||||||
|
{...}: {
|
||||||
|
programs.direnv = {
|
||||||
|
enable = true;
|
||||||
|
|
||||||
|
nix-direnv.enable = true;
|
||||||
|
enableBashIntegration = true;
|
||||||
|
};
|
||||||
|
}
|
24
systems/common/firefox.nix
Normal file
24
systems/common/firefox.nix
Normal file
@ -0,0 +1,24 @@
|
|||||||
|
{config, ...}: {
|
||||||
|
programs.firefox = {
|
||||||
|
enable = true;
|
||||||
|
|
||||||
|
profiles.kristian = {
|
||||||
|
isDefault = true;
|
||||||
|
search.default = "DuckDuckGo";
|
||||||
|
search.force = true;
|
||||||
|
|
||||||
|
extensions = with config.nur.repos.rycee.firefox-addons; [
|
||||||
|
ublock-origin
|
||||||
|
umatrix
|
||||||
|
sidebery
|
||||||
|
sponsorblock
|
||||||
|
dearrow
|
||||||
|
user-agent-string-switcher
|
||||||
|
];
|
||||||
|
|
||||||
|
settings = {
|
||||||
|
"extensions.pocket.enabled" = false;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
7
systems/common/fonts.nix
Normal file
7
systems/common/fonts.nix
Normal file
@ -0,0 +1,7 @@
|
|||||||
|
{pkgs, ...}: {
|
||||||
|
fonts.fontconfig.enable = true;
|
||||||
|
|
||||||
|
home.packages = with pkgs; [
|
||||||
|
nerdfonts
|
||||||
|
];
|
||||||
|
}
|
19
systems/common/git.nix
Normal file
19
systems/common/git.nix
Normal file
@ -0,0 +1,19 @@
|
|||||||
|
{...}: {
|
||||||
|
programs.git = let
|
||||||
|
userName = "Kristian Krsnik";
|
||||||
|
userEmail = "git@krsnik.at";
|
||||||
|
in {
|
||||||
|
enable = true;
|
||||||
|
|
||||||
|
inherit userName userEmail;
|
||||||
|
|
||||||
|
signing = {
|
||||||
|
key = userEmail;
|
||||||
|
signByDefault = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
extraConfig = {
|
||||||
|
init.defaultBranch = "main";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
106
systems/common/gnome.nix
Normal file
106
systems/common/gnome.nix
Normal file
@ -0,0 +1,106 @@
|
|||||||
|
{
|
||||||
|
pkgs,
|
||||||
|
wallpaper,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
|
home.packages = with pkgs.gnomeExtensions; [
|
||||||
|
quick-settings-audio-panel
|
||||||
|
tray-icons-reloaded
|
||||||
|
espresso
|
||||||
|
pano
|
||||||
|
];
|
||||||
|
|
||||||
|
dconf.settings = {
|
||||||
|
# Use `dconf watch /` to track stateful changes you are doing, then set them here.
|
||||||
|
"org/gnome/shell" = {
|
||||||
|
disable-user-extensions = false;
|
||||||
|
enabled-extensions = [
|
||||||
|
"quick-settings-audio-panel@rayzeq.github.io"
|
||||||
|
"places-menu@gnome-shell-extensions.gcampax.github.com"
|
||||||
|
"launch-new-instance@gnome-shell-extensions.gcampax.github.com"
|
||||||
|
"trayIconsReloaded@selfmade.pl"
|
||||||
|
"espresso@coadmunkee.github.com"
|
||||||
|
"pano@elhan.io"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
|
"org/gnome/desktop/interface" = {
|
||||||
|
color-scheme = "prefer-dark";
|
||||||
|
gtk-theme = "Adwaita-dark";
|
||||||
|
};
|
||||||
|
|
||||||
|
"org/gnome/desktop/background" = let
|
||||||
|
width = 3840;
|
||||||
|
height = 2160;
|
||||||
|
in {
|
||||||
|
picture-uri = "file://${wallpaper.override {
|
||||||
|
preset = "nord-snow-aurora";
|
||||||
|
inherit width height;
|
||||||
|
}}/share/wallpapers/nixos-wallpaper.png";
|
||||||
|
|
||||||
|
picture-uri-dark = "file://${wallpaper.override {
|
||||||
|
preset = "nord-night-aurora";
|
||||||
|
inherit width height;
|
||||||
|
}}/share/wallpapers/nixos-wallpaper.png";
|
||||||
|
};
|
||||||
|
|
||||||
|
"org/gnome/desktop/wm/keybindings" = {
|
||||||
|
switch-to-workspace-left = ["<Alt>1"];
|
||||||
|
switch-to-workspace-right = ["<Alt>2"];
|
||||||
|
move-to-workspace-left = ["<Shift><Alt>1"];
|
||||||
|
move-to-workspace-right = ["<Shift><Alt>2"];
|
||||||
|
};
|
||||||
|
|
||||||
|
"org/gnome/settings-daemon/plugins/media-keys" = {
|
||||||
|
mic-mute = ["<Shift>AudioMute"];
|
||||||
|
};
|
||||||
|
|
||||||
|
"org/gnome/settings-daemon/plugins/media-keys/custom-keybindings/custom0" = {
|
||||||
|
binding = "<Shift><Alt>a";
|
||||||
|
command = "kgx";
|
||||||
|
name = "Console";
|
||||||
|
};
|
||||||
|
|
||||||
|
"org/gnome/settings-daemon/plugins/media-keys/custom-keybindings/custom1" = {
|
||||||
|
binding = "<Shift><Alt>f";
|
||||||
|
command = "nautilus";
|
||||||
|
name = "File Manager";
|
||||||
|
};
|
||||||
|
|
||||||
|
"org/gnome/settings-daemon/plugins/media-keys" = {
|
||||||
|
custom-keybindings = [
|
||||||
|
"/org/gnome/settings-daemon/plugins/media-keys/custom-keybindings/custom0/"
|
||||||
|
"/org/gnome/settings-daemon/plugins/media-keys/custom-keybindings/custom1/"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
|
"org/gnome/mutter" = {
|
||||||
|
edge-tiling = true;
|
||||||
|
dynamic-workspaces = true;
|
||||||
|
workspaces-only-on-primary = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
"org/gnome/Console" = {
|
||||||
|
theme = "auto";
|
||||||
|
};
|
||||||
|
|
||||||
|
"org/gnome/simple-scan" = {
|
||||||
|
text-dpi = 300;
|
||||||
|
};
|
||||||
|
|
||||||
|
"org/gnome/shell/extensions/pano" = {
|
||||||
|
play-audio-on-copy = false;
|
||||||
|
# This solves the stuttering issue for me.
|
||||||
|
# https://github.com/oae/gnome-shell-pano/issues/79
|
||||||
|
send-notification-on-copy = false;
|
||||||
|
};
|
||||||
|
|
||||||
|
"org/gnome/shell/extensions/espresso" = {
|
||||||
|
show-notifications = false;
|
||||||
|
};
|
||||||
|
|
||||||
|
"org/gnome/nautilus/preferences" = {
|
||||||
|
show-image-thumbnails = "always";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
28
systems/common/gpg.nix
Normal file
28
systems/common/gpg.nix
Normal file
@ -0,0 +1,28 @@
|
|||||||
|
{...}: {
|
||||||
|
programs.gpg.enable = true;
|
||||||
|
|
||||||
|
services.gpg-agent = {
|
||||||
|
enable = true;
|
||||||
|
|
||||||
|
enableSshSupport = true;
|
||||||
|
sshKeys = ["A0B5D579ECACC45C51B2B38E317D346182083CD8"];
|
||||||
|
|
||||||
|
# The amount of time a key is kept in the cache before it is removed.
|
||||||
|
# The timer is reset after each use within that window.
|
||||||
|
defaultCacheTtl = 86400; # 1 Day
|
||||||
|
defaultCacheTtlSsh = 86400; # 1 Day
|
||||||
|
|
||||||
|
# The maximum amount after which the passphrase has to be retyped,
|
||||||
|
# even if the key is still cached.
|
||||||
|
maxCacheTtl = 86400; # 1 Day
|
||||||
|
maxCacheTtlSsh = 86400; # 1 Day
|
||||||
|
};
|
||||||
|
|
||||||
|
# Disable gnome-keyring-ssh for gpg-agent to work
|
||||||
|
# https://github.com/NixOS/nixpkgs/issues/101616
|
||||||
|
xdg.configFile."autostart/gnome-keyring-ssh.desktop".text = ''
|
||||||
|
[Desktop Entry]
|
||||||
|
Type=Application
|
||||||
|
Hidden=true
|
||||||
|
'';
|
||||||
|
}
|
23
systems/common/mpv.nix
Normal file
23
systems/common/mpv.nix
Normal file
@ -0,0 +1,23 @@
|
|||||||
|
{...}: {
|
||||||
|
programs.mpv = {
|
||||||
|
enable = true;
|
||||||
|
bindings = let
|
||||||
|
volume-step = "5";
|
||||||
|
speed-step = "0.125";
|
||||||
|
seek-step = "5";
|
||||||
|
in {
|
||||||
|
# supported commands https://raw.githubusercontent.com/mpv-player/mpv/master/etc/input.conf
|
||||||
|
WHEEL_UP = "add volume +${volume-step}";
|
||||||
|
WHEEL_DOWN = "add volume -${volume-step}";
|
||||||
|
RIGHT = "seek +${seek-step}";
|
||||||
|
LEFT = "seek -${seek-step}";
|
||||||
|
UP = "add volume +${volume-step}";
|
||||||
|
DOWN = "add volume -${volume-step}";
|
||||||
|
"Alt+h" = "vf toggle hflip";
|
||||||
|
"Alt+v" = "vf toggle vflip";
|
||||||
|
">" = "add speed +${speed-step}";
|
||||||
|
"<" = "add speed -${speed-step}";
|
||||||
|
BS = "set speed 1.0";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
54
systems/common/nvim/default.nix
Normal file
54
systems/common/nvim/default.nix
Normal file
@ -0,0 +1,54 @@
|
|||||||
|
{pkgs, ...}: {
|
||||||
|
config.programs.neovim = {
|
||||||
|
enable = true;
|
||||||
|
|
||||||
|
defaultEditor = true;
|
||||||
|
viAlias = true;
|
||||||
|
vimAlias = true;
|
||||||
|
vimdiffAlias = true;
|
||||||
|
|
||||||
|
plugins = with pkgs.vimPlugins;
|
||||||
|
[
|
||||||
|
telescope-nvim # fuzzy finder
|
||||||
|
tokyonight-nvim # theme
|
||||||
|
undotree # undotree
|
||||||
|
vim-fugitive # git integration
|
||||||
|
nvim-treesitter # syntax highlighting
|
||||||
|
|
||||||
|
# Autocomplete and LSP
|
||||||
|
nvim-lspconfig
|
||||||
|
nvim-cmp
|
||||||
|
cmp-nvim-lsp
|
||||||
|
luasnip
|
||||||
|
]
|
||||||
|
++ (with pkgs.vimPlugins.nvim-treesitter-parsers; [
|
||||||
|
# Parsers for syntax highlighting
|
||||||
|
nix
|
||||||
|
zig
|
||||||
|
python
|
||||||
|
vim
|
||||||
|
vimdoc
|
||||||
|
markdown
|
||||||
|
dockerfile
|
||||||
|
yaml
|
||||||
|
json
|
||||||
|
toml
|
||||||
|
lua
|
||||||
|
c
|
||||||
|
glsl
|
||||||
|
bash
|
||||||
|
]);
|
||||||
|
|
||||||
|
extraPackages = [pkgs.nodePackages.pyright];
|
||||||
|
extraLuaConfig =
|
||||||
|
builtins.readFile ./keybinds.lua
|
||||||
|
+ builtins.readFile ./colors.lua
|
||||||
|
+ builtins.readFile ./undotree.lua
|
||||||
|
+ builtins.readFile ./fugitive.lua
|
||||||
|
+ builtins.readFile ./treesitter.lua
|
||||||
|
+ builtins.readFile ./telescope.lua
|
||||||
|
+ builtins.readFile ./cmp.lua
|
||||||
|
+ builtins.readFile ./lspconfig.lua;
|
||||||
|
extraConfig = "set number relativenumber";
|
||||||
|
};
|
||||||
|
}
|
32
systems/common/obs.nix
Normal file
32
systems/common/obs.nix
Normal file
@ -0,0 +1,32 @@
|
|||||||
|
{
|
||||||
|
pkgs,
|
||||||
|
libs,
|
||||||
|
config,
|
||||||
|
...
|
||||||
|
}: let
|
||||||
|
cfg = config.programs.obs;
|
||||||
|
in {
|
||||||
|
options.programs.obs = {
|
||||||
|
autostart = pkgs.lib.mkOption {
|
||||||
|
type = pkgs.lib.types.bool;
|
||||||
|
default = false;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
config = {
|
||||||
|
programs.obs-studio = {
|
||||||
|
enable = true;
|
||||||
|
plugins = with pkgs.obs-studio-plugins; [
|
||||||
|
obs-source-record
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
|
xdg.configFile = pkgs.lib.mkIf cfg.autostart {
|
||||||
|
"autostart/obs-autostart.desktop" = libs.mkAutostart {
|
||||||
|
inherit pkgs;
|
||||||
|
name = "obs";
|
||||||
|
command = "obs --startreplaybuffer";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
110
systems/common/packages.nix
Normal file
110
systems/common/packages.nix
Normal file
@ -0,0 +1,110 @@
|
|||||||
|
{
|
||||||
|
pkgs,
|
||||||
|
lib,
|
||||||
|
...
|
||||||
|
}: {
|
||||||
|
nixpkgs.config = {
|
||||||
|
allowUnfree = false;
|
||||||
|
|
||||||
|
permittedInsecurePackages = [
|
||||||
|
"electron-25.9.0"
|
||||||
|
];
|
||||||
|
|
||||||
|
allowUnfreePredicate = pkg:
|
||||||
|
builtins.elem (lib.getName pkg) [
|
||||||
|
"osu-lazer"
|
||||||
|
"spotify"
|
||||||
|
"linuxsampler"
|
||||||
|
"libsciter"
|
||||||
|
"obsidian"
|
||||||
|
"steam"
|
||||||
|
"steam-original"
|
||||||
|
"davinci-resolve"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
|
home.packages = with pkgs; [
|
||||||
|
# Basic utils
|
||||||
|
unzip
|
||||||
|
magic-wormhole
|
||||||
|
|
||||||
|
# Important graphical applications
|
||||||
|
keepassxc
|
||||||
|
logseq
|
||||||
|
xournalpp
|
||||||
|
libreoffice
|
||||||
|
onlyoffice-bin
|
||||||
|
|
||||||
|
# For windows applications
|
||||||
|
bottles
|
||||||
|
|
||||||
|
# Games
|
||||||
|
lutris
|
||||||
|
osu-lazer
|
||||||
|
r2modman
|
||||||
|
prismlauncher
|
||||||
|
|
||||||
|
# Communication
|
||||||
|
webcord
|
||||||
|
telegram-desktop
|
||||||
|
signal-desktop
|
||||||
|
element-desktop
|
||||||
|
|
||||||
|
# Creative software
|
||||||
|
gimp
|
||||||
|
inkscape
|
||||||
|
davinci-resolve
|
||||||
|
|
||||||
|
ardour # DAW
|
||||||
|
# plugins
|
||||||
|
sfizz
|
||||||
|
swh_lv2
|
||||||
|
zynaddsubfx
|
||||||
|
caps
|
||||||
|
cmt
|
||||||
|
distrho
|
||||||
|
surge
|
||||||
|
calf
|
||||||
|
dexed
|
||||||
|
odin2
|
||||||
|
ninjas2
|
||||||
|
linuxsampler
|
||||||
|
|
||||||
|
yabridge
|
||||||
|
yabridgectl
|
||||||
|
|
||||||
|
geonkick # for drums
|
||||||
|
|
||||||
|
# Misc
|
||||||
|
gnome-decoder
|
||||||
|
tor-browser-bundle-bin
|
||||||
|
obsidian
|
||||||
|
easyeffects
|
||||||
|
|
||||||
|
starc
|
||||||
|
scanned-image-extractor
|
||||||
|
|
||||||
|
rustdesk
|
||||||
|
wireshark
|
||||||
|
mullvad-vpn
|
||||||
|
|
||||||
|
# Entertainment
|
||||||
|
hypnotix
|
||||||
|
|
||||||
|
# VPN client for university
|
||||||
|
(
|
||||||
|
pkgs.writeScriptBin "univpn"
|
||||||
|
''
|
||||||
|
read -p "Username: " username
|
||||||
|
read -s -p "Password: " password
|
||||||
|
|
||||||
|
# newline
|
||||||
|
echo ""
|
||||||
|
|
||||||
|
read -p "OTP: " otp
|
||||||
|
|
||||||
|
sudo ${pkgs.gof5}/bin/gof5 --server "vpn.univie.ac.at" --username "$username@$otp" --password "$password"
|
||||||
|
''
|
||||||
|
)
|
||||||
|
];
|
||||||
|
}
|
23
systems/common/spiceify.nix
Normal file
23
systems/common/spiceify.nix
Normal file
@ -0,0 +1,23 @@
|
|||||||
|
{
|
||||||
|
pkgs,
|
||||||
|
spicetify,
|
||||||
|
...
|
||||||
|
}: let
|
||||||
|
spicePkgs = spicetify.packages.${pkgs.system}.default;
|
||||||
|
in {
|
||||||
|
programs.spicetify = {
|
||||||
|
enable = true;
|
||||||
|
|
||||||
|
theme = spicePkgs.themes.text;
|
||||||
|
colorScheme = "CatppuccinLatte";
|
||||||
|
|
||||||
|
enabledExtensions = with spicePkgs.extensions; [
|
||||||
|
shuffle # shuffle+ (special characters are sanitized out of ext names)
|
||||||
|
groupSession
|
||||||
|
wikify
|
||||||
|
fullScreen
|
||||||
|
playlistIntersection
|
||||||
|
phraseToPlaylist
|
||||||
|
];
|
||||||
|
};
|
||||||
|
}
|
10
systems/common/thunderbird.nix
Normal file
10
systems/common/thunderbird.nix
Normal file
@ -0,0 +1,10 @@
|
|||||||
|
{...}: {
|
||||||
|
programs.thunderbird = {
|
||||||
|
enable = true;
|
||||||
|
|
||||||
|
profiles.kristian = {
|
||||||
|
isDefault = true;
|
||||||
|
withExternalGnupg = true;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
136
systems/common/vscode.nix
Normal file
136
systems/common/vscode.nix
Normal file
@ -0,0 +1,136 @@
|
|||||||
|
{pkgs, ...}: {
|
||||||
|
programs.vscode = {
|
||||||
|
enable = true;
|
||||||
|
|
||||||
|
package = pkgs.vscodium; # Replace VSCode with VSCodium
|
||||||
|
|
||||||
|
enableUpdateCheck = false;
|
||||||
|
enableExtensionUpdateCheck = false;
|
||||||
|
|
||||||
|
keybindings = [
|
||||||
|
{
|
||||||
|
key = "alt+a";
|
||||||
|
command = "editor.action.commentLine";
|
||||||
|
when = "editorTextFocus && !editorReadonly";
|
||||||
|
}
|
||||||
|
];
|
||||||
|
|
||||||
|
# This will only yield extensions that are compatible with the installed version of vscode
|
||||||
|
extensions = with pkgs.vscode-marketplace; [
|
||||||
|
jnoortheen.nix-ide
|
||||||
|
mkhl.direnv
|
||||||
|
ms-python.python
|
||||||
|
ms-python.vscode-pylance
|
||||||
|
ms-python.autopep8
|
||||||
|
james-yu.latex-workshop
|
||||||
|
davidanson.vscode-markdownlint
|
||||||
|
tamasfe.even-better-toml
|
||||||
|
asciidoctor.asciidoctor-vscode
|
||||||
|
ziglang.vscode-zig
|
||||||
|
slevesque.shader
|
||||||
|
ms-vscode.cpptools
|
||||||
|
nvarner.typst-lsp
|
||||||
|
redhat.java
|
||||||
|
|
||||||
|
streetsidesoftware.code-spell-checker
|
||||||
|
streetsidesoftware.code-spell-checker-german
|
||||||
|
];
|
||||||
|
|
||||||
|
userSettings = {
|
||||||
|
"git.enableCommitSigning" = true;
|
||||||
|
|
||||||
|
"window.menuBarVisibility" = "toggle";
|
||||||
|
|
||||||
|
"editor.fontFamily" = "'FiraCode Nerd Font'";
|
||||||
|
"editor.fontLigatures" = true;
|
||||||
|
"editor.minimap.enabled" = false;
|
||||||
|
|
||||||
|
"extensions.ignoreRecommendations" = true;
|
||||||
|
|
||||||
|
"[nix]" = {
|
||||||
|
"editor.formatOnSave" = true;
|
||||||
|
"editor.formatOnSaveMode" = "file"; # modificationsIfAvailable does not work
|
||||||
|
};
|
||||||
|
|
||||||
|
"[python]" = {
|
||||||
|
"editor.formatOnSave" = true;
|
||||||
|
"editor.formatOnSaveMode" = "modificationsIfAvailable";
|
||||||
|
"editor.defaultFormatter" = "ms-python.autopep8";
|
||||||
|
};
|
||||||
|
|
||||||
|
"[javascript]" = {
|
||||||
|
"editor.formatOnSave" = true;
|
||||||
|
"editor.formatOnSaveMode" = "modificationsIfAvailable";
|
||||||
|
};
|
||||||
|
|
||||||
|
"[typescript]" = {
|
||||||
|
"editor.formatOnSave" = true;
|
||||||
|
"editor.formatOnSaveMode" = "modificationsIfAvailable";
|
||||||
|
};
|
||||||
|
|
||||||
|
"[latex]" = {
|
||||||
|
"editor.formatOnSave" = true;
|
||||||
|
"editor.formatOnSaveMode" = "file"; # modificationsIfAvailable does not work
|
||||||
|
};
|
||||||
|
|
||||||
|
"[toml]" = {
|
||||||
|
"editor.formatOnSave" = true;
|
||||||
|
"editor.formatOnSaveMode" = "modificationsIfAvailable";
|
||||||
|
};
|
||||||
|
|
||||||
|
"[c]" = {
|
||||||
|
"editor.formatOnSave" = true;
|
||||||
|
"editor.formatOnSaveMode" = "modificationsIfAvailable";
|
||||||
|
};
|
||||||
|
|
||||||
|
"[cpp]" = {
|
||||||
|
"editor.formatOnSave" = true;
|
||||||
|
"editor.formatOnSaveMode" = "modificationsIfAvailable";
|
||||||
|
};
|
||||||
|
|
||||||
|
"[typst]" = {
|
||||||
|
"editor.defaultFormatter" = "nvarner.typst-lsp";
|
||||||
|
"editor.formatOnSave" = true;
|
||||||
|
"editor.formatOnSaveMode" = "modificationsIfAvailable";
|
||||||
|
};
|
||||||
|
|
||||||
|
"nix.enableLanguageServer" = true;
|
||||||
|
"nix.serverPath" = "${pkgs.nil}/bin/nil";
|
||||||
|
"nix.serverSettings" = {
|
||||||
|
nil = {
|
||||||
|
formatting = {command = ["${pkgs.alejandra}/bin/alejandra"];};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
"direnv.path.executable" = "${pkgs.direnv}/bin/direnv";
|
||||||
|
|
||||||
|
"latex-workshop.latex.outDir" = "%DIR%/out";
|
||||||
|
|
||||||
|
"terminal.integrated.profiles.linux" = {
|
||||||
|
"bash" = {
|
||||||
|
"path" = "${pkgs.bashInteractive}/bin/bash";
|
||||||
|
"args" = [];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
"terminal.integrated.defaultProfile.linux" = "bash";
|
||||||
|
|
||||||
|
"cSpell.language" = "en,de-de";
|
||||||
|
|
||||||
|
"zig.path" = "";
|
||||||
|
"zig.zls.path" = "";
|
||||||
|
"zig.initialSetupDone" = true;
|
||||||
|
|
||||||
|
"typst-lsp.serverPath" = "${pkgs.typst-lsp}/bin/typst-lsp";
|
||||||
|
"typst-lsp.experimentalFormatterMode" = "on";
|
||||||
|
|
||||||
|
"C_Cpp.default.compilerPath" = "${pkgs.gnat}/bin/g++";
|
||||||
|
"C_Cpp.default.includePath" = [
|
||||||
|
"\${workspaceFolder}/**"
|
||||||
|
];
|
||||||
|
"C_Cpp.clang_format_fallbackStyle" = "Microsoft";
|
||||||
|
|
||||||
|
"redhat.telemetry.enabled" = false;
|
||||||
|
"java.jdt.ls.java.home" = "${pkgs.jdk21_headless}";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
16
systems/laptop/default.nix
Normal file
16
systems/laptop/default.nix
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
{...}: {
|
||||||
|
targets.genericLinux.enable = false;
|
||||||
|
|
||||||
|
programs.bash.shellAliases = {
|
||||||
|
hms = "home-manager switch --flake $HOME/.config/home-manager#laptop";
|
||||||
|
};
|
||||||
|
|
||||||
|
dconf.settings = {
|
||||||
|
"org/gnome/settings-daemon/plugins/power" = {
|
||||||
|
sleep-inactive-ac-type = "suspend";
|
||||||
|
power-button-action = "hibernate";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
programs.obs.autostart = false;
|
||||||
|
}
|
16
systems/pc/default.nix
Normal file
16
systems/pc/default.nix
Normal file
@ -0,0 +1,16 @@
|
|||||||
|
{...}: {
|
||||||
|
targets.genericLinux.enable = false;
|
||||||
|
|
||||||
|
programs.bash.shellAliases = {
|
||||||
|
hms = "home-manager switch --flake $HOME/.config/home-manager#pc";
|
||||||
|
};
|
||||||
|
|
||||||
|
dconf.settings = {
|
||||||
|
"org/gnome/settings-daemon/plugins/power" = {
|
||||||
|
sleep-inactive-ac-type = "nothing"; # Automatic suspend/hibernation creates a suspend/hibernation loop
|
||||||
|
power-button-action = "suspend";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
programs.obs.autostart = true;
|
||||||
|
}
|
Reference in New Issue
Block a user