Compare commits
1025 Commits
mail
...
416d3ab277
| Author | SHA1 | Date | |
|---|---|---|---|
| 416d3ab277 | |||
| 82b9bb2a4c | |||
| 82b650bdbf | |||
| 06125303b8 | |||
| c0efacd6ce | |||
| 2aff28c6ed | |||
| e27db27fd8 | |||
| 683bd2f3be | |||
| 01e3cef34f | |||
| f921d3d3b6 | |||
| ffa3f820ce | |||
| 8738cb4a58 | |||
| a2b706e787 | |||
| 22247715a3 | |||
| bdd4bda339 | |||
| 1002fd8b43 | |||
| 1f48644558 | |||
| da95622df1 | |||
| e275c81257 | |||
| bf7d0165b1 | |||
| cb10b423dc | |||
| a93a34e546 | |||
| c7603af4d0 | |||
| dd685afb7c | |||
| 055b4016e6 | |||
| f361d2b877 | |||
| 8b00faf762 | |||
| f7d72e00b6 | |||
| 087c138906 | |||
| bf8f6d8d52 | |||
| fcf2aa4cca | |||
| 48484514bc | |||
| aa359ad986 | |||
| 2432b0bbaa | |||
| 2b754d4a5b | |||
| f38e5c3295 | |||
| f6b4740b73 | |||
| c06fb3f50c | |||
| 4ae2fa4a6a | |||
| 6809db5ccc | |||
| c9fb802c55 | |||
| 2f4505d29b | |||
| b43de46611 | |||
| 3545c37084 | |||
| 043fe3b67b | |||
| f0779c45c3 | |||
| b7a6fda046 | |||
| e431e0bf03 | |||
| ac54cd5eaf | |||
| 4bd5965915 | |||
| f21112465b | |||
| b989684f12 | |||
| beef73daab | |||
| de3fbfd356 | |||
| a1e88e30a7 | |||
| c50698f275 | |||
| 6119c0dbcc | |||
| 7dd5a9e269 | |||
| 2384a4eef5 | |||
| f6ffd477d1 | |||
| 77fc7e4832 | |||
| 76d75048fa | |||
| 71e65461cf | |||
| 6545b016c5 | |||
| 6eff3d831c | |||
| 80abae0daa | |||
| bbdef3a8ed | |||
| 1f28eb000d | |||
| fb7a295310 | |||
| ad84e0445d | |||
| faac180148 | |||
| 2691608f8c | |||
| 9678ba7b28 | |||
| dc90c4c6ab | |||
| 4c2a4df663 | |||
| c60e90f001 | |||
| d0f1287c68 | |||
| f91004fff6 | |||
| adca14865c | |||
| 4cdf954732 | |||
| e2bd211d4b | |||
| d04c652f61 | |||
| f036e50210 | |||
| 8b8fbeb511 | |||
| 04b40f15e2 | |||
| 70755b3cec | |||
| 3ebd71971d | |||
| ca51f06e2a | |||
| 0e9051aaaa | |||
| d1079fe413 | |||
| 6418b03548 | |||
| ecdfd7953d | |||
| 08ab96c0db | |||
| 5939219f8c | |||
| e2f82c3da8 | |||
| 0dc43c2eff | |||
| 136b04cb3f | |||
| 8af855585b | |||
| 4136e7bf3f | |||
| c365f5f8b2 | |||
| d37393b1ca | |||
| b484f424af | |||
| 15e2cd7e4f | |||
| a88a0f57c2 | |||
| 4d81f0b0ac | |||
| 0971a2c575 | |||
| 18c829f224 | |||
| 865b0b736c | |||
| 84613b8d51 | |||
| 7fcf265ffd | |||
| 5892702841 | |||
| 233fa97da5 | |||
| aeda9e63e6 | |||
| 80d9a1b41c | |||
| 40fd40453f | |||
| 8beb632b1e | |||
| 83c9b0e30c | |||
| 8471f7e1e2 | |||
| 8ff3cab263 | |||
| 321eb82116 | |||
| 9d0dc4397c | |||
| 6ab4332965 | |||
| f00d903043 | |||
| cb1f3ce4f1 | |||
| d3e3bf92eb | |||
| 60e44ae4eb | |||
| 9bc3279f52 | |||
| 2f75f4c3b3 | |||
| f8a3bfe21e | |||
| 56fe6b3f00 | |||
| 8746b4522a | |||
| e8f46cd497 | |||
| 10a4afd59d | |||
| 27499d6a7a | |||
| c20acb75f8 | |||
| 4dd00e1063 | |||
| 20df63014d | |||
| 27a6c5833e | |||
| 2201b192fd | |||
| cf2c0c7a37 | |||
| 3a48c9860b | |||
| 9c44e03215 | |||
| d6c4899dc1 | |||
| 94092fbfeb | |||
| a1e96d67b7 | |||
| a2290fd6f7 | |||
| bc2d4fb005 | |||
| a0096a771d | |||
| eb2f7ea275 | |||
| c2b567664c | |||
| 900839b9b3 | |||
| 6498e5a1da | |||
| 1f971b2a74 | |||
| be178dffc6 | |||
| 934a5840df | |||
| 199ccf7537 | |||
| e479ea36ec | |||
| b8f8e97df1 | |||
| 5e6baef3d2 | |||
| 008db3167d | |||
| 2cbf412f27 | |||
| f1021be262 | |||
| bed819219c | |||
| 0a21d0434c | |||
| 5e34212f5b | |||
| 01925ed0ff | |||
| 1311b64824 | |||
| 2b85e37fb6 | |||
| 6fb75ace21 | |||
| 72135addb0 | |||
| 1ebf7d6cec | |||
| 27442da13d | |||
| 5f0b0beb94 | |||
| 52fd14c4fb | |||
| b33a64796c | |||
| 2a761efc90 | |||
| f320afd838 | |||
| 345fd8159c | |||
| daef8b79d4 | |||
| 6cdfdaf703 | |||
| eca981e5c9 | |||
| 2fee6ae34b | |||
| 6c96c792f0 | |||
| 70414128e5 | |||
| d480eff8cd | |||
| d23d443cc5 | |||
| 1131da55ce | |||
| f5882d1577 | |||
| 39917e0bf6 | |||
| 6727673dcf | |||
| 2b2290841b | |||
| 179b526214 | |||
| 8894fb2a27 | |||
| ed97c13314 | |||
| cd0874f093 | |||
| d67f501452 | |||
| 118dcf3046 | |||
| 7154c84cdc | |||
| 94f0299a75 | |||
| 69354bbd3a | |||
| e6b761da34 | |||
| 724ac3aa99 | |||
| 8880e6814c | |||
| bee54c5f0b | |||
| a5e1ef0a77 | |||
| 8b1dc82eae | |||
| e830c87763 | |||
| 6079c109f9 | |||
| d74b261897 | |||
| fa192a3977 | |||
| fd38db79c0 | |||
| 06eda7cb6f | |||
| 543ea247ed | |||
| 742018dab0 | |||
| 8a8a4aae67 | |||
| e521a82246 | |||
| 78f490cdfb | |||
| b5905f886a | |||
| f1ce023eca | |||
| 13793d3263 | |||
| 99a8ecf876 | |||
| 6a3add22ed | |||
| 83fb13d541 | |||
| e34aecaa66 | |||
| 000091f910 | |||
| c68895cbb8 | |||
| 295dfad33e | |||
| 0f6d9bdc66 | |||
| dcd7a9a4f6 | |||
| 51ca66c383 | |||
| 574fded6e2 | |||
| bdb9220df6 | |||
| aac96c00bf | |||
| 97e61f6eb1 | |||
| 3cb211c682 | |||
| a133f2bb3d | |||
| 7b617aecd8 | |||
| 9f38cc3850 | |||
| e62e28ffb1 | |||
| d3b2ce8277 | |||
| 30b4c6354f | |||
| 7c88a16a32 | |||
| 60dc5a9629 | |||
| 29da1f50cf | |||
| 14cc0ac6aa | |||
| 80e91d1685 | |||
| c17b611af5 | |||
| c85b73a874 | |||
| ff49bb95a7 | |||
| 3a21680812 | |||
| 4f962778b7 | |||
| 4006c36f9b | |||
| eb521b2e0e | |||
| f178daaffd | |||
| f23e644417 | |||
| 0f432025ad | |||
| 7f009cfd08 | |||
| 94cdfa3ea3 | |||
| e75348e1cb | |||
| e13e421b75 | |||
| a3fa195089 | |||
| 35192198a7 | |||
| b93f4a49e0 | |||
| 9a4b9946cb | |||
| 9955d05152 | |||
| 141d5db610 | |||
| a4edbfd29d | |||
| 6f7d5eadbf | |||
| 1d6d8f8249 | |||
| 901ab8d6b0 | |||
| 5249d6ab0d | |||
| 9a00809a2d | |||
| 376a2e115c | |||
| aac1a2e813 | |||
| 28ef523c82 | |||
| c672260930 | |||
| 5cc34626e1 | |||
| 9f1f73ad21 | |||
| 5fdb612033 | |||
| 508bc908ce | |||
| 4cba5a0b8a | |||
| 71b5a8cb24 | |||
| 200bff8386 | |||
| 79fd340f82 | |||
| 69ed97a4ab | |||
| ebbbb537c3 | |||
| 556255ac8b | |||
| 6516c5c9b7 | |||
| b5d32d3962 | |||
| 766874a226 | |||
| 2e9386a6c2 | |||
| 9af10ecf46 | |||
| bd200b655d | |||
| 4adf8fea0a | |||
| 0f0b5658be | |||
| 4f8f3751f4 | |||
| 5b76c1439f | |||
| 3e684ae24a | |||
| 83afa6174a | |||
| 0d483bfc0c | |||
| dea9c3f0ed | |||
| f8b452901f | |||
| 80143fee87 | |||
| 834e5d9ef3 | |||
| 121d5e242f | |||
| b9748964d0 | |||
| 4ab7d0d92e | |||
| 08ada6b818 | |||
| a128813990 | |||
| 5eaee95ba1 | |||
| 5eba5b84f1 | |||
| 2a8495a92c | |||
| 5e62f0363d | |||
| 1c8c210f06 | |||
| 48ce381be0 | |||
| 777f24e37e | |||
| 78a50e9ae3 | |||
| b8967c8e5c | |||
| e3f3e4045a | |||
| 08ce7749b5 | |||
| d7adefc289 | |||
| 7472eb5028 | |||
| f85a8d2737 | |||
| 9724cdda54 | |||
| 6727df461d | |||
| 0f11a9398f | |||
| db07d68a60 | |||
| f4c8094ad8 | |||
| 04247c6ca1 | |||
| d99399009c | |||
| 19c1f7c50d | |||
| a983ce13f8 | |||
| b6fa1fc274 | |||
| 68e60b93ff | |||
| 3aabeea2c3 | |||
| 74c6fcd3a5 | |||
| 392ef95c4f | |||
| 5869807936 | |||
| e2a0ba3eed | |||
| 25c6f97693 | |||
| 12698d9f48 | |||
| 5dccdfee83 | |||
| 8420a2435d | |||
| ed732b3a65 | |||
| cbb676bf00 | |||
| 74b102e55e | |||
| c14f5925e2 | |||
| 9a7b6b020a | |||
| 68338c2791 | |||
| e74f9b6bd0 | |||
| a17201c28d | |||
| 2a94899db5 | |||
| bae1cb485c | |||
| 7f6e00a309 | |||
| 2a5ea9700b | |||
| 8b5bfd236d | |||
| 8302b1d9fb | |||
| 8f66163c39 | |||
| 7ad02f75a9 | |||
| 2f3d4fb3b1 | |||
| 005da63416 | |||
| beaf6c81e4 | |||
| 7c67d3f88a | |||
| 0d20cded25 | |||
| 6c1e8368a1 | |||
| ac1a7ac37e | |||
| 85a6001b53 | |||
| 4e107f3df7 | |||
| 37880ae746 | |||
| 155722a8cd | |||
| 73d71498c7 | |||
| e9b5c2623d | |||
| ddc4ca0db4 | |||
| 8fbaed35f8 | |||
| 87042f5409 | |||
| a9b1a03af1 | |||
| 010d620b76 | |||
| 18033c0e54 | |||
| 5cdf3637a5 | |||
| 9192fa458b | |||
| 40472e2ff8 | |||
| a592947bbf | |||
| 444336cd19 | |||
| 6ef578d644 | |||
| 8e19069d4c | |||
| 42df0dc7df | |||
| d6c10df13e | |||
| 8cbbb4b50d | |||
| bc23d7ac24 | |||
| 40f31fa316 | |||
| f73d8725c4 | |||
| 97fc0f82bf | |||
| ef3d6c4eaf | |||
| c6d7dbe787 | |||
| b9149c8d9a | |||
| 36502ecfd8 | |||
| 43fd4bbf19 | |||
| 37e851cc50 | |||
| 018f79f88d | |||
| 6843ac90b5 | |||
| afb69bf334 | |||
| ea57f539b0 | |||
| 3d10ac09ab | |||
| 38f088d9e5 | |||
| 422f2b8676 | |||
| 7c1ca72a29 | |||
| f171284b71 | |||
| ca50ba931a | |||
| 63ad607d46 | |||
| e553f1bcda | |||
| 8923f7a2c9 | |||
| 07024df1c9 | |||
| cb9bcf2d1d | |||
| 7aeda72026 | |||
| 95c93cc565 | |||
| c9979de250 | |||
| 7889d56b99 | |||
| 03be9636ad | |||
| 5d36ed4cd6 | |||
| c33446aee3 | |||
| fe7744bedb | |||
| 9673e9d3e8 | |||
| 5175f3f819 | |||
| 5923f3341a | |||
| 901cf6f711 | |||
| 859e536159 | |||
| 4ea18d0152 | |||
| c7c7017070 | |||
| 7c80f160db | |||
| 6fce803c70 | |||
| a6bff424b0 | |||
| d61b17c656 | |||
| cbdf8ef038 | |||
| 876dbe785b | |||
| fb4a14a6bf | |||
| 02977ea936 | |||
| dcca34d5c1 | |||
| 8bd8ec611f | |||
| 96a67a937e | |||
| fb85c29651 | |||
| 3344af5339 | |||
| fdfd8a687f | |||
| e804da180d | |||
| 2af8e1aa86 | |||
| 10224de58a | |||
| 2bf095c553 | |||
| a7d994abe7 | |||
| 680997fb12 | |||
| a2d1ab6f53 | |||
| 52761a13e2 | |||
| 98f7de9680 | |||
| 72f04f9391 | |||
| 10ad21a39c | |||
| 5c9e25f27a | |||
| 4b563ddf00 | |||
| d041e6fa52 | |||
| 8749646101 | |||
| 960311c65f | |||
| a70f05239a | |||
| d716e5716f | |||
| 2781930ecf | |||
| f34a938968 | |||
| 080439604b | |||
| 72df03fbf6 | |||
| b799e7c26f | |||
| 2a450e2f36 | |||
| 485e07ec9e | |||
| dcf3452353 | |||
| edc8e83594 | |||
| 01bc8178ad | |||
| eff303a854 | |||
| bc992a170c | |||
| 78e9bedcb4 | |||
| d5cdbf3795 | |||
| bcb5949e15 | |||
| dd61883648 | |||
| 1d7a432bec | |||
| 0e7652ff46 | |||
| a96c0d9ab3 | |||
| 82bb2d9f17 | |||
| 4fa0256095 | |||
| 2915594238 | |||
| cf48d89ea6 | |||
| 37f570a979 | |||
| f8af039913 | |||
| 46882af11e | |||
| 2c5d2f4add | |||
| bd089bd408 | |||
| fce8d15356 | |||
| acec2505e4 | |||
| 218c251d31 | |||
| 8cda7861f9 | |||
| a35c883eca | |||
| db61bc4b91 | |||
| 43fc9ebba2 | |||
| 23d60233a0 | |||
| f2fcc3be9a | |||
| 30e3baa335 | |||
| 616a530c64 | |||
| e5d437949b | |||
| 80c3b143ca | |||
| 263a732580 | |||
| c638ef93f5 | |||
| 69c2f506ae | |||
| db4857c86d | |||
| 6668542d53 | |||
| 561faed161 | |||
| 36ed681e99 | |||
| be84688b63 | |||
| de296c4e62 | |||
| d7807ba1b9 | |||
| 51fba9baa6 | |||
| a0fb2bd819 | |||
| a0830070f3 | |||
| c860529161 | |||
| 03461dcaaa | |||
| 1cd7039759 | |||
| af0806b766 | |||
| bd8960fd44 | |||
| 1bc90b2e84 | |||
| d2939795ac | |||
| 4a4d5a148d | |||
| f30cfbf142 | |||
| 15bda4721d | |||
| 4d610461b8 | |||
| eed54d1593 | |||
| ddec0551e8 | |||
| b0f2a74372 | |||
| 65584ec52f | |||
| 96f5d750ef | |||
| 77e97e84a9 | |||
| 96cb298584 | |||
| 5dc561da83 | |||
| b8c79fd21c | |||
| a98333a6b8 | |||
| fa5fe37610 | |||
| 0be0356005 | |||
| 394615168d | |||
| b6e77f77af | |||
| d7727433fd | |||
| 3f02559da2 | |||
| e7c801b6c4 | |||
| 3092fcda85 | |||
| 43a1ecedac | |||
| da55a342e3 | |||
| 48fcb08427 | |||
| a0855f8bbb | |||
| 3efb4682f2 | |||
| 048429f593 | |||
| 59cacae72e | |||
| 420245231a | |||
| 2911972900 | |||
| 5efcb813f0 | |||
| fd8f5d3a5c | |||
| 3508575ebe | |||
| 3741304284 | |||
| 6bfaf551d2 | |||
| 423cb074a0 | |||
| 9174337290 | |||
| 5ba0e9bfce | |||
| 14685a758d | |||
| 29385fdfac | |||
| 2fbf1f8ee6 | |||
| 675eb4db27 | |||
| 3ed6aa4b05 | |||
| 0cf4bdddf0 | |||
| 6c42159df0 | |||
| 51d09c68a7 | |||
| 71c24dd1a5 | |||
| c089f89eaa | |||
| c40fb2f097 | |||
| 4fc7d8dd2a | |||
| 240b97dce9 | |||
| 177977160f | |||
| 8a887226e7 | |||
| b49bedb9bc | |||
| 83662f48d1 | |||
| 3ae7b4d67d | |||
| 8e3691d775 | |||
| 30ad4816f7 | |||
| fc1a794455 | |||
| 8ee09997a4 | |||
| 435bf6888b | |||
| 2cbc6daac5 | |||
| da436bfafc | |||
| 125379fb18 | |||
| 7794464b36 | |||
|
|
2106247cf5 | ||
|
|
0ff450138f | ||
|
|
de761d60c1 | ||
|
|
40e1b9fdbc | ||
|
|
51d620058c | ||
|
|
d8ed9a41ed | ||
|
|
32f84a0aff | ||
|
|
838efd4093 | ||
|
|
d6a2e05590 | ||
|
|
36b2f38234 | ||
|
|
689b6d6898 | ||
|
|
96301914a9 | ||
|
|
14b0ef9dc6 | ||
|
|
4b3f685a0c | ||
|
|
2073c517ca | ||
|
|
7cfb61c5e8 | ||
|
|
f072262354 | ||
|
|
8098cdc842 | ||
|
|
717355a2cd | ||
|
|
c14e490d93 | ||
|
|
1711dda150 | ||
|
|
9c7c1d35e6 | ||
|
|
bc0ffde90e | ||
|
|
f32cd1e4bc | ||
|
|
5ec3713ad3 | ||
|
|
d15225ca1f | ||
|
|
956efaf350 | ||
|
|
232689dc10 | ||
|
|
01370d5d0b | ||
|
|
5a787fd0bb | ||
|
|
2152ea5e9d | ||
|
|
7132aeac86 | ||
|
|
676a76ea16 | ||
|
|
bf4defbc29 | ||
|
|
15d87f6a8d | ||
|
|
904cbdbc76 | ||
|
|
4c9d55727c | ||
|
|
699796d06e | ||
|
|
16205c3655 | ||
|
|
95a75db394 | ||
|
|
0a999a9ac7 | ||
|
|
e427aa912e | ||
|
|
854610384e | ||
|
|
60f920f3f0 | ||
|
|
7a9dd4c83e | ||
|
|
13bee034fa | ||
|
|
c2dd2f97ef | ||
|
|
07079de224 | ||
|
|
49900967e2 | ||
|
|
d85c7caca7 | ||
|
|
46cf80a54c | ||
|
|
404d8a81b4 | ||
|
|
7e22e8f72a | ||
|
|
9ee2786315 | ||
|
|
824dafb93c | ||
|
|
2dbe03835c | ||
|
|
e9faa01e1b | ||
|
|
90fe107176 | ||
|
|
237c733c1d | ||
|
|
5e768e932f | ||
|
|
4d153ebc5d | ||
|
|
09fd7b5d8d | ||
|
|
f97e7bd85e | ||
|
|
c8bbbb6055 | ||
|
|
1c52649be8 | ||
|
|
58fc4c1ce6 | ||
|
|
02452abfa1 | ||
|
|
2e33c708d3 | ||
|
|
56b366d8fe | ||
|
|
04a9f83bc8 | ||
|
|
a32eee9cad | ||
|
|
ecabce3025 | ||
|
|
f24269c83d | ||
|
|
2112e4e34f | ||
|
|
949bae5540 | ||
|
|
ce502a9a23 | ||
|
|
9e8ee5d0e0 | ||
|
|
cdddcf11de | ||
|
|
f610ed83c5 | ||
|
|
ed960eff06 | ||
|
|
32808989c1 | ||
|
|
a07d7ed1e4 | ||
|
|
fc96c4981f | ||
|
|
a678d47149 | ||
|
|
6dc3052fc0 | ||
|
|
8d6411dc9a | ||
|
|
d7a1b5d744 | ||
|
|
f4e3047abd | ||
|
|
652a5dfdb6 | ||
|
|
a7e831abff | ||
|
|
df63bed013 | ||
|
|
e90b287db8 | ||
|
|
1ed55fcb59 | ||
|
|
d5d6da02e6 | ||
|
|
a2fd2d96ff | ||
|
|
b2e32a4692 | ||
|
|
456cc7b80c | ||
|
|
05e7e84392 | ||
|
|
ac2c7b7036 | ||
|
|
b35dda6997 | ||
|
|
28f00240bb | ||
|
|
c4574909de | ||
|
|
43c008bcbf | ||
|
|
eadf80e8e4 | ||
|
|
b3caee106e | ||
|
|
39c9a2533a | ||
|
|
5b0c915023 | ||
|
|
875333962c | ||
|
|
08385b15e7 | ||
|
|
81551aa478 | ||
|
|
871370e7a8 | ||
|
|
e380f96f4c | ||
|
|
dfdb9d0bdb | ||
|
|
90eed5cb3b | ||
|
|
4443d065ed | ||
|
|
5b189d6f17 | ||
|
|
d8a4d4eedf | ||
|
|
2c3957735b | ||
|
|
ddd9a96cec | ||
|
|
01c6dccc9c | ||
|
|
8e636461bd | ||
|
|
dcb1e7cf1d | ||
|
|
82efad8ee8 | ||
|
|
70cc121237 | ||
|
|
8b835c1252 | ||
|
|
489386992e | ||
|
|
ac90b48268 | ||
|
|
c725ed62b5 | ||
|
|
078cbb8830 | ||
|
|
7b0d5977cc | ||
|
|
749fba4c7d | ||
|
|
884e50b8cd | ||
|
|
405d6d8407 | ||
|
|
a3163e6260 | ||
|
|
b379f09c20 | ||
|
|
4658252570 | ||
|
|
2e6ac15443 | ||
|
|
eca7ee17cb | ||
|
|
bbdf762c5c | ||
|
|
046424b399 | ||
|
|
a20ad8cc7e | ||
|
|
4b25ff0b27 | ||
|
|
729b43237b | ||
|
|
26e7d546c1 | ||
|
|
fd36d5279c | ||
|
|
9a33c1a106 | ||
|
|
a59be3f398 | ||
|
|
39bc899d44 | ||
|
|
e34ee8399b | ||
|
|
a842d2a691 | ||
|
|
a77f630681 | ||
|
|
b93c4e9c9c | ||
|
|
ba03c19a74 | ||
|
|
796f73ef5f | ||
|
|
0e016dee48 | ||
|
|
e143020e20 | ||
|
|
b343bb971d | ||
|
|
33afa0cf36 | ||
|
|
fa22ee2a16 | ||
|
|
e4139569d5 | ||
|
|
b7881ac9af | ||
|
|
07dbe2477f | ||
|
|
0285299f22 | ||
|
|
afed1b91b2 | ||
|
|
6a03e93450 | ||
|
|
8030dd6371 | ||
|
|
36e8c579ba | ||
|
|
2ae0b24b6e | ||
|
|
56c494024a | ||
|
|
279ba28afa | ||
|
|
9680174b39 | ||
|
|
8d6aa32e4b | ||
|
|
eff6f65a71 | ||
|
|
c272396c89 | ||
|
|
131026381b | ||
|
|
338ce8d0aa | ||
|
|
4ba5a08a26 | ||
|
|
89b176b251 | ||
|
|
e3ec4f560c | ||
|
|
68792c4256 | ||
|
|
c7101d432c | ||
|
|
22370a6e14 | ||
|
|
9b25fbf753 | ||
|
|
fea816416f | ||
|
|
d74d4ff2ad | ||
|
|
a629925124 | ||
|
|
49cd307026 | ||
|
|
e21eb7887c | ||
|
|
49c3ab78d1 | ||
|
|
c2d1a80875 | ||
|
|
674709eae0 | ||
|
|
792766fd37 | ||
|
|
07f72f3ba8 | ||
|
|
5ca0742586 | ||
|
|
866575feee | ||
|
|
5e9f95a9ef | ||
|
|
62d0023358 | ||
|
|
5eda4ce94c | ||
|
|
6c528d6a0f | ||
|
|
54a9762dfb | ||
|
|
64666ba42e | ||
|
|
72fd9982e4 | ||
|
|
104c173549 | ||
|
|
e3f1557099 | ||
|
|
b15d88710e | ||
|
|
a7577d9ae9 | ||
|
|
8bdbd242dd | ||
|
|
c743b8bfe0 | ||
|
|
d14dae097e | ||
|
|
84e3f21c4c | ||
|
|
9020ae67c8 | ||
|
|
7010bbb0e8 | ||
|
|
8235b6aa81 | ||
|
|
3ca9c87396 | ||
|
|
752a80fc60 | ||
|
|
99d11d94b9 | ||
|
|
4b5f5442f7 | ||
|
|
ade69c281b | ||
|
|
70a3885e6d | ||
|
|
e9dfe86550 | ||
|
|
b5fdf77cee | ||
|
|
a4a69fed1c | ||
|
|
e7c78938a0 | ||
|
|
9ba7acd05e | ||
|
|
93f759b672 | ||
|
|
8173bd1c45 | ||
|
|
931f668cf2 | ||
|
|
13bb0a7906 | ||
|
|
c90b2259ef | ||
|
|
8f9b8b631c | ||
|
|
ee731c8a92 | ||
|
|
30cd8e00b9 | ||
|
|
5cb8da0bf1 | ||
|
|
82f87161bd | ||
|
|
cc96633900 | ||
|
|
8714caa93c | ||
|
|
980f4571bd | ||
|
|
76354e605b | ||
|
|
eb0771c233 | ||
|
|
7a1a092f6b | ||
|
|
8a7fd14968 | ||
|
|
b284b2aabb | ||
|
|
73d9e92cf9 | ||
|
|
2116bdb62d | ||
|
|
a0ddfff751 | ||
|
|
cf339a930b | ||
|
|
d118ce65b7 | ||
|
|
8890b30e5f | ||
|
|
ebaff40268 | ||
|
|
015f0ac438 | ||
|
|
72c3f63b02 | ||
|
|
c5cec7d44c | ||
|
|
c6c621baf1 | ||
|
|
4abc0f4221 | ||
|
|
d710ef3b66 | ||
|
|
b5b18e46dc | ||
|
|
70f0cb6bf2 | ||
|
|
af66ff8692 | ||
|
|
d3b58a3053 | ||
|
|
1167fb9feb | ||
|
|
54d102c932 | ||
|
|
fa3eace6c3 | ||
|
|
2cdaa5c6e2 | ||
|
|
457b995f1c | ||
|
|
bc85925037 | ||
|
|
524efb5ea5 | ||
|
|
ebb075cdfb | ||
|
|
bc58b830eb | ||
|
|
b06a89f5f0 | ||
|
|
8548ba5b49 | ||
|
|
99883608bd | ||
|
|
de67da0f85 | ||
|
|
571e7fa804 | ||
|
|
82ea9c608c | ||
|
|
4985017bcd | ||
|
|
d7aca4feb6 | ||
|
|
10874028f3 | ||
|
|
dac90e7ec4 | ||
|
|
723f00c8ab | ||
|
|
692df84f28 | ||
|
|
28959b5884 | ||
|
|
08303c4635 | ||
|
|
09370e800a | ||
|
|
7fc9a76633 | ||
|
|
df0d5caa70 | ||
|
|
7a7f296c43 | ||
|
|
233a0a3b4c | ||
|
|
c3fea51536 | ||
|
|
2b2bffcfc2 | ||
|
|
e603f7027c | ||
|
|
7839ca7657 | ||
|
|
7b4403ada3 | ||
|
|
d615669c20 | ||
|
|
dde21aa97b | ||
|
|
3dcad1caca | ||
|
|
92b506a601 | ||
|
|
800dd22fad | ||
|
|
66f78ccf38 | ||
|
|
f31e0f31c2 | ||
|
|
c56652fd61 | ||
|
|
7d5a39db6f | ||
|
|
9c1cfecb13 | ||
|
|
7b0a3cf884 | ||
|
|
c9c6b66f69 | ||
|
|
1be35491e2 | ||
|
|
e2e816394f | ||
|
|
3fb1941e59 | ||
|
|
b5041fb44b | ||
|
|
a4257aac68 | ||
|
|
782a4d7fa5 | ||
|
|
6d39e33059 | ||
|
|
0d394f319f | ||
|
|
22b5b2f8f4 | ||
|
|
e8e83873e7 | ||
|
|
309318c4b6 | ||
|
|
5664786ab4 | ||
|
|
d64c349fe3 | ||
|
|
afa7fbe6bd | ||
|
|
b89ba23236 | ||
|
|
80176887f5 | ||
|
|
175f16e168 | ||
|
|
f96c218a9b | ||
|
|
5b824354ec | ||
|
|
0a9ba892a2 | ||
|
|
12e4ba3de8 | ||
|
|
9cc6eac782 | ||
|
|
3d8d577df4 | ||
|
|
ab465804c5 | ||
|
|
66d0c03dc7 | ||
|
|
88c0b3c629 | ||
|
|
5a5fb062f9 | ||
|
|
27608c1f2d | ||
|
|
a8c99be137 | ||
|
|
f85bcbe023 | ||
|
|
d7b145f64b | ||
|
|
834c35e670 | ||
|
|
21a1c12c52 | ||
|
|
d6dd9f82c4 | ||
|
|
e296de9ed1 | ||
|
|
ff99bfcb5a | ||
|
|
d8a0862430 | ||
|
|
ce100eacbb | ||
|
|
edc6ba42bd | ||
|
|
ab9e9c0d47 | ||
|
|
f9e2fd596f | ||
|
|
394ec9309f | ||
|
|
6591a39532 | ||
|
|
15cddf337e | ||
|
|
ee96da36ca | ||
|
|
a0661ef34b | ||
|
|
6471e43d60 | ||
|
|
e70ca97656 | ||
|
|
9c497f24d4 | ||
|
|
fc2f25c907 | ||
|
|
249532b0e3 | ||
|
|
36d51e5a60 | ||
|
|
922b3cdabd | ||
|
|
5ca680eb06 | ||
|
|
45fe60cdfe | ||
|
|
65b5afacf8 | ||
|
|
c9e90ca2c1 | ||
|
|
a36decd409 | ||
|
|
7fe20551f5 | ||
|
|
d5b387b04d | ||
|
|
52c1ee51aa | ||
|
|
d88763f18a | ||
|
|
3134bbc747 | ||
|
|
ee22f13f22 | ||
|
|
f93a0e04a2 | ||
|
|
7b8e0c47a4 | ||
|
|
bfe3ba925f | ||
|
|
7343206622 | ||
|
|
6e41f78863 | ||
|
|
93c87be579 | ||
|
|
f9a6140ad7 | ||
|
|
25dbc57b11 | ||
|
|
a03fe53dd5 | ||
|
|
56f52ffe7f | ||
|
|
c99d1f33a1 | ||
|
|
81f53a25b6 | ||
|
|
a146155524 | ||
|
|
9ae7c58266 | ||
|
|
0b2274122d | ||
|
|
24726e02f0 | ||
|
|
f78a5d9002 | ||
|
|
088d5092dc | ||
|
|
f3d2f9bb2c | ||
|
|
e542a1197f | ||
|
|
637172dbcb | ||
|
|
fb157bbe2d | ||
|
|
34a7f98de8 | ||
|
|
10c5bb621d | ||
|
|
0e63a16128 | ||
|
|
c31a4e2ba5 | ||
|
|
5653b5578d | ||
|
|
f4cae1278e | ||
|
|
4d28abff2a | ||
|
|
ddb465367e | ||
|
|
890da6c00d | ||
|
|
87365b6585 | ||
|
|
88ab354e79 | ||
|
|
4176a6b7cf | ||
|
|
a653057414 | ||
|
|
0959e9ff43 | ||
|
|
5ed1eeacbc | ||
|
|
bc8140125d | ||
|
|
cc02d5af08 | ||
|
|
04dbd783c2 | ||
|
|
a143b803bd | ||
|
|
e73c3d16f6 | ||
|
|
6878535724 | ||
|
|
a1bfd2a9ec | ||
|
|
5478672eaa | ||
|
|
ed0c6cc0bd | ||
|
|
55041ff122 | ||
|
|
aaf4b54c04 | ||
|
|
5adb60742b | ||
|
|
4085a0a431 | ||
|
|
9b9a6ddccc | ||
|
|
b8c81dae19 | ||
|
|
b3f2d62def | ||
|
|
61bb7670d5 | ||
|
|
161d2e64f3 | ||
|
|
39129fe306 | ||
|
|
8381d1708d | ||
|
|
cda90cb04b | ||
|
|
6b592d45e7 | ||
|
|
b8cb900ec1 | ||
|
|
4697098e38 | ||
|
|
870d8a69e9 | ||
|
|
57c0187386 | ||
|
|
9550f1b1a0 | ||
|
|
2f63ff75f0 | ||
|
|
f9b332bde3 | ||
|
|
838653c27c | ||
|
|
070a746a2a | ||
|
|
b64ec51224 | ||
|
|
7df07fc745 |
38
.bin/256color
Executable file
@@ -0,0 +1,38 @@
|
|||||||
|
#! /bin/sh
|
||||||
|
set -euf
|
||||||
|
|
||||||
|
pl() {
|
||||||
|
for i in $(seq $1 $(expr $2 - 1)); do
|
||||||
|
printf '\e[38;5;%sm%03i\e[m ' $i $i
|
||||||
|
done
|
||||||
|
printf '\e[38;5;%sm%03i\e[m\n' $2 $2
|
||||||
|
}
|
||||||
|
|
||||||
|
p() {
|
||||||
|
printf '\e[38;5;%sm%03i\e[m ' $1 $1
|
||||||
|
}
|
||||||
|
pn() {
|
||||||
|
printf '\e[38;5;%sm%03i\e[m\n' $1 $1
|
||||||
|
}
|
||||||
|
|
||||||
|
p6x6() {
|
||||||
|
for i in $(seq 0 5); do
|
||||||
|
for j in $(seq 0 5); do
|
||||||
|
p $(expr $1 + $i + $j \* 6)
|
||||||
|
done
|
||||||
|
echo
|
||||||
|
done
|
||||||
|
}
|
||||||
|
|
||||||
|
pl 0 7
|
||||||
|
pl 8 15
|
||||||
|
|
||||||
|
p6x6 16
|
||||||
|
p6x6 52
|
||||||
|
p6x6 88
|
||||||
|
p6x6 124
|
||||||
|
p6x6 160
|
||||||
|
p6x6 196
|
||||||
|
|
||||||
|
pl 232 243
|
||||||
|
pl 244 255
|
||||||
24
.bin/browser
Executable file
@@ -0,0 +1,24 @@
|
|||||||
|
#!/bin/sh -e
|
||||||
|
#
|
||||||
|
# Usage: browser
|
||||||
|
# pipe html to a browser
|
||||||
|
# e.g.
|
||||||
|
# $ echo '<h1>hi mom!</h1>' | browser
|
||||||
|
# $ ron -5 man/rip.5.ron | browser
|
||||||
|
|
||||||
|
if [ -t 0 ]; then
|
||||||
|
if [ -n "$1" ]; then
|
||||||
|
open $1
|
||||||
|
else
|
||||||
|
cat <<usage
|
||||||
|
Usage: browser
|
||||||
|
pipe html to a browser
|
||||||
|
$ echo '<h1>hi mom!</h1>' | browser
|
||||||
|
$ ron -5 man/rip.5.ron | browser
|
||||||
|
usage
|
||||||
|
fi
|
||||||
|
else
|
||||||
|
f="/tmp/browser.$RANDOM.html"
|
||||||
|
cat /dev/stdin > $f
|
||||||
|
xdg-open $f
|
||||||
|
fi
|
||||||
25
.bin/candyman
Executable file
@@ -0,0 +1,25 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
set -efu
|
||||||
|
|
||||||
|
usage() {
|
||||||
|
echo >&2 "$0 add-{reddit,telegram,youtube,twitch,twitter} NAME"
|
||||||
|
exit 1
|
||||||
|
}
|
||||||
|
|
||||||
|
candyman() {
|
||||||
|
curl -fsSv http://news.r/api -H content-type:application/json -d "$(jq -n "
|
||||||
|
{
|
||||||
|
command: \"PRIVMSG\",
|
||||||
|
params: [\"#all\", \"candyman: $1 $2\"]
|
||||||
|
}
|
||||||
|
")"
|
||||||
|
}
|
||||||
|
|
||||||
|
[ $# -ge 2 ] || usage
|
||||||
|
|
||||||
|
case "$1" in
|
||||||
|
add-reddit|add-telegram|add-youtube|add-twitter|add-twitch)
|
||||||
|
candyman "$@"
|
||||||
|
;;
|
||||||
|
*) usage;;
|
||||||
|
esac
|
||||||
13
.bin/countdown
Executable file
@@ -0,0 +1,13 @@
|
|||||||
|
#!/usr/bin/env -S awk -f
|
||||||
|
function z() {
|
||||||
|
getline < "/proc/uptime"
|
||||||
|
close("/proc/uptime")
|
||||||
|
return $0
|
||||||
|
}
|
||||||
|
BEGIN {
|
||||||
|
x = z()
|
||||||
|
while (1) {
|
||||||
|
y = z()
|
||||||
|
printf "%02d:%05.2f\r", (y - x) / 60, (y - x) % 60
|
||||||
|
}
|
||||||
|
}
|
||||||
34
.bin/horoscope.sh
Normal file
@@ -0,0 +1,34 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
set -efu
|
||||||
|
|
||||||
|
# Berlin: -d lodeg=13 -d lomin=22 -d losec=41 -d lodir=E -d ladeg=52 -d lamin=27 -d lasec=42 -d ladir=N -d usecoords=1 \
|
||||||
|
# Kassel: -d lodeg=9 -d lomin=32 -d losec=5 -d lodir=E -d ladeg=51 -d lamin=18 -d lasec=17 -d ladir=N -d usecoords=1 \
|
||||||
|
|
||||||
|
|
||||||
|
[ $# -eq 1 ] || {
|
||||||
|
echo >&2 Usage: "$0" TIMESTAMP
|
||||||
|
exit 1
|
||||||
|
}
|
||||||
|
|
||||||
|
export TZ=UTC
|
||||||
|
|
||||||
|
chart_path="$(mktemp /tmp/chart_XXX.pdf)"
|
||||||
|
|
||||||
|
timestamp="$1"
|
||||||
|
|
||||||
|
year="$(date -d "@$timestamp" +%Y)"
|
||||||
|
month="$(date -d "@$timestamp" +%m)"
|
||||||
|
day="$(date -d "@$timestamp" +%d)"
|
||||||
|
hour="$(date -d "@$timestamp" +%H)"
|
||||||
|
minute="$(date -d "@$timestamp" +%M)"
|
||||||
|
|
||||||
|
curl -sSL 'https://edifyingfellowship.org/astro/' \
|
||||||
|
-d lodeg=9 -d lomin=32 -d losec=5 -d lodir=E -d ladeg=51 -d lamin=18 -d lasec=17 -d ladir=N -d usecoords=1 \
|
||||||
|
-d ybyr="$year" -d ybmo="$month" -d ybdy="$day" -d ybhr="$hour" -d ybmi="$minute" -d ybsc=0 -d ybtz="$TZ" \
|
||||||
|
-d currenttime=0 \
|
||||||
|
-d title="$timestamp" \
|
||||||
|
-d options[]=VancouverWheel -d options[]=Arrow -d options[]=XBold -d options[]=HouseLabels -d options[]=Placidus \
|
||||||
|
-d options[]=Sun -d options[]=Moon -d options[]=Mercury -d options[]=Venus -d options[]=Mars -d options[]=Jupiter -d options[]=Saturn -d options[]=Uranus -d options[]=Neptune -d options[]=Pluto -d options[]=Ascendant -d options[]=MC -d options[]=Lilith -d options[]=MeanNode -d options[]=TrueNode \
|
||||||
|
-d aspectpct=100 -d format=PDF -d Submit= -o "$chart_path"
|
||||||
|
|
||||||
|
zathura "$chart_path"
|
||||||
15
.bin/libib.sh
Executable file
@@ -0,0 +1,15 @@
|
|||||||
|
#!/usr/bin/env bash
|
||||||
|
session_id=7b638c194d9bda74f80043045018cc9e
|
||||||
|
|
||||||
|
declare -A libraries
|
||||||
|
|
||||||
|
libraries["Literatur"]=344428
|
||||||
|
libraries["Sprache"]=344160
|
||||||
|
libraries["Miscellanea"]=344427
|
||||||
|
libraries["Wissenschaft"]=344429
|
||||||
|
libraries["Relicta"]=565920
|
||||||
|
|
||||||
|
for library in ${!libraries[@]}
|
||||||
|
do
|
||||||
|
curl -sSL 'https://www.libib.com/library/functions/csv-export.php' -H "Cookie: PHPSESSID=$session_id" -d export="${libraries[$library]}" > "$library.csv"
|
||||||
|
done
|
||||||
81
.bin/lieferando.sh
Normal file
@@ -0,0 +1,81 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
set -efu
|
||||||
|
|
||||||
|
if echo "$1" | grep -Eq '[[:digit:]]{5}'; then
|
||||||
|
PLZ="$1"
|
||||||
|
else
|
||||||
|
echo >&2 "Usage: $0 PLZ"
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
lieferando_dir=/tmp/lieferando
|
||||||
|
mkdir -p "$lieferando_dir/$PLZ"
|
||||||
|
|
||||||
|
fetch_restaurants() {
|
||||||
|
cache_path="$lieferando_dir/$PLZ.json"
|
||||||
|
|
||||||
|
if [ -r "$cache_path" ]; then
|
||||||
|
cat "$cache_path"
|
||||||
|
else
|
||||||
|
w3m -dump_source "http://www.lieferando.de/$PLZ" \
|
||||||
|
| gunzip \
|
||||||
|
| sed -n '/var restaurants/,/];$/p' \
|
||||||
|
| sed 's/var restaurants =//;$s/;$//' \
|
||||||
|
| prettier --parser=json \
|
||||||
|
| jq '
|
||||||
|
map({
|
||||||
|
name: .[30] | .name,
|
||||||
|
category: .[30] |.categories | split(", "),
|
||||||
|
url: "http://lieferando.de\(.[30] | .url)",
|
||||||
|
minutes: .[19],
|
||||||
|
minimum: .[10],
|
||||||
|
delivery: .[14]
|
||||||
|
})' \
|
||||||
|
| tee "$cache_path"
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
fetch_menu() {
|
||||||
|
[ $# -eq 1 ] || exit 1
|
||||||
|
|
||||||
|
slug="$(echo "$1" | sed 's!.*/!!')"
|
||||||
|
cache_path="$lieferando_dir/$PLZ/$slug.json"
|
||||||
|
|
||||||
|
if [ -r "$cache_path" ]; then
|
||||||
|
cat "$cache_path"
|
||||||
|
else
|
||||||
|
w3m -dump_source "$1" \
|
||||||
|
| gunzip \
|
||||||
|
| sed -n '/var MenucardProducts/,/\];/p' \
|
||||||
|
| sed 's/var MenucardProducts =//;s/;$//' \
|
||||||
|
| jq -r '
|
||||||
|
unique_by(.productId)
|
||||||
|
| group_by(.categoryId)
|
||||||
|
| flatten
|
||||||
|
' \
|
||||||
|
| tee "$cache_path"
|
||||||
|
fi
|
||||||
|
}
|
||||||
|
|
||||||
|
data="$(fetch_restaurants)"
|
||||||
|
|
||||||
|
# echo "$data" | jq -c '.[]' | while read -r restaurant; do
|
||||||
|
# fetch_menu "$(echo "$restaurant" | jq -r .url)"
|
||||||
|
# done
|
||||||
|
|
||||||
|
selected_categories="$(echo "$data" | jq -r 'map(.category) | flatten | unique | .[]' | fzf -m)"
|
||||||
|
|
||||||
|
selected_restaurant_url="$(echo "$selected_categories" | jq --argjson restaurants "$data" -sRr '
|
||||||
|
split("\n")[:-1] as $categories
|
||||||
|
| $restaurants[]
|
||||||
|
| select(.category - $categories != .category)
|
||||||
|
| "\(.name) [🚴\(.minutes)min 💰\(.minimum)€ + \(.delivery)€] (\(.url))"
|
||||||
|
' \
|
||||||
|
| fzf \
|
||||||
|
| sed 's/.*(//;s/)$//'
|
||||||
|
)"
|
||||||
|
|
||||||
|
fetch_menu "$selected_restaurant_url" \
|
||||||
|
| jq -r '.[] | "\(.price)\t\(.name)"' \
|
||||||
|
| fzf -m \
|
||||||
|
| awk '{print $0; sum += $1} END {print "-----"; print sum}'
|
||||||
17
.bin/lit.awk
Normal file
@@ -0,0 +1,17 @@
|
|||||||
|
BEGIN {
|
||||||
|
if (!comment) comment = "--";
|
||||||
|
if (!begin) begin = "\\begin{code}";
|
||||||
|
if (!end) end = "\\end{code}";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
if ($0 == begin) {
|
||||||
|
code = 1;
|
||||||
|
print comment, $0;
|
||||||
|
} else if ($0 == end) {
|
||||||
|
code = 0;
|
||||||
|
print comment, $0;
|
||||||
|
} else {
|
||||||
|
if (code) print $0;
|
||||||
|
else print comment, $0;
|
||||||
|
}
|
||||||
|
}
|
||||||
3
.bin/mail-current-part
Executable file
@@ -0,0 +1,3 @@
|
|||||||
|
#! /bin/sh
|
||||||
|
set -efu
|
||||||
|
exec curl -fSs --unix-socket /tmp/much.api.sock http://localhost/current/part
|
||||||
27
.bin/mail-current-query-find-part-by-name
Executable file
@@ -0,0 +1,27 @@
|
|||||||
|
#! /bin/sh
|
||||||
|
# usage: mail-current-query-find-part-by-name NAME
|
||||||
|
set -efu
|
||||||
|
|
||||||
|
name=$1
|
||||||
|
|
||||||
|
query=$(mail-current-query)
|
||||||
|
result=$(notmuch show --entire-thread=false --format=json "$query")
|
||||||
|
|
||||||
|
part_id=$(printf %s "$result" | jq --arg name "$name" '
|
||||||
|
[
|
||||||
|
recurse |
|
||||||
|
select(type == "object") |
|
||||||
|
{ id, name: .filename } |
|
||||||
|
select(.id != null and .name != null)
|
||||||
|
] |
|
||||||
|
map(select(.name == $name))[0].id
|
||||||
|
')
|
||||||
|
|
||||||
|
if test "$part_id" = null; then
|
||||||
|
printf 'error: could not find part with name %s\n' \
|
||||||
|
"$name" \
|
||||||
|
>&2
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
exec notmuch show --part="$part_id" "$query"
|
||||||
39
.bin/mail-current-query-find-part-by-type
Executable file
@@ -0,0 +1,39 @@
|
|||||||
|
#! /bin/sh
|
||||||
|
# usage: mail-current-query-find-part-by-type TYPE
|
||||||
|
set -efu
|
||||||
|
|
||||||
|
type=$1
|
||||||
|
|
||||||
|
query=$(mail-current-query)
|
||||||
|
result=$(notmuch show --entire-thread=false --format=json "$query")
|
||||||
|
|
||||||
|
part_id=$(printf %s "$result" | jq --arg type "$type" '
|
||||||
|
#flatten|map(select(.!=null))[0].body[0] |
|
||||||
|
#
|
||||||
|
#if .["content-type"] == $type then
|
||||||
|
# .id
|
||||||
|
#elif .["content-type"] | test("^multipart/") then
|
||||||
|
# .content|map(select(.["content-type"]==$type))[0].id
|
||||||
|
#else
|
||||||
|
# null
|
||||||
|
#end
|
||||||
|
|
||||||
|
[
|
||||||
|
recurse |
|
||||||
|
select(type == "object") |
|
||||||
|
{ id, type: .["content-type"] } |
|
||||||
|
select(.id != null and .type != null)
|
||||||
|
] |
|
||||||
|
map(select(.type == $type))[0].id
|
||||||
|
')
|
||||||
|
|
||||||
|
if test "$part_id" = null; then
|
||||||
|
printf 'error: could not find part with type %s\n' \
|
||||||
|
"$type" \
|
||||||
|
>&2
|
||||||
|
exit 1
|
||||||
|
fi
|
||||||
|
|
||||||
|
exec notmuch show --part="$part_id" "$query"
|
||||||
|
|
||||||
|
|
||||||
23
.bin/pdf-ocr.sh
Executable file
@@ -0,0 +1,23 @@
|
|||||||
|
#!/usr/bin/env nix-shell
|
||||||
|
#! nix-shell -i bash -p poppler_utils tesseract4
|
||||||
|
set -eu
|
||||||
|
|
||||||
|
pdf_path="$(realpath "$1")"
|
||||||
|
|
||||||
|
[ -f "$pdf_path" ] || {
|
||||||
|
echo "Usage: $0 FILE.pdf" >&2
|
||||||
|
exit 1
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
tmpdir="$(mktemp -d)"
|
||||||
|
trap 'rm -rf $tmpdir' EXIT
|
||||||
|
|
||||||
|
cd "$tmpdir"
|
||||||
|
|
||||||
|
pdftoppm -png "$pdf_path" pdf-ocr
|
||||||
|
for png in pdf-ocr*.png; do
|
||||||
|
tesseract "$png" "$png.txt" 2>/dev/null
|
||||||
|
done
|
||||||
|
|
||||||
|
cat pdf-ocr-*.txt
|
||||||
2
.bin/playlist_entries.sh
Executable file
@@ -0,0 +1,2 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
youtube-dl -ij "$*" | jq -sr '.[] | .webpage_url'
|
||||||
17
.bin/proxies.sh
Normal file
@@ -0,0 +1,17 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
curl -sSL https://www.netzwelt.de/proxy/index.html \
|
||||||
|
| pup ".tblc" \
|
||||||
|
| xml-to-json /dev/stdin \
|
||||||
|
| jq '
|
||||||
|
.div.table.tbody.tr
|
||||||
|
| map(
|
||||||
|
.td
|
||||||
|
| {
|
||||||
|
ip: .[0].a.value,
|
||||||
|
port: .[1],
|
||||||
|
country: .[2] | (if type == "string" then . else .a.value end),
|
||||||
|
security: .[3],
|
||||||
|
protocol: .[4]
|
||||||
|
}
|
||||||
|
)
|
||||||
|
'
|
||||||
4
.bin/readme
Executable file
@@ -0,0 +1,4 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
curl -sSL "https://raw.githubusercontent.com/$*/master/README.md" \
|
||||||
|
| pandoc -f gfm -t man -s \
|
||||||
|
| man -l -
|
||||||
6
.bin/sample-pdf.sh
Executable file
@@ -0,0 +1,6 @@
|
|||||||
|
#!/bin/sh
|
||||||
|
|
||||||
|
filepath="$(shuf --head-count=1)"
|
||||||
|
pages="$(pdfinfo "$filepath" | awk '/^Pages:/{print $2}')"
|
||||||
|
random_page="$(shuf --input-range="1-$pages" --head-count=1)"
|
||||||
|
zathura --page="$random_page" "$filepath"
|
||||||
6
.gitignore
vendored
@@ -1,2 +1,6 @@
|
|||||||
secrets.nix
|
|
||||||
result
|
result
|
||||||
|
.direnv
|
||||||
|
.envrc
|
||||||
|
.history
|
||||||
|
.todo
|
||||||
|
node_modules
|
||||||
|
|||||||
6
.gitmodules
vendored
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
[submodule "submodules/menstruation-telegram"]
|
||||||
|
path = submodules/menstruation-telegram
|
||||||
|
url = https://github.com/kmein/menstruation-telegram
|
||||||
|
[submodule "submodules/menstruation-backend"]
|
||||||
|
path = submodules/menstruation-backend
|
||||||
|
url = https://github.com/kmein/menstruation.rs
|
||||||
10
.versions/home-manager.json
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
{
|
||||||
|
"url": "https://github.com/nix-community/home-manager.git",
|
||||||
|
"rev": "bcf03fa16a1f06b8a0abb27bf49afa8d6fffe8f1",
|
||||||
|
"date": "2021-11-15T23:33:21+00:00",
|
||||||
|
"path": "/nix/store/6yb649xh4pm8n49azlg769imarkk2xpw-home-manager",
|
||||||
|
"sha256": "0nznlb2xgkvdav6d4qls2w81m3p3h4hdbwbp2nwqkiszkp7j1bln",
|
||||||
|
"fetchSubmodules": false,
|
||||||
|
"deepClone": false,
|
||||||
|
"leaveDotGit": false
|
||||||
|
}
|
||||||
10
.versions/krops.json
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
{
|
||||||
|
"url": "https://cgit.krebsco.de/krops",
|
||||||
|
"rev": "cccebf3ff7a53336b3f106cb96dddd5892d427ed",
|
||||||
|
"date": "2021-03-23T22:47:37+01:00",
|
||||||
|
"path": "/nix/store/mz13xxnil35lwsf90hwnrm2agir7hb51-krops",
|
||||||
|
"sha256": "07mg3iaqjf1w49vmwfchi7b1w55bh7rvsbgicp2m47gnj9alwdb6",
|
||||||
|
"fetchSubmodules": false,
|
||||||
|
"deepClone": false,
|
||||||
|
"leaveDotGit": false
|
||||||
|
}
|
||||||
10
.versions/nixpkgs-mozilla.json
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
{
|
||||||
|
"url": "https://github.com/mozilla/nixpkgs-mozilla",
|
||||||
|
"rev": "764ed9c9721f66c945d77d7b09fb8c1879ec67c6",
|
||||||
|
"date": "2021-11-16T09:46:48-05:00",
|
||||||
|
"path": "/nix/store/p75z3ihhdy7zxhnfqdj4mhzg9k0rfz7f-nixpkgs-mozilla",
|
||||||
|
"sha256": "0lkhaz4hciisvfhq8v2wlp019v6gg5vd4sf5vx3cj4d5b2zf0h4v",
|
||||||
|
"fetchSubmodules": false,
|
||||||
|
"deepClone": false,
|
||||||
|
"leaveDotGit": false
|
||||||
|
}
|
||||||
10
.versions/nixpkgs-unstable.json
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
{
|
||||||
|
"url": "https://github.com/NixOS/nixpkgs.git",
|
||||||
|
"rev": "8df865561fbc53922f1e801c3deeb53c12ce8c4f",
|
||||||
|
"date": "2021-11-18T22:15:39-08:00",
|
||||||
|
"path": "/nix/store/a4n904v45pl3zi8q59l77dha47v1mwl0-nixpkgs",
|
||||||
|
"sha256": "092ivyacs2iz2zb572jki2kdi6nylrm10caa0kv2hdfr5yjzs5w7",
|
||||||
|
"fetchSubmodules": false,
|
||||||
|
"deepClone": false,
|
||||||
|
"leaveDotGit": false
|
||||||
|
}
|
||||||
10
.versions/nixpkgs.json
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
{
|
||||||
|
"url": "https://github.com/NixOS/nixpkgs.git",
|
||||||
|
"rev": "46251a79f752ae1d46ef733e8e9760b6d3429da4",
|
||||||
|
"date": "2021-11-14T21:40:46-05:00",
|
||||||
|
"path": "/nix/store/4j2xxc8kqvnif4nhsd0f58dymj3ckryd-nixpkgs",
|
||||||
|
"sha256": "1xsp0xyrf8arjkf4wi09n96kbg0r8igsmzx8bhc1nj4nr078p0pg",
|
||||||
|
"fetchSubmodules": false,
|
||||||
|
"deepClone": false,
|
||||||
|
"leaveDotGit": false
|
||||||
|
}
|
||||||
10
.versions/nur.json
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
{
|
||||||
|
"url": "https://github.com/nix-community/NUR",
|
||||||
|
"rev": "69746e0eb8efba6ed7776dd910c4ebc3bc85f6b6",
|
||||||
|
"date": "2021-11-19T05:31:00+00:00",
|
||||||
|
"path": "/nix/store/1lxn1j1dg20q5kh47jnq56a8yd1570xg-NUR",
|
||||||
|
"sha256": "03scqq7j7lywxzcy2qsyxiynms3jmiadvz825pwfwg5kg5p75m9c",
|
||||||
|
"fetchSubmodules": false,
|
||||||
|
"deepClone": false,
|
||||||
|
"leaveDotGit": false
|
||||||
|
}
|
||||||
10
.versions/retiolum.json
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
{
|
||||||
|
"url": "https://github.com/krebs/retiolum",
|
||||||
|
"rev": "3fc3147ef4c644b4008f1425fae701f2d371db52",
|
||||||
|
"date": "2021-10-30T16:02:13+02:00",
|
||||||
|
"path": "/nix/store/ybc3zn2ql3ml9mfxdlvya71pz5hjvkh2-retiolum",
|
||||||
|
"sha256": "1vh8s0dknnsy9c68l807difjnar2m6xbbwj51f308bl8wyjyq4y5",
|
||||||
|
"fetchSubmodules": false,
|
||||||
|
"deepClone": false,
|
||||||
|
"leaveDotGit": false
|
||||||
|
}
|
||||||
10
.versions/stockholm.json
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
{
|
||||||
|
"url": "https://cgit.krebsco.de/stockholm",
|
||||||
|
"rev": "c979f7009f5ff1b2d25158aff1bca0f5be2dba54",
|
||||||
|
"date": "2021-11-08T05:14:49+01:00",
|
||||||
|
"path": "/nix/store/shz2yw0p30ibmw3lgr11ckzz0y4kmz4y-stockholm",
|
||||||
|
"sha256": "13yds6hwh6ah4mks8jrg7syigfmp17ylr7706jpvdzfy9ihj81wh",
|
||||||
|
"fetchSubmodules": false,
|
||||||
|
"deepClone": false,
|
||||||
|
"leaveDotGit": false
|
||||||
|
}
|
||||||
|
Before Width: | Height: | Size: 14 KiB |
|
Before Width: | Height: | Size: 1.4 MiB |
|
Before Width: | Height: | Size: 1.4 MiB |
|
Before Width: | Height: | Size: 512 KiB |
|
Before Width: | Height: | Size: 653 KiB |
|
Before Width: | Height: | Size: 325 KiB |
|
Before Width: | Height: | Size: 1.1 MiB |
|
Before Width: | Height: | Size: 477 KiB |
|
Before Width: | Height: | Size: 1.4 MiB |
BIN
art/file.jpeg
|
Before Width: | Height: | Size: 2.0 MiB |
|
Before Width: | Height: | Size: 66 KiB |
|
Before Width: | Height: | Size: 2.5 MiB |
|
Before Width: | Height: | Size: 345 KiB |
|
Before Width: | Height: | Size: 210 KiB |
45
configs/alacritty.nix
Normal file
@@ -0,0 +1,45 @@
|
|||||||
|
{ pkgs, lib, config, ... }:
|
||||||
|
{
|
||||||
|
environment.variables.TERMINAL = "alacritty";
|
||||||
|
|
||||||
|
environment.systemPackages = [
|
||||||
|
pkgs.alacritty
|
||||||
|
];
|
||||||
|
|
||||||
|
home-manager.users.me.xdg.configFile =
|
||||||
|
let
|
||||||
|
inherit (import <niveum/lib>) colours;
|
||||||
|
colourNames = [ "black" "red" "green" "yellow" "blue" "magenta" "cyan" "white" ];
|
||||||
|
colourPairs = lib.getAttrs colourNames colours;
|
||||||
|
in {
|
||||||
|
"alacritty/alacritty.yml".source = (pkgs.formats.yaml {}).generate "alacritty.yml" {
|
||||||
|
background_opacity = 0.9;
|
||||||
|
colors = {
|
||||||
|
primary = { inherit (colours) background foreground; };
|
||||||
|
normal = lib.mapAttrs (_: colour: colour.dark) colourPairs;
|
||||||
|
bright = lib.mapAttrs (_: colour: colour.bright) colourPairs;
|
||||||
|
};
|
||||||
|
font = {
|
||||||
|
normal.family = "Monospace";
|
||||||
|
size = 6;
|
||||||
|
};
|
||||||
|
key_bindings = [
|
||||||
|
{
|
||||||
|
key = "Plus";
|
||||||
|
mods = "Control";
|
||||||
|
action = "IncreaseFontSize";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "Minus";
|
||||||
|
mods = "Control";
|
||||||
|
action = "DecreaseFontSize";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
key = "Key0";
|
||||||
|
mods = "Control";
|
||||||
|
action = "ResetFontSize";
|
||||||
|
}
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
@@ -1,6 +1,7 @@
|
|||||||
{
|
{
|
||||||
programs.bash = {
|
programs.bash = {
|
||||||
promptInit = ''PS1="$(tput bold)\w \$([[ \$? == 0 ]] && echo \"\[\033[1;32m\]\" || echo \"\[\033[1;31m\]\")\$$(tput sgr0) "'';
|
promptInit = ''
|
||||||
|
PS1="$(tput bold)\w \$([[ \$? == 0 ]] && echo \"\[\033[1;32m\]\" || echo \"\[\033[1;31m\]\")\$$(tput sgr0) "'';
|
||||||
interactiveShellInit = ''
|
interactiveShellInit = ''
|
||||||
set -o vi
|
set -o vi
|
||||||
'';
|
'';
|
||||||
|
|||||||
17
configs/battery.nix
Normal file
@@ -0,0 +1,17 @@
|
|||||||
|
{ config, pkgs, ... }:
|
||||||
|
{
|
||||||
|
boot.extraModulePackages = with config.boot.kernelPackages; [
|
||||||
|
tp_smapi
|
||||||
|
acpi_call
|
||||||
|
];
|
||||||
|
boot.kernelModules = [ "tp_smapi" "acpi_call" ];
|
||||||
|
environment.systemPackages = [ pkgs.tpacpi-bat ];
|
||||||
|
|
||||||
|
services.tlp = {
|
||||||
|
enable = true;
|
||||||
|
settings = {
|
||||||
|
START_CHARGE_THRESH_BAT0 = 80;
|
||||||
|
STOP_CHARGE_THRESH_BAT0 = 95;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
11
configs/beets.nix
Normal file
@@ -0,0 +1,11 @@
|
|||||||
|
{ lib, pkgs, ... }:
|
||||||
|
{
|
||||||
|
environment.systemPackages = [ pkgs.beets ];
|
||||||
|
home-manager.users.me.xdg.configFile = {
|
||||||
|
"beets/config.yaml".source = (pkgs.formats.yaml {}).generate "config.yaml" {
|
||||||
|
directory = "~/cloud/syncthing/music";
|
||||||
|
library = "~/cloud/syncthing/common/music.db";
|
||||||
|
plugins = toString [ "fetchart" "lastgenre" ];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
@@ -1,16 +1,11 @@
|
|||||||
{ pkgs, ... }:
|
{ pkgs, lib, ... }: {
|
||||||
{
|
|
||||||
hardware.bluetooth = {
|
hardware.bluetooth = {
|
||||||
enable = true;
|
enable = true;
|
||||||
extraConfig = ''
|
settings.General.Enable =
|
||||||
[General]
|
lib.concatStringsSep "," [ "Source" "Sink" "Media" "Socket" ];
|
||||||
Enable=Source,Sink,Media,Socket
|
|
||||||
'';
|
|
||||||
};
|
};
|
||||||
|
|
||||||
environment.systemPackages = [ pkgs.blueman ];
|
environment.systemPackages = [ pkgs.blueman ];
|
||||||
|
|
||||||
home-manager.users.me = {
|
home-manager.users.me = { services.blueman-applet.enable = false; };
|
||||||
services.blueman-applet.enable = true;
|
|
||||||
};
|
|
||||||
}
|
}
|
||||||
|
|||||||
57
configs/bvg.nix
Normal file
@@ -0,0 +1,57 @@
|
|||||||
|
{ pkgs, lib, ... }:
|
||||||
|
let
|
||||||
|
inherit (import <niveum/lib>) serveHtml;
|
||||||
|
stations = [
|
||||||
|
900068204 # A/M
|
||||||
|
900068302 # KAS
|
||||||
|
900068203 # B-P
|
||||||
|
];
|
||||||
|
fahrplan = pkgs.writeText "fahrplan.html" ''
|
||||||
|
<!DOCTYPE html>
|
||||||
|
<title>Fahrplan</title>
|
||||||
|
<link
|
||||||
|
rel="icon"
|
||||||
|
type="image/x-icon"
|
||||||
|
href="https://mobil.bvg.de/Fahrinfo/img/ua_xhtml/logo.gif"
|
||||||
|
/>
|
||||||
|
<style>
|
||||||
|
body {
|
||||||
|
margin: 0;
|
||||||
|
--bvg-yellow: #f0d722;
|
||||||
|
}
|
||||||
|
#fahrplan {
|
||||||
|
display: flex;
|
||||||
|
height: 100vh;
|
||||||
|
width: 100%;
|
||||||
|
flex-direction: row;
|
||||||
|
}
|
||||||
|
#fahrplan iframe {
|
||||||
|
flex-grow: 1;
|
||||||
|
border: none;
|
||||||
|
}
|
||||||
|
#fahrplan iframe + iframe {
|
||||||
|
border-left: 2px solid var(--bvg-yellow);
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
<body>
|
||||||
|
<div id="fahrplan">
|
||||||
|
${lib.concatMapStrings (station: ''
|
||||||
|
<iframe scrolling="no" src="https://mobil.bvg.de/Fahrinfo/bin/stboard.bin/dox?ld=0.1&input=${toString station}&boardType=depRT&start=yes"></iframe>
|
||||||
|
'') stations}
|
||||||
|
</div>
|
||||||
|
</body>
|
||||||
|
'';
|
||||||
|
in
|
||||||
|
{
|
||||||
|
services.nginx = {
|
||||||
|
enable = true;
|
||||||
|
recommendedGzipSettings = true;
|
||||||
|
recommendedOptimisation = true;
|
||||||
|
recommendedProxySettings = true;
|
||||||
|
recommendedTlsSettings = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
services.nginx.virtualHosts."bvg.kmein.r" = {
|
||||||
|
locations."/".extraConfig = serveHtml fahrplan pkgs;
|
||||||
|
};
|
||||||
|
}
|
||||||
28
configs/ccc.nix
Normal file
@@ -0,0 +1,28 @@
|
|||||||
|
{ pkgs, ... }:
|
||||||
|
# https://paste.sr.ht/~erictapen/11716989e489b600f237041b6d657fdf0ee17b34
|
||||||
|
let
|
||||||
|
certificate = pkgs.stdenv.mkDerivation rec {
|
||||||
|
name = "dst-root-ca-x3.pem";
|
||||||
|
src = builtins.toFile "${name}.sed" ''
|
||||||
|
1,/DST Root CA X3/d
|
||||||
|
1,/-----END CERTIFICATE-----/p
|
||||||
|
'';
|
||||||
|
nativeBuildInputs = with pkgs; [ cacert gnused ];
|
||||||
|
phases = "installPhase";
|
||||||
|
installPhase = ''
|
||||||
|
${pkgs.gnused}/bin/sed -n -f $src ${pkgs.cacert}/etc/ssl/certs/ca-bundle.crt > $out
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
in {
|
||||||
|
networking.wireless.networks."36C3" = {
|
||||||
|
auth = ''
|
||||||
|
key_mgmt=WPA-EAP
|
||||||
|
eap=TTLS
|
||||||
|
identity="kmein"
|
||||||
|
password=" "
|
||||||
|
ca_cert="${certificate}"
|
||||||
|
altsubject_match="DNS:radius.c3noc.net"
|
||||||
|
phase2="auth=PAP"
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
}
|
||||||
@@ -1,17 +1,16 @@
|
|||||||
{ pkgs, ... }:
|
{ pkgs, ... }: {
|
||||||
{
|
|
||||||
programs.chromium = {
|
programs.chromium = {
|
||||||
enable = true;
|
enable = true;
|
||||||
extensions = [
|
extensions = [
|
||||||
"hdokiejnpimakedhajhdlcegeplioahd" # LastPass
|
"nngceckbapebfimnlniiiahkandclblb" # BitWarden
|
||||||
"ihlenndgcmojhcghmfjfneahoeklbjjh" # cVim
|
# "ihlenndgcmojhcghmfjfneahoeklbjjh" # cVim
|
||||||
"fpnmgdkabkmnadcjpehmlllkndpkmiak" # Wayback Machine
|
# "fpnmgdkabkmnadcjpehmlllkndpkmiak" # Wayback Machine
|
||||||
"cjpalhdlnbpafiamejdnhcphjbkeiagm" # uBlock Origin
|
"cjpalhdlnbpafiamejdnhcphjbkeiagm" # uBlock Origin
|
||||||
"iaalpfgpbocpdfblpnhhgllgbdbchmia" # asciidoctor
|
"khncfooichmfjbepaaaebmommgaepoid" # Remove YouTube Recommended Videos
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
environment.systemPackages = [ pkgs.chromium ];
|
environment.systemPackages = [ pkgs.chromium pkgs.brave ];
|
||||||
|
|
||||||
niveum.applications.browser = "chromium";
|
environment.variables.BROWSER = "brave";
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,26 +1,41 @@
|
|||||||
{ config, lib, pkgs, ... }:
|
{ config, lib, pkgs, ... }: {
|
||||||
{
|
|
||||||
imports = [
|
imports = [
|
||||||
<modules/seafile.nix>
|
<niveum/modules/dropbox.nix>
|
||||||
<modules/google-drive.nix>
|
|
||||||
<modules/dropbox.nix>
|
|
||||||
<stockholm/krebs/3modules/syncthing.nix>
|
|
||||||
];
|
];
|
||||||
|
|
||||||
niveum.dropbox = {
|
niveum = {
|
||||||
enable = true;
|
dropbox.enable = false;
|
||||||
user = config.users.users.me;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
niveum.seafile = {
|
system.activationScripts.home-symlinks = ''
|
||||||
enable = true;
|
ln -sfn ${config.users.users.me.home}/cloud/syncthing/common/mahlzeit ${config.users.users.me.home}/mahlzeit
|
||||||
user = config.users.users.me;
|
ln -sfn ${config.users.users.me.home}/cloud/Seafile/Wiki ${config.users.users.me.home}/notes
|
||||||
|
ln -sfn ${config.users.users.me.home}/cloud/Seafile/Uni ${config.users.users.me.home}/uni
|
||||||
|
'';
|
||||||
|
|
||||||
|
home-manager.users.me = {
|
||||||
|
services.nextcloud-client.enable = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
niveum.google-drive = rec {
|
environment.systemPackages = [
|
||||||
enable = true;
|
(pkgs.writers.writeDashBin "book" ''
|
||||||
directory = "${user.home}/cloud/gdrive";
|
set -efu
|
||||||
user = config.users.users.me;
|
book="$({
|
||||||
|
${pkgs.findutils}/bin/find ${config.users.users.me.home}/cloud/syncthing/library -type f
|
||||||
|
${pkgs.findutils}/bin/find ${config.users.users.me.home}/cloud/Seafile/Books -type f
|
||||||
|
} | ${pkgs.fzf}/bin/fzf)"
|
||||||
|
${pkgs.zathura}/bin/zathura "$book"
|
||||||
|
'')
|
||||||
|
];
|
||||||
|
|
||||||
|
fileSystems."/media/moodle" = {
|
||||||
|
device = "zaatar.r:/moodle";
|
||||||
|
fsType = "nfs";
|
||||||
|
options = [
|
||||||
|
"x-systemd.idle-timeout=600"
|
||||||
|
"noauto"
|
||||||
|
"x-systemd.automount"
|
||||||
|
];
|
||||||
};
|
};
|
||||||
|
|
||||||
services.syncthing = rec {
|
services.syncthing = rec {
|
||||||
@@ -29,20 +44,21 @@
|
|||||||
openDefaultPorts = true;
|
openDefaultPorts = true;
|
||||||
configDir = "/home/kfm/.config/syncthing";
|
configDir = "/home/kfm/.config/syncthing";
|
||||||
dataDir = "/home/kfm/.config/syncthing";
|
dataDir = "/home/kfm/.config/syncthing";
|
||||||
};
|
declarative = rec {
|
||||||
|
cert = toString <system-secrets/syncthing/cert.pem>;
|
||||||
krebs.syncthing = rec {
|
key = toString <system-secrets/syncthing/key.pem>;
|
||||||
enable = true;
|
inherit ((import <niveum/lib>).syncthing) devices;
|
||||||
key = toString <secrets/syncthing/key.pem>;
|
folders =
|
||||||
cert = toString <secrets/syncthing/cert.pem>;
|
let cloud-dir = "${config.users.users.me.home}/cloud";
|
||||||
peers = {
|
in {
|
||||||
homeros.id = "HSOL72W-MMN346W-C3WCWCH-OTRKJYG-MY2WWV6-P7JUHN7-5WYYYRV-ZMH4KAA";
|
"${cloud-dir}/syncthing/common".devices = [ "kabsa" "manakish" ];
|
||||||
scardanelli.id = "7CZYHEX-3CSFDQU-PEEMYHG-6XGQ2ZD-KGVUWH5-GFRB2XK-FP57ERX-7APZUQU";
|
"${cloud-dir}/syncthing/library".devices = [ "kabsa" "manakish" "heym" ];
|
||||||
rilke.id = "NYNNHXP-7JMSTXG-SVNOPWD-RWXCCCL-CBOVBEI-X4QPLF4-NJA5G2P-RSGYRQQ";
|
"${cloud-dir}/syncthing/mundoiu".devices = [ "kabsa" "manakish" "heym" ];
|
||||||
wilde.id = "R6DEBD7-G5RYDKN-VFA3HPO-WX4DNVI-373F7OQ-AW5MZTT-3L4BDVW-Y6ROEAF";
|
"${cloud-dir}/syncthing/music" = {
|
||||||
|
devices = [ "kabsa" "manakish" "heym" "zaatar" ];
|
||||||
|
id = "music";
|
||||||
|
};
|
||||||
|
};
|
||||||
};
|
};
|
||||||
folders."${config.users.users.me.home}/cloud/syncthing/common".peers = [ "homeros" "scardanelli" "wilde" ];
|
|
||||||
folders."${config.users.users.me.home}/cloud/syncthing/library".peers = lib.attrNames peers;
|
|
||||||
folders."${config.users.users.me.home}/cloud/syncthing/mundoiu".peers = lib.attrNames peers;
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -2,7 +2,7 @@
|
|||||||
services.compton = {
|
services.compton = {
|
||||||
enable = true;
|
enable = true;
|
||||||
shadow = true;
|
shadow = true;
|
||||||
menuOpacity = "0.9";
|
menuOpacity = 0.9;
|
||||||
shadowOpacity = "0.3";
|
shadowOpacity = 0.3;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,258 +1,162 @@
|
|||||||
{ pkgs, lib, config, ... }:
|
{ pkgs, lib, config, options, ... }:
|
||||||
{
|
let
|
||||||
|
inherit (lib.strings) makeBinPath;
|
||||||
|
inherit (import <niveum/lib>) localAddresses kieran;
|
||||||
|
in {
|
||||||
imports = [
|
imports = [
|
||||||
<modules/constants.nix>
|
|
||||||
{
|
|
||||||
services.dbus.packages = [ pkgs.gnome3.dconf ];
|
|
||||||
}
|
|
||||||
<home-manager/nixos>
|
<home-manager/nixos>
|
||||||
# <configs/mopidy.nix>
|
<niveum/modules/system-dependent.nix>
|
||||||
<configs/bash.nix>
|
|
||||||
<configs/bluetooth.nix>
|
|
||||||
<configs/chromium.nix>
|
|
||||||
<configs/cloud.nix>
|
|
||||||
<configs/compton.nix>
|
|
||||||
<configs/default.nix>
|
|
||||||
# <configs/home-assistant.nix>
|
|
||||||
<configs/distrobump.nix>
|
|
||||||
<configs/docker.nix>
|
|
||||||
<configs/dunst.nix>
|
|
||||||
<configs/fonts.nix>
|
|
||||||
<configs/git.nix>
|
|
||||||
<configs/haskell>
|
|
||||||
<configs/hledger.nix>
|
|
||||||
<configs/htop.nix>
|
|
||||||
<configs/hu-berlin.nix>
|
|
||||||
<configs/i3.nix>
|
|
||||||
<configs/kdeconnect.nix>
|
|
||||||
<configs/keybase.nix>
|
|
||||||
<configs/keyboard.nix>
|
|
||||||
<configs/mail.nix>
|
|
||||||
<configs/mpv.nix>
|
|
||||||
<configs/nano.nix>
|
|
||||||
<configs/neovim.nix>
|
|
||||||
<configs/nixpkgs-unstable.nix>
|
|
||||||
<configs/packages>
|
|
||||||
<configs/printing.nix>
|
|
||||||
<configs/python.nix>
|
|
||||||
<configs/random-background.nix>
|
|
||||||
<configs/redshift.nix>
|
|
||||||
<configs/retiolum.nix>
|
|
||||||
<configs/rofi.nix>
|
|
||||||
<configs/sncli.nix>
|
|
||||||
<configs/ssh.nix>
|
|
||||||
<configs/sudo.nix>
|
|
||||||
<configs/themes/owickstrom-dark.nix>
|
|
||||||
<configs/theming.nix>
|
|
||||||
<configs/tmux.nix>
|
|
||||||
<configs/todo-txt.nix>
|
|
||||||
<configs/traadfri.nix>
|
|
||||||
<configs/unclutter.nix>
|
|
||||||
<configs/urxvt.nix>
|
|
||||||
<configs/vscode.nix>
|
|
||||||
<configs/xautolock.nix>
|
|
||||||
<configs/xresources.nix>
|
|
||||||
<configs/zsh.nix>
|
|
||||||
{
|
{
|
||||||
niveum.user = {
|
boot.supportedFilesystems = [ "ntfs" ];
|
||||||
github = "kmein";
|
|
||||||
email = "kieran.meinhardt@gmail.com";
|
|
||||||
name = "Kierán Meinhardt";
|
|
||||||
};
|
|
||||||
|
|
||||||
niveum.applications = rec {
|
|
||||||
fileManager = "${config.niveum.applications.terminal} -e ${pkgs.ranger}/bin/ranger";
|
|
||||||
};
|
|
||||||
|
|
||||||
niveum.theme = {
|
|
||||||
gtk = { name = "Arc"; package = pkgs.arc-theme; };
|
|
||||||
icon = { name = "Arc"; package = pkgs.arc-icon-theme; };
|
|
||||||
cursor = { name = "capitaine-cursors"; package = pkgs.capitaine-cursors; };
|
|
||||||
};
|
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
nixpkgs.config = {
|
nix.nixPath = [
|
||||||
allowUnfree = true;
|
"/var/src"
|
||||||
packageOverrides = pkgs: {
|
"nixpkgs-overlays=${toString ../overlays}"
|
||||||
python3Packages = pkgs.python3Packages.override {
|
];
|
||||||
overrides = new: old: {
|
}
|
||||||
spotify-cli-linux = new.callPackage <packages/spotify-cli-linux.nix> {};
|
{ services.dbus.packages = [ pkgs.gnome3.dconf ]; }
|
||||||
instaloader = new.callPackage <packages/instaloader.nix> {};
|
{
|
||||||
sncli = new.callPackage <packages/sncli.nix> {};
|
nixpkgs = {
|
||||||
};
|
config = {
|
||||||
};
|
allowUnfree = true;
|
||||||
haskellPackages = pkgs.haskellPackages.override {
|
packageOverrides = pkgs: {
|
||||||
overrides = new: old: {
|
nur = import <nur> { inherit pkgs; };
|
||||||
blessings = new.callPackage <packages/blessings.nix> {};
|
writeDashBin = pkgs.writers.writeDashBin;
|
||||||
scanner = new.callPackage <stockholm/krebs/5pkgs/haskell/scanner.nix> {};
|
writeDash = pkgs.writers.writeDash;
|
||||||
};
|
gfs-fonts = pkgs.callPackage <niveum/packages/gfs-fonts.nix> {};
|
||||||
};
|
iolanguage = pkgs.callPackage <niveum/packages/iolanguage.nix> { };
|
||||||
git-quick-stats = pkgs.callPackage <packages/git-quick-stats.nix> {};
|
ix = pkgs.callPackage <niveum/packages/ix.nix> { };
|
||||||
writeDash = pkgs.writers.writeDash;
|
|
||||||
writeDashBin = pkgs.writers.writeDashBin;
|
|
||||||
iolanguage = pkgs.callPackage <packages/iolanguage.nix> {};
|
|
||||||
nix-git = pkgs.callPackage <packages/nix-git.nix> {};
|
|
||||||
|
|
||||||
kmein = {
|
|
||||||
autorenkalender = pkgs.callPackage <packages/autorenkalender.nix> {};
|
|
||||||
bvg = pkgs.callPackage <packages/bvg.nix> {};
|
|
||||||
daybook = pkgs.callPackage <packages/daybook.nix> {};
|
|
||||||
font-size = pkgs.callPackage <packages/font-size.nix> { font = config.niveum.fonts.terminal; };
|
|
||||||
genius = pkgs.callPackage <packages/genius.nix> {};
|
|
||||||
instaget = pkgs.callPackage <packages/instaget.nix> {};
|
|
||||||
literature-quote = pkgs.callPackage <packages/literature-quote.nix> {};
|
|
||||||
n = pkgs.callPackage <packages/n.nix> {};
|
|
||||||
depp = pkgs.callPackage <packages/depp.nix> {};
|
|
||||||
odyssey = pkgs.callPackage <packages/odyssey.nix> {};
|
|
||||||
wttr = pkgs.callPackage <packages/wttr.nix> {};
|
|
||||||
nav = pkgs.callPackage <packages/nav.nix> {};
|
|
||||||
slide =
|
|
||||||
let slide-package = pkgs.fetchFromGitHub {
|
|
||||||
owner = "kmein";
|
|
||||||
repo = "slide";
|
|
||||||
rev = "0470583d22212745eab4f46076267addf4d2346c";
|
|
||||||
sha256 = "0skcp3va9v4hmxy5ramghpz53gnyxv10wsacgmc2jr0v1wrqlzbh";
|
|
||||||
};
|
|
||||||
in pkgs.callPackage slide-package {};
|
|
||||||
haskellPackages.mnemosyne =
|
|
||||||
let mnemosyne-package = pkgs.fetchFromGitHub {
|
|
||||||
repo = "mnemosyne";
|
|
||||||
owner = "kmein";
|
|
||||||
rev = "6bfa13c88db176af80be90840ff03573d67d679f";
|
|
||||||
sha256 = "1rimv5c5q9602y501hbkgkfbimqnmdkcr5hp1434q06gcazhjhca";
|
|
||||||
};
|
|
||||||
in pkgs.haskellPackages.callPackage mnemosyne-package {};
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
overlays = [
|
||||||
|
(import <stockholm/krebs/5pkgs>)
|
||||||
|
(self: super: {
|
||||||
|
scripts = import <niveum/packages/scripts> { pkgs = super; lib = super.lib; };
|
||||||
|
})
|
||||||
|
];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
boot.cleanTmpDir = true;
|
boot.cleanTmpDir = true;
|
||||||
boot.loader.timeout = 1;
|
boot.loader.timeout = 1;
|
||||||
boot.extraModulePackages = [ config.boot.kernelPackages.exfat-nofuse ];
|
|
||||||
}
|
|
||||||
{
|
|
||||||
time.timeZone = "Europe/Berlin";
|
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
home-manager.users.me = {
|
home-manager.users.me = {
|
||||||
programs.zathura = {
|
programs.zathura = {
|
||||||
enable = true;
|
enable = true;
|
||||||
options.selection-clipboard = "clipboard";
|
options = {
|
||||||
|
selection-clipboard = "clipboard";
|
||||||
|
# first-page-column = "1:1"; # makes side-by-side mode start on the left side
|
||||||
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
users.mutableUsers = false;
|
users.mutableUsers = false;
|
||||||
|
|
||||||
|
users.defaultUserShell = pkgs.zsh;
|
||||||
|
|
||||||
users.users.me = {
|
users.users.me = {
|
||||||
name = "kfm";
|
name = "kfm";
|
||||||
description = config.niveum.user.name;
|
description = kieran.name;
|
||||||
home = "/home/kfm";
|
hashedPassword =
|
||||||
createHome = true;
|
"$6$w9hXyGFl/.IZBXk$5OiWzS1G.5hImhh1YQmZiCXYNAJhi3X6Y3uSLupJNYYXPLMsQpx2fwF4Xr2uYzGMV8Foqh8TgUavx1APD9rcb/";
|
||||||
group = "users";
|
isNormalUser = true;
|
||||||
hashedPassword = "$6$w9hXyGFl/.IZBXk$5OiWzS1G.5hImhh1YQmZiCXYNAJhi3X6Y3uSLupJNYYXPLMsQpx2fwF4Xr2uYzGMV8Foqh8TgUavx1APD9rcb/";
|
uid = 1000;
|
||||||
shell = pkgs.zsh;
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
home-manager.users.me.xdg.enable = true;
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
sound.enable = true;
|
sound.enable = true;
|
||||||
|
|
||||||
hardware.pulseaudio = {
|
hardware.pulseaudio = {
|
||||||
enable = true;
|
enable = true;
|
||||||
package = pkgs.pulseaudioFull; # for bluetooth sound output
|
package = pkgs.pulseaudioFull;
|
||||||
|
extraModules = [ pkgs.pulseaudio-modules-bt ];
|
||||||
|
# copy server:/run/pulse/.config/pulse/cookie to client:~/.config/pulse/cookie to authenticate a client machine
|
||||||
|
zeroconf.discovery.enable = true;
|
||||||
|
extraConfig = ''
|
||||||
|
load-module ${toString [
|
||||||
|
"module-tunnel-sink-new"
|
||||||
|
"server=zaatar.r"
|
||||||
|
"sink_name=zaatar"
|
||||||
|
"channels=2"
|
||||||
|
"rate=44100"
|
||||||
|
]}
|
||||||
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
users.users.me.extraGroups = [ "audio" ];
|
users.users.me.extraGroups = [ "audio" ];
|
||||||
|
|
||||||
environment.systemPackages = [ pkgs.pavucontrol pkgs.pamixer ];
|
environment.systemPackages = [ pkgs.pavucontrol pkgs.ncpamixer pkgs.pamixer pkgs.pulsemixer ];
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
environment.systemPackages = [
|
environment.interactiveShellInit =
|
||||||
(pkgs.writers.writeDashBin "niveum-deploy" ''
|
"export PATH=$PATH:$HOME/projects/niveum";
|
||||||
NIVEUM_DIR=/home/kfm/prog/git/niveum
|
environment.shellAliases = let
|
||||||
|
wcd = pkgs.writers.writeDash "wcd" ''
|
||||||
[ $# -eq 1 ] || echo >&2 "Usage: niveum-deploy SYSTEM"
|
cd "$(readlink "$(${pkgs.which}/bin/which --skip-alias "$1")" | xargs dirname)/.."
|
||||||
|
'';
|
||||||
eval $(nix-build --no-out-link "$NIVEUM_DIR/deploy.nix" -A "$1")
|
where = pkgs.writers.writeDash "where" ''
|
||||||
'')
|
readlink "$(${pkgs.which}/bin/which --skip-alias "$1")" | xargs dirname
|
||||||
(pkgs.writers.writeDashBin "niveum-update" ''
|
'';
|
||||||
NIVEUM_DIR=/home/kfm/prog/git/niveum
|
take = pkgs.writers.writeDash "take" ''
|
||||||
|
mkdir "$1" && cd "$1"
|
||||||
nix-prefetch-git --url https://github.com/NixOS/nixpkgs-channels --rev refs/heads/nixos-${config.system.stateVersion} > "$NIVEUM_DIR/nixpkgs.json"
|
'';
|
||||||
'')
|
swallow = command: "${pkgs.scripts.swallow}/bin/swallow ${command}";
|
||||||
];
|
in {
|
||||||
}
|
"ß" = "${pkgs.utillinux}/bin/setsid";
|
||||||
{
|
cat = "${pkgs.bat}/bin/bat --style=plain";
|
||||||
environment.interactiveShellInit = "export PATH=$PATH:$HOME/.cargo/bin";
|
chromium-incognito =
|
||||||
environment.shellAliases = {
|
"chromium --user-data-dir=$(mktemp -d /tmp/chr.XXXXXX) --no-first-run --incognito";
|
||||||
clipboard = "${pkgs.xclip}/bin/xclip -se c";
|
cp = "cp --interactive";
|
||||||
o = "${pkgs.xdg_utils}/bin/xdg-open";
|
|
||||||
tmux = "${pkgs.tmux}/bin/tmux -2";
|
|
||||||
ip = "${pkgs.iproute}/bin/ip -c";
|
ip = "${pkgs.iproute}/bin/ip -c";
|
||||||
|
l = "ls --color=auto --time-style=long-iso --almost-all";
|
||||||
|
ls = "ls --color=auto --time-style=long-iso";
|
||||||
|
ll = "ls --color=auto --time-style=long-iso -l";
|
||||||
|
la = "ls --color=auto --time-style=long-iso --almost-all -l";
|
||||||
|
mv = "mv --interactive";
|
||||||
|
nixi = "nix repl '<nixpkgs>'";
|
||||||
ns = "nix-shell --run zsh";
|
ns = "nix-shell --run zsh";
|
||||||
nixi = ''nix repl "<nixpkgs>"'';
|
o = "${pkgs.xdg_utils}/bin/xdg-open";
|
||||||
rm = "rm -i";
|
pbcopy = "${pkgs.xclip}/bin/xclip -selection clipboard -in";
|
||||||
cp = "cp -i";
|
pbpaste = "${pkgs.xclip}/bin/xclip -selection clipboard -out";
|
||||||
mv = "mv -i";
|
rm = "rm --interactive";
|
||||||
l = "${pkgs.exa}/bin/exa -a";
|
s = "${pkgs.systemd}/bin/systemctl";
|
||||||
ls = "${pkgs.exa}/bin/exa";
|
take = "source ${take}";
|
||||||
ll = "${pkgs.exa}/bin/exa -l";
|
tmux = "${pkgs.tmux}/bin/tmux -2";
|
||||||
la = "${pkgs.exa}/bin/exa -la";
|
sxiv = swallow "${pkgs.sxiv}/bin/sxiv";
|
||||||
dig = "dig +short";
|
zathura = swallow "${pkgs.zathura}/bin/zathura";
|
||||||
|
us = "${pkgs.systemd}/bin/systemctl --user";
|
||||||
|
wcd = "source ${wcd}";
|
||||||
|
im = "${pkgs.openssh}/bin/ssh weechat@makanek -t tmux attach-session -t IM";
|
||||||
|
where = "source ${where}";
|
||||||
|
yt =
|
||||||
|
"${pkgs.youtube-dl}/bin/youtube-dl --add-metadata -ic"; # Download video link
|
||||||
|
yta =
|
||||||
|
"${pkgs.youtube-dl}/bin/youtube-dl --add-metadata -xic"; # Download with audio
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
{
|
{ i18n.defaultLocale = "en_GB.UTF-8"; }
|
||||||
networking.wireless = {
|
{ services.illum.enable = true; }
|
||||||
enable = true;
|
|
||||||
userControlled.enable = true;
|
|
||||||
networks = {
|
|
||||||
"Aether".pskRaw = "e1b18af54036c5c9a747fe681c6a694636d60a5f8450f7dec0d76bc93e2ec85a";
|
|
||||||
"Asoziales Netzwerk".pskRaw = "8e234041ec5f0cd1b6a14e9adeee9840ed51b2f18856a52137485523e46b0cb6";
|
|
||||||
"EasyBox-927376".pskRaw = "dbd490ab69b39bd67cfa06daf70fc3ef3ee90f482972a668ed758f90f5577c22";
|
|
||||||
"FlixBus Wi-Fi" = {};
|
|
||||||
"FlixBus" = {};
|
|
||||||
"FlixTrain" = {};
|
|
||||||
"Libertarian WiFi".pskRaw = "e9beaae6ffa55d10e80b8a2e7d997411d676a3cc6f1f29d0b080391f04555050";
|
|
||||||
"Ni/Schukajlow".pskRaw = "ffc47f6829da59c48aea878a32252223303f5c47a3859edc90971ffc63346781";
|
|
||||||
"WIFIonICE" = {};
|
|
||||||
"WLAN-914742".psk = "67647139648174545446";
|
|
||||||
"WLAN-XVMU6T".pskRaw = "46ea807283255a3d7029233bd79c18837df582666c007c86a8d591f65fae17cc";
|
|
||||||
"c-base-public" = {};
|
|
||||||
"discord".psk = "baraustrinken";
|
|
||||||
"security-by-obscurity".psk = "44629828256481964386";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
environment.systemPackages = [ pkgs.wpa_supplicant_gui ];
|
|
||||||
}
|
|
||||||
{
|
|
||||||
networking.hosts = {
|
|
||||||
"192.168.178.1" = [ "fritz.box" ];
|
|
||||||
"192.168.178.21" = [ "scardanelli" ];
|
|
||||||
"192.168.178.22" = [ "homeros" ];
|
|
||||||
"192.168.178.24" = [ "catullus" ];
|
|
||||||
};
|
|
||||||
}
|
|
||||||
{
|
|
||||||
i18n.defaultLocale = "en_GB.UTF-8";
|
|
||||||
}
|
|
||||||
{
|
|
||||||
services.illum.enable = true;
|
|
||||||
}
|
|
||||||
{
|
{
|
||||||
services.xserver = {
|
services.xserver = {
|
||||||
enable = true;
|
enable = true;
|
||||||
displayManager.lightdm = {
|
displayManager = {
|
||||||
enable = true;
|
autoLogin = {
|
||||||
autoLogin.enable = true;
|
|
||||||
autoLogin.user = config.users.users.me.name;
|
|
||||||
greeters.gtk = {
|
|
||||||
enable = true;
|
enable = true;
|
||||||
indicators = [ "~spacer" "~host" "~spacer" "~session" "~power" ];
|
user = config.users.users.me.name;
|
||||||
|
};
|
||||||
|
lightdm = {
|
||||||
|
enable = true;
|
||||||
|
greeters.gtk = {
|
||||||
|
enable = true;
|
||||||
|
indicators = [ "~spacer" "~host" "~spacer" "~session" "~power" ];
|
||||||
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
desktopManager.default = "none";
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
@@ -261,14 +165,86 @@
|
|||||||
pumount.source = "${pkgs.pmount}/bin/pumount";
|
pumount.source = "${pkgs.pmount}/bin/pumount";
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
{ programs.command-not-found.enable = true; }
|
||||||
{
|
{
|
||||||
programs.command-not-found.enable = true;
|
programs.gnupg.agent.enable = true;
|
||||||
|
|
||||||
|
environment.systemPackages = [
|
||||||
|
pkgs.gnupg
|
||||||
|
(pkgs.pass.withExtensions (e: [e.pass-otp]))
|
||||||
|
];
|
||||||
}
|
}
|
||||||
{
|
{
|
||||||
programs.java = {
|
services.atd.enable = true;
|
||||||
enable = true;
|
}
|
||||||
package = pkgs.openjdk;
|
{
|
||||||
|
services.getty = {
|
||||||
|
greetingLine = lib.mkForce "";
|
||||||
|
helpLine = lib.mkForce "";
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
{
|
||||||
|
networking.hosts = lib.mapAttrs' (name: address: {
|
||||||
|
name = address;
|
||||||
|
value = [ "${name}.local" ];
|
||||||
|
}) localAddresses;
|
||||||
|
}
|
||||||
|
./alacritty.nix
|
||||||
|
./bash.nix
|
||||||
|
./beets.nix
|
||||||
|
./bluetooth.nix
|
||||||
|
./ccc.nix
|
||||||
|
# ./kleiter.nix
|
||||||
|
./khal.nix
|
||||||
|
./engiadina.nix
|
||||||
|
./chromium.nix
|
||||||
|
./cloud.nix
|
||||||
|
./compton.nix
|
||||||
|
./direnv.nix
|
||||||
|
./distrobump.nix
|
||||||
|
./docker.nix
|
||||||
|
./dunst.nix
|
||||||
|
./flix.nix
|
||||||
|
./fonts.nix
|
||||||
|
./fzf.nix
|
||||||
|
./gaslight.nix
|
||||||
|
./git.nix
|
||||||
|
./hledger.nix
|
||||||
|
./htop.nix
|
||||||
|
./hu-berlin.nix
|
||||||
|
./i3.nix
|
||||||
|
./keyboard.nix
|
||||||
|
./lb.nix
|
||||||
|
./mpv.nix
|
||||||
|
./mime.nix
|
||||||
|
./nano.nix
|
||||||
|
./neovim.nix
|
||||||
|
./neomutt.nix
|
||||||
|
./nix.nix
|
||||||
|
./newsboat.nix
|
||||||
|
./flameshot-once.nix
|
||||||
|
./packages
|
||||||
|
./power-action.nix
|
||||||
|
./printing.nix
|
||||||
|
./openweathermap.nix
|
||||||
|
./wallpaper.nix
|
||||||
|
./redshift.nix
|
||||||
|
./retiolum.nix
|
||||||
|
./rofi.nix
|
||||||
|
./spacetime.nix
|
||||||
|
./seafile.nix
|
||||||
|
./ssh.nix
|
||||||
|
./sshd.nix
|
||||||
|
./sudo.nix
|
||||||
|
./sxiv.nix
|
||||||
|
./theming.nix
|
||||||
|
./tmux.nix
|
||||||
|
# ./tor.nix
|
||||||
|
./traadfri.nix
|
||||||
|
./unclutter.nix
|
||||||
|
./version.nix
|
||||||
|
./vscode.nix
|
||||||
|
./watson.nix
|
||||||
|
./zsh.nix
|
||||||
];
|
];
|
||||||
}
|
}
|
||||||
|
|||||||
38
configs/direnv.nix
Normal file
@@ -0,0 +1,38 @@
|
|||||||
|
{ pkgs, ... }:
|
||||||
|
let
|
||||||
|
nixify = pkgs.writers.writeDashBin "nixify" ''
|
||||||
|
set -efuC
|
||||||
|
|
||||||
|
if [ ! -e ./.envrc ]; then
|
||||||
|
echo use_nix > .envrc
|
||||||
|
direnv allow
|
||||||
|
fi
|
||||||
|
if [ ! -e shell.nix ]; then
|
||||||
|
cat > shell.nix <<'EOF'
|
||||||
|
{ pkgs ? import <nixpkgs> {} }:
|
||||||
|
pkgs.mkShell {
|
||||||
|
buildInputs = [];
|
||||||
|
}
|
||||||
|
EOF
|
||||||
|
''${EDITOR:-vim} shell.nix
|
||||||
|
fi
|
||||||
|
'';
|
||||||
|
in {
|
||||||
|
environment.systemPackages = [ pkgs.direnv nixify ];
|
||||||
|
|
||||||
|
home-manager.users.me.programs.direnv = {
|
||||||
|
enable = true;
|
||||||
|
stdlib = builtins.readFile ("${
|
||||||
|
pkgs.fetchFromGitHub {
|
||||||
|
owner = "Mic92";
|
||||||
|
repo = "dotfiles";
|
||||||
|
rev = "a0a9b7e358fa70a85cd468f8ca1fbb02ae0a91df";
|
||||||
|
sha256 = "1y9h5s1lf59sczsm0ksq2x1yhl98ba9lwk5yil3q53rg7n4574pg";
|
||||||
|
}
|
||||||
|
}/home/.direnvrc");
|
||||||
|
};
|
||||||
|
|
||||||
|
programs.zsh.interactiveShellInit = ''
|
||||||
|
eval "$(${pkgs.direnv}/bin/direnv hook zsh)"
|
||||||
|
'';
|
||||||
|
}
|
||||||
@@ -1,13 +1,10 @@
|
|||||||
{ lib, config, pkgs, ... }:
|
{ lib, config, pkgs, ... }: {
|
||||||
{
|
|
||||||
imports = [
|
imports = [
|
||||||
(import <stockholm/makefu/3modules/bump-distrowatch.nix> {
|
(import <stockholm/makefu/3modules/bump-distrowatch.nix> {
|
||||||
inherit lib config;
|
inherit lib config;
|
||||||
pkgs = pkgs // {
|
pkgs = pkgs // { writeDash = pkgs.writers.writeDash; };
|
||||||
writeDash = pkgs.writers.writeDash;
|
|
||||||
};
|
|
||||||
})
|
})
|
||||||
];
|
];
|
||||||
|
|
||||||
makefu.distrobump.enable = true;
|
makefu.distrobump.enable = false;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,6 +1,12 @@
|
|||||||
{ pkgs, ... }:
|
{ lib, pkgs, ... }: {
|
||||||
{
|
virtualisation.docker = {
|
||||||
virtualisation.docker.enable = true;
|
enable = true;
|
||||||
|
# for ICE wifi, ref https://gist.github.com/sunsided/7840e89ff4e11b64a2d7503fafa0290c
|
||||||
|
extraOptions = lib.concatStringsSep " " [
|
||||||
|
"--bip=172.39.1.5/24"
|
||||||
|
"--fixed-cidr=172.39.1.0/25"
|
||||||
|
];
|
||||||
|
};
|
||||||
users.users.me.extraGroups = [ "docker" ];
|
users.users.me.extraGroups = [ "docker" ];
|
||||||
environment.systemPackages = [ pkgs.docker pkgs.docker_compose ];
|
environment.systemPackages = [ pkgs.docker pkgs.docker_compose ];
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,12 +1,14 @@
|
|||||||
{ config, pkgs, ... }:
|
{ config, pkgs, ... }:
|
||||||
with config.niveum; {
|
let
|
||||||
|
inherit (import <niveum/lib>) defaultApplications colours theme;
|
||||||
|
in {
|
||||||
home-manager.users.me.services.dunst = {
|
home-manager.users.me.services.dunst = {
|
||||||
enable = true;
|
enable = true;
|
||||||
iconTheme = theme.icon;
|
iconTheme = (theme pkgs).icon;
|
||||||
settings = {
|
settings = {
|
||||||
global = {
|
global = {
|
||||||
transparency = 10;
|
transparency = 10;
|
||||||
font = "${fonts.terminal.name} ${toString fonts.terminal.size}";
|
font = "Monospace 8";
|
||||||
geometry = "200x5-30+20";
|
geometry = "200x5-30+20";
|
||||||
frame_color = colours.foreground;
|
frame_color = colours.foreground;
|
||||||
follow = "mouse";
|
follow = "mouse";
|
||||||
@@ -18,7 +20,7 @@ with config.niveum; {
|
|||||||
separator_color = "auto";
|
separator_color = "auto";
|
||||||
sort = true;
|
sort = true;
|
||||||
markup = "full";
|
markup = "full";
|
||||||
format = ''%a\n<b>%s</b>\n%b'';
|
format = "%a\\n<b>%s</b>\\n%b";
|
||||||
alignment = "left";
|
alignment = "left";
|
||||||
show_age_threshold = 60;
|
show_age_threshold = 60;
|
||||||
bounce_freq = 0;
|
bounce_freq = 0;
|
||||||
@@ -31,7 +33,7 @@ with config.niveum; {
|
|||||||
sticky_history = true;
|
sticky_history = true;
|
||||||
history_length = 20;
|
history_length = 20;
|
||||||
dmenu = "${pkgs.rofi}/bin/rofi -display-run dunst -show run";
|
dmenu = "${pkgs.rofi}/bin/rofi -display-run dunst -show run";
|
||||||
browser = applications.browser;
|
browser = (defaultApplications pkgs).browser;
|
||||||
verbosity = "mesg";
|
verbosity = "mesg";
|
||||||
corner_radius = 0;
|
corner_radius = 0;
|
||||||
mouse_left_click = "do_action";
|
mouse_left_click = "do_action";
|
||||||
|
|||||||
30
configs/engiadina.nix
Normal file
@@ -0,0 +1,30 @@
|
|||||||
|
{ config, pkgs, ... }:
|
||||||
|
let
|
||||||
|
inherit (import <niveum/lib>) tmpfilesConfig;
|
||||||
|
cdnRoot = "/var/lib/engiadina";
|
||||||
|
in
|
||||||
|
{
|
||||||
|
imports = [ <stockholm/krebs/3modules/permown.nix> ];
|
||||||
|
|
||||||
|
krebs.permown.${cdnRoot} = {
|
||||||
|
owner = config.users.users.me.name;
|
||||||
|
group = "users";
|
||||||
|
umask = "0002";
|
||||||
|
};
|
||||||
|
|
||||||
|
services.nginx = {
|
||||||
|
enable = true;
|
||||||
|
virtualHosts.default = {
|
||||||
|
root = cdnRoot;
|
||||||
|
listen = [{
|
||||||
|
addr = "0.0.0.0";
|
||||||
|
port = 3333;
|
||||||
|
}];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
environment.shellAliases = {
|
||||||
|
engiadina-watch = "${pkgs.findutils}/bin/find extra-src src | ${pkgs.entr}/bin/entr -s 'build-component && ${pkgs.rsync}/bin/rsync -avu dist/*.js ${cdnRoot}/'";
|
||||||
|
engiadina-edit = "$EDITOR ${cdnRoot}/index.html";
|
||||||
|
};
|
||||||
|
}
|
||||||
26
configs/flameshot-once.nix
Normal file
@@ -0,0 +1,26 @@
|
|||||||
|
{ config, lib, pkgs, ... }:
|
||||||
|
{
|
||||||
|
home-manager.users.me = {
|
||||||
|
services.flameshot.enable = true;
|
||||||
|
|
||||||
|
xdg.configFile."flameshot/flameshot.ini".source = (pkgs.formats.ini {}).generate "flameshot.ini" {
|
||||||
|
General = {
|
||||||
|
disabledTrayIcon = true;
|
||||||
|
checkForUpdates = false;
|
||||||
|
contrastOpacity = 188;
|
||||||
|
savePath = "/tmp";
|
||||||
|
savePathFixed = true;
|
||||||
|
drawThickness = 0;
|
||||||
|
showStartupLaunchMessage = false;
|
||||||
|
filenamePattern = "shot_%F_%T";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
systemd.user.services.flameshot.Unit.Requires = lib.mkForce [];
|
||||||
|
systemd.user.services.flameshot.Environment = {
|
||||||
|
# IMGUR_CREATE_URL = "https://p.krebsco.de/image";
|
||||||
|
# IMGUR_DELETE_URL = "https://p.krebsco.de/image/delete/%1";
|
||||||
|
PATH = "${config.home-manager.users.me.home.profileDirectory}/bin";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
79
configs/flix.nix
Normal file
@@ -0,0 +1,79 @@
|
|||||||
|
{ config, pkgs, ... }:
|
||||||
|
let
|
||||||
|
flixLocation = "/media/flix";
|
||||||
|
cacheLocation = "/var/cache/flix";
|
||||||
|
indexFilename = "index";
|
||||||
|
flixUser = "flix";
|
||||||
|
flixGroup = "users";
|
||||||
|
inherit (import <niveum/lib>) tmpfilesConfig;
|
||||||
|
in {
|
||||||
|
fileSystems.${flixLocation} = {
|
||||||
|
device = "prism.r:/export";
|
||||||
|
fsType = "nfs";
|
||||||
|
options = [
|
||||||
|
"noauto"
|
||||||
|
"noatime"
|
||||||
|
"nodiratime"
|
||||||
|
"x-systemd.automount"
|
||||||
|
"x-systemd.device-timeout=1"
|
||||||
|
"x-systemd.idle-timeout=1min"
|
||||||
|
"x-systemd.requires=tinc.retiolum.service"
|
||||||
|
"x-systemd.requires=wpa_supplicant.service"
|
||||||
|
"user"
|
||||||
|
"_netdev"
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
|
systemd.tmpfiles.rules = [
|
||||||
|
(tmpfilesConfig {
|
||||||
|
type = "d";
|
||||||
|
path = cacheLocation;
|
||||||
|
mode = "0750";
|
||||||
|
user = flixUser;
|
||||||
|
group = flixGroup;
|
||||||
|
})
|
||||||
|
];
|
||||||
|
|
||||||
|
systemd.services.flix-index = {
|
||||||
|
description = "Flix indexing service";
|
||||||
|
wants = [ "network-online.target" ];
|
||||||
|
script = "cp ${flixLocation}/download/index ./${indexFilename}";
|
||||||
|
startAt = "hourly";
|
||||||
|
serviceConfig = {
|
||||||
|
Type = "oneshot";
|
||||||
|
User = flixUser;
|
||||||
|
Group = flixGroup;
|
||||||
|
WorkingDirectory = cacheLocation;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
users.extraUsers.${flixUser} = {
|
||||||
|
isSystemUser = true;
|
||||||
|
createHome = true;
|
||||||
|
home = cacheLocation;
|
||||||
|
extraGroups = [ flixGroup ];
|
||||||
|
};
|
||||||
|
|
||||||
|
environment.systemPackages = [
|
||||||
|
(pkgs.writers.writeDashBin "mpv-simpsons" ''
|
||||||
|
set -efu
|
||||||
|
cd "${flixLocation}/download"
|
||||||
|
[ -f "${cacheLocation}/${indexFilename}" ] || exit 1
|
||||||
|
|
||||||
|
cat "${cacheLocation}/${indexFilename}" \
|
||||||
|
| ${pkgs.gnugrep}/bin/grep -i 'simpsons.*mkv' \
|
||||||
|
| shuf \
|
||||||
|
| ${pkgs.findutils}/bin/xargs -d '\n' ${pkgs.mpv}/bin/mpv
|
||||||
|
'')
|
||||||
|
(pkgs.writers.writeDashBin "flixmenu" ''
|
||||||
|
set -efu
|
||||||
|
cd "${flixLocation}/download"
|
||||||
|
|
||||||
|
[ -f "${cacheLocation}/${indexFilename}" ] || exit 1
|
||||||
|
|
||||||
|
${pkgs.dmenu}/bin/dmenu -i -p flix -l 5 "$@" < ${cacheLocation}/${indexFilename} \
|
||||||
|
| ${pkgs.findutils}/bin/xargs -I '{}' ${pkgs.utillinux}/bin/setsid ${pkgs.xdg_utils}/bin/xdg-open '{}'
|
||||||
|
'')
|
||||||
|
];
|
||||||
|
|
||||||
|
}
|
||||||
@@ -1,19 +1,41 @@
|
|||||||
{ pkgs, ... }:
|
{ pkgs, ... }: {
|
||||||
{
|
nixpkgs.config.joypixels.acceptLicense = true;
|
||||||
niveum.fonts = {
|
|
||||||
ui = {
|
|
||||||
name = "Sans";
|
|
||||||
size = 9;
|
|
||||||
};
|
|
||||||
terminal = {
|
|
||||||
name = "Monospace";
|
|
||||||
size = 9;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
fonts = {
|
fonts = {
|
||||||
enableDefaultFonts = true;
|
enableDefaultFonts = true;
|
||||||
enableFontDir = true;
|
fontDir.enable = true;
|
||||||
fonts = with pkgs; [ corefonts eb-garamond fira libertine lmodern noto-fonts roboto ubuntu_font_family ];
|
fonts = with pkgs; [
|
||||||
|
alegreya
|
||||||
|
alegreya-sans
|
||||||
|
corefonts
|
||||||
|
eb-garamond
|
||||||
|
fira
|
||||||
|
font-awesome-ttf
|
||||||
|
ibm-plex
|
||||||
|
inconsolata
|
||||||
|
iosevka
|
||||||
|
libertine
|
||||||
|
lmodern
|
||||||
|
noto-fonts
|
||||||
|
noto-fonts-cjk
|
||||||
|
noto-fonts-emoji
|
||||||
|
roboto
|
||||||
|
roboto-mono
|
||||||
|
roboto-slab
|
||||||
|
source-code-pro
|
||||||
|
source-serif-pro
|
||||||
|
source-sans-pro
|
||||||
|
ubuntu_font_family
|
||||||
|
gfs-fonts
|
||||||
|
jetbrains-mono
|
||||||
|
twemoji-color-font
|
||||||
|
joypixels
|
||||||
|
];
|
||||||
|
fontconfig.defaultFonts = {
|
||||||
|
monospace = [ "JetBrains Mono" "JoyPixels" ];
|
||||||
|
serif = [ "Roboto Slab" ];
|
||||||
|
sansSerif = [ "Roboto" "Noto Sans" ];
|
||||||
|
emoji = [ "JoyPixels" ];
|
||||||
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
32
configs/fzf.nix
Normal file
@@ -0,0 +1,32 @@
|
|||||||
|
{ pkgs, lib, ... }: {
|
||||||
|
environment = {
|
||||||
|
systemPackages = [ pkgs.fzf ];
|
||||||
|
variables = {
|
||||||
|
FZF_DEFAULT_OPTS =
|
||||||
|
lib.escapeShellArgs [ "--height=40%" "--layout=reverse" ];
|
||||||
|
FZF_ALT_C_COMMAND = "${pkgs.fd}/bin/fd --type d";
|
||||||
|
FZF_ALT_C_OPTS = lib.escapeShellArgs [
|
||||||
|
"--preview='${pkgs.tree}/bin/tree -L 1 \"{}\"'"
|
||||||
|
"--bind=space:toggle-preview"
|
||||||
|
"--preview-window=hidden"
|
||||||
|
];
|
||||||
|
FZF_CTRL_T_COMMAND = "${pkgs.fd}/bin/fd --type f";
|
||||||
|
FZF_CTRL_T_OPTS =
|
||||||
|
lib.escapeShellArgs [ "--preview='${pkgs.bat}/bin/bat \"{}\"'" ];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
programs.zsh.interactiveShellInit = ''
|
||||||
|
if [[ $options[zle] = on ]]; then
|
||||||
|
. ${pkgs.fzf}/share/fzf/completion.zsh
|
||||||
|
. ${pkgs.fzf}/share/fzf/key-bindings.zsh
|
||||||
|
fi
|
||||||
|
'';
|
||||||
|
|
||||||
|
programs.bash.interactiveShellInit = ''
|
||||||
|
if [[ :$SHELLOPTS: =~ :(vi|emacs): ]]; then
|
||||||
|
. ${pkgs.fzf}/share/fzf/completion.bash
|
||||||
|
. ${pkgs.fzf}/share/fzf/key-bindings.bash
|
||||||
|
fi
|
||||||
|
'';
|
||||||
|
}
|
||||||
25
configs/gaslight.nix
Normal file
@@ -0,0 +1,25 @@
|
|||||||
|
{ pkgs, ... }:
|
||||||
|
{
|
||||||
|
environment.systemPackages = [
|
||||||
|
(pkgs.writers.writeDashBin "gaslight-stream" ''
|
||||||
|
${pkgs.ffmpeg}/bin/ffmpeg -r 14 -s 640x480 -f video4linux2 -i /dev/video0 -f alsa -i default -c:v libx264 -preset ultrafast -c:a aac -f avi -
|
||||||
|
'')
|
||||||
|
(pkgs.writers.writeDashBin "gaslight-say" ''
|
||||||
|
voices="de
|
||||||
|
de+whisper"
|
||||||
|
|
||||||
|
echo "$@" | ${pkgs.espeak}/bin/espeak -v "$(echo "$voices" | ${pkgs.coreutils}/bin/shuf -n1)"
|
||||||
|
'')
|
||||||
|
(pkgs.writers.writeDashBin "gaslight-play" ''
|
||||||
|
set -o noglob
|
||||||
|
${pkgs.mpv}/bin/mpv --no-video "$1"
|
||||||
|
'')
|
||||||
|
];
|
||||||
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
|
||||||
|
ssh machine gaslight-stream | mpv -
|
||||||
|
ssh machine gaslight-say "blablabla"
|
||||||
|
|
||||||
|
*/
|
||||||
@@ -1,25 +1,64 @@
|
|||||||
{ pkgs, config, ... }:
|
{ pkgs, config, lib, ... }:
|
||||||
|
let
|
||||||
|
inherit (import <niveum/lib>) kieran ignorePaths;
|
||||||
|
in
|
||||||
{
|
{
|
||||||
environment.systemPackages = [
|
environment.systemPackages = [
|
||||||
pkgs.mr
|
pkgs.mr
|
||||||
pkgs.git
|
pkgs.git
|
||||||
|
pkgs.gitAndTools.gitflow
|
||||||
pkgs.gitAndTools.hub
|
pkgs.gitAndTools.hub
|
||||||
|
pkgs.gitAndTools.gh
|
||||||
pkgs.gitAndTools.git-extras
|
pkgs.gitAndTools.git-extras
|
||||||
|
pkgs.gitAndTools.git-trim
|
||||||
pkgs.gitstats
|
pkgs.gitstats
|
||||||
pkgs.patch
|
pkgs.patch
|
||||||
pkgs.patchutils
|
pkgs.patchutils
|
||||||
pkgs.git-quick-stats
|
|
||||||
pkgs.git-preview
|
pkgs.git-preview
|
||||||
];
|
];
|
||||||
|
|
||||||
|
environment.shellAliases = {
|
||||||
|
gf = "git-flow";
|
||||||
|
g = "git";
|
||||||
|
};
|
||||||
|
|
||||||
home-manager.users.me = {
|
home-manager.users.me = {
|
||||||
home.file.".mrconfig".text = builtins.readFile <dot/mrconfig.ini>;
|
home.file.".mrconfig".text = let
|
||||||
|
prependPath = prefix:
|
||||||
|
lib.attrsets.mapAttrs'
|
||||||
|
(path: lib.attrsets.nameValuePair "${prefix}/${path}");
|
||||||
|
git = url: { checkout = "git clone ${url}"; };
|
||||||
|
github = owner: repo: git "git@github.com:${owner}/${repo}";
|
||||||
|
keybase = owner: repo: git "keybase://private/${owner}/${repo}";
|
||||||
|
in lib.generators.toINI { } ({
|
||||||
|
DEFAULT = { git_gc = ''git gc "$@"''; };
|
||||||
|
} // prependPath "projects" {
|
||||||
|
"menstruation.rs" = github "kmein" "menstruation.rs";
|
||||||
|
brockman = github "kmein" "brockman";
|
||||||
|
challenges = github "kmein" "challenges";
|
||||||
|
conlangs = github "kmein" "conlangs";
|
||||||
|
ledger = keybase "kmein" "ledger";
|
||||||
|
mahlzeit = github "kmein" "mahlzeit";
|
||||||
|
menstruation-telegram = github "kmein" "menstruation-telegram";
|
||||||
|
meteora = github "kmein" "meteora";
|
||||||
|
modernizr = github "kmein" "modernizr";
|
||||||
|
niveum = github "kmein" "niveum";
|
||||||
|
nixpkgs = github "NixOS" "nixpkgs";
|
||||||
|
poetry = github "kmein" "poetry";
|
||||||
|
quotes = github "kmein" "quotes";
|
||||||
|
sphinx = github "kmein" "sphinx";
|
||||||
|
stockholm = git "https://cgit.krebsco.de/stockholm";
|
||||||
|
telebots = github "kmein" "telebots";
|
||||||
|
traadfri = github "kmein" "traadfri";
|
||||||
|
wissen = github "kmein" "wissen";
|
||||||
|
zen = github "kmein" "zen";
|
||||||
|
});
|
||||||
|
|
||||||
programs.git = {
|
programs.git = {
|
||||||
enable = true;
|
enable = true;
|
||||||
package = pkgs.gitAndTools.gitFull;
|
package = pkgs.gitAndTools.gitFull;
|
||||||
userName = config.niveum.user.name;
|
userName = kieran.name;
|
||||||
userEmail = config.niveum.user.email;
|
userEmail = kieran.email;
|
||||||
aliases = {
|
aliases = {
|
||||||
br = "branch";
|
br = "branch";
|
||||||
co = "checkout";
|
co = "checkout";
|
||||||
@@ -31,9 +70,34 @@
|
|||||||
diffs = "diff --staged";
|
diffs = "diff --staged";
|
||||||
last = "log -1 HEAD";
|
last = "log -1 HEAD";
|
||||||
logs = "log --pretty=oneline";
|
logs = "log --pretty=oneline";
|
||||||
graph = "log --graph --abbrev-commit --decorate --date=relative --format=format:'%C(bold blue)%h%C(reset) - %C(bold green)(%ar)%C(reset) %C(white)%s%C(reset) %C(dim white)- %an%C(reset)%C(bold yellow)%d%C(reset)' --all";
|
graph =
|
||||||
|
"log --graph --abbrev-commit --decorate --date=relative --format=format:'%C(bold blue)%h%C(reset) - %C(bold green)(%ar)%C(reset) %C(white)%s%C(reset) %C(dim white)- %an%C(reset)%C(bold yellow)%d%C(reset)' --all";
|
||||||
|
};
|
||||||
|
ignores = ignorePaths;
|
||||||
|
extraConfig = {
|
||||||
|
pull.ff = "only";
|
||||||
|
rebase.autoStash = true;
|
||||||
|
merge.autoStash = true;
|
||||||
|
core.pager =
|
||||||
|
"${pkgs.gitAndTools.diff-so-fancy}/bin/diff-so-fancy | ${pkgs.less}/bin/less --tabs=4 -RFX";
|
||||||
|
color = {
|
||||||
|
ui = true;
|
||||||
|
diff = {
|
||||||
|
meta = "11";
|
||||||
|
frag = "magenta bold";
|
||||||
|
commit = "yellow bold";
|
||||||
|
old = "red bold";
|
||||||
|
new = "green bold";
|
||||||
|
whitespace = "red reverse";
|
||||||
|
};
|
||||||
|
diff-highlight = {
|
||||||
|
oldNormal = "red bold";
|
||||||
|
oldHighlight = "red bold 52";
|
||||||
|
newNormal = "green bold";
|
||||||
|
newHighlight = "green bold 22";
|
||||||
|
};
|
||||||
|
};
|
||||||
};
|
};
|
||||||
ignores = config.niveum.ignore;
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
13
configs/gitea.nix
Normal file
@@ -0,0 +1,13 @@
|
|||||||
|
{
|
||||||
|
services.gitea = {
|
||||||
|
enable = true;
|
||||||
|
disableRegistration = true;
|
||||||
|
rootUrl = "https://code.xn--kiern-0qa.de";
|
||||||
|
appName = "code.kierán.de";
|
||||||
|
};
|
||||||
|
services.nginx.virtualHosts."code.xn--kiern-0qa.de" = {
|
||||||
|
forceSSL = true;
|
||||||
|
enableACME = true;
|
||||||
|
locations."/".extraConfig = "proxy_pass http://localhost:3000;";
|
||||||
|
};
|
||||||
|
}
|
||||||
@@ -1,5 +0,0 @@
|
|||||||
{
|
|
||||||
services.gollum = {
|
|
||||||
enable = true;
|
|
||||||
};
|
|
||||||
}
|
|
||||||
@@ -1,46 +0,0 @@
|
|||||||
{ config, pkgs, ... }:
|
|
||||||
{
|
|
||||||
home-manager.users.me.home.file = {
|
|
||||||
".ghc/ghci.conf".text = ''
|
|
||||||
:set editor vim
|
|
||||||
:def hoogle \s -> return $ ":!${pkgs.haskellPackages.hoogle}/bin/hoogle search --color -l --count=15 \"" ++ s ++ "\""
|
|
||||||
:def doc \s -> return $ ":!${pkgs.haskellPackages.hoogle}/bin/hoogle search --color -l --info \"" ++ s ++ "\""
|
|
||||||
:def pl \x -> return $ ":!${pkgs.haskellPackages.pointfree}/bin/pointfree -v \"" ++ x ++ "\""
|
|
||||||
:set prompt "\o033[1m%s\o033[1;34m λ\o033[0m "
|
|
||||||
:set -Wall
|
|
||||||
'';
|
|
||||||
# :def unpl \x -> return $ ":!${pkgs.haskellPackages.pointful}/bin/pointful \"" ++ x ++ "\""
|
|
||||||
".stack/config.yaml".text = let user = config.niveum.user; in ''
|
|
||||||
templates:
|
|
||||||
params:
|
|
||||||
author-name: ${user.name}
|
|
||||||
author-email: ${user.email}
|
|
||||||
copyright: 'Copyright: (c) 2019 ${user.name}'
|
|
||||||
github-username: ${user.github}
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
|
|
||||||
services.hoogle = {
|
|
||||||
enable = true;
|
|
||||||
packages = import ./packages.nix;
|
|
||||||
port = 8091;
|
|
||||||
};
|
|
||||||
|
|
||||||
environment.systemPackages = with pkgs; [
|
|
||||||
cabal2nix
|
|
||||||
stack2nix
|
|
||||||
cabal-install
|
|
||||||
hlint
|
|
||||||
# haskellPackages.brittany
|
|
||||||
(haskellPackages.ghcWithHoogle (import ./packages.nix))
|
|
||||||
] ++ map haskell.lib.justStaticExecutables [
|
|
||||||
haskellPackages.ghcid
|
|
||||||
haskellPackages.hakyll
|
|
||||||
# haskellPackages.hfmt
|
|
||||||
haskellPackages.hasktags
|
|
||||||
haskellPackages.hindent
|
|
||||||
haskellPackages.pointfree
|
|
||||||
# haskellPackages.pointful
|
|
||||||
haskellPackages.hpack
|
|
||||||
];
|
|
||||||
}
|
|
||||||
61
configs/hass/default.nix
Normal file
@@ -0,0 +1,61 @@
|
|||||||
|
{ config, pkgs, lib, ... }:
|
||||||
|
let
|
||||||
|
inherit (import ./lib.nix) triggers;
|
||||||
|
inherit (import <niveum/lib>) localAddresses;
|
||||||
|
in
|
||||||
|
{
|
||||||
|
imports = [
|
||||||
|
./zigbee.nix
|
||||||
|
./frontend.nix
|
||||||
|
];
|
||||||
|
|
||||||
|
services.home-assistant = {
|
||||||
|
enable = true;
|
||||||
|
configWritable = true;
|
||||||
|
lovelaceConfigWritable = true;
|
||||||
|
openFirewall = true;
|
||||||
|
config = {
|
||||||
|
homeassistant = {
|
||||||
|
name = "Toum";
|
||||||
|
latitude = config.location.latitude;
|
||||||
|
longitude = config.location.longitude;
|
||||||
|
elevation = 90; # TODO find out how high I live
|
||||||
|
unit_system = "metric";
|
||||||
|
time_zone = config.time.timeZone;
|
||||||
|
};
|
||||||
|
config = {};
|
||||||
|
discovery = {};
|
||||||
|
system_health = {};
|
||||||
|
history = {};
|
||||||
|
# tradfri.host = localAddresses.tradfri; # dont use until python3Packages.pytradfri is packaged
|
||||||
|
sun = {};
|
||||||
|
mobile_app = {};
|
||||||
|
shopping_list = {};
|
||||||
|
sensor = [
|
||||||
|
{
|
||||||
|
platform = "dwd_weather_warnings";
|
||||||
|
region_name = "Berlin";
|
||||||
|
}
|
||||||
|
];
|
||||||
|
mqtt = {
|
||||||
|
broker = "localhost";
|
||||||
|
port = 1883;
|
||||||
|
client_id = "home-assistant";
|
||||||
|
username = "albrecht";
|
||||||
|
password = lib.strings.fileContents <system-secrets/mosquitto>;
|
||||||
|
keepalive = 60;
|
||||||
|
protocol = "3.1";
|
||||||
|
|
||||||
|
discovery = true;
|
||||||
|
birth_message = {
|
||||||
|
topic = "/hass/status";
|
||||||
|
payload = "online";
|
||||||
|
};
|
||||||
|
will_message = {
|
||||||
|
topic = "/hass/status";
|
||||||
|
payload = "offline";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
37
configs/hass/frontend.nix
Normal file
@@ -0,0 +1,37 @@
|
|||||||
|
let
|
||||||
|
inherit (import ./lib.nix) triggers;
|
||||||
|
in
|
||||||
|
{
|
||||||
|
services.home-assistant.config = {
|
||||||
|
frontend = {
|
||||||
|
themes = {
|
||||||
|
day_theme = import ./themes/clear.nix;
|
||||||
|
night_theme = import ./themes/clear-dark.nix;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
automation = [
|
||||||
|
{
|
||||||
|
alias = "Night Theme";
|
||||||
|
hide_entity = true;
|
||||||
|
trigger = triggers.night;
|
||||||
|
action = [
|
||||||
|
{
|
||||||
|
service = "frontend.set_theme";
|
||||||
|
data.name = "night_theme";
|
||||||
|
}
|
||||||
|
];
|
||||||
|
}
|
||||||
|
{
|
||||||
|
alias = "Day Theme";
|
||||||
|
hide_entity = true;
|
||||||
|
trigger = triggers.day;
|
||||||
|
action = [
|
||||||
|
{
|
||||||
|
service = "frontend.set_theme";
|
||||||
|
data.name = "day_theme";
|
||||||
|
}
|
||||||
|
];
|
||||||
|
}
|
||||||
|
];
|
||||||
|
};
|
||||||
|
}
|
||||||
16
configs/hass/lib.nix
Normal file
@@ -0,0 +1,16 @@
|
|||||||
|
{
|
||||||
|
triggers = {
|
||||||
|
night = {
|
||||||
|
platform = "numeric_state";
|
||||||
|
entity_id = "sun.sun";
|
||||||
|
value_template = "{{ state.attributes.elevation }}";
|
||||||
|
below = -4.0;
|
||||||
|
};
|
||||||
|
day = {
|
||||||
|
platform = "numeric_state";
|
||||||
|
entity_id = "sun.sun";
|
||||||
|
value_template = "{{ state.attributes.elevation }}";
|
||||||
|
above = 0;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
72
configs/hass/themes/clear-dark.nix
Normal file
@@ -0,0 +1,72 @@
|
|||||||
|
rec {
|
||||||
|
# Colors
|
||||||
|
text-color = "#DADADB"; # Grey text
|
||||||
|
text-medium-light-color = "#A0A2A8"; # Medium-light grey text
|
||||||
|
text-medium-color = "#80828A"; # Medium grey text
|
||||||
|
text-dark-color = "#6A6B74"; # Dark grey text
|
||||||
|
accent-color = "#008bef"; # Blue
|
||||||
|
accent-medium-color = "#2484C9"; # Decent blue
|
||||||
|
background-color = "#3b4049"; # Dark grey background
|
||||||
|
background-color-2 = "#484E59"; # Light grey background
|
||||||
|
background-card-color = "#434952"; # Grey background
|
||||||
|
border-color = "#383C46"; # Grey border
|
||||||
|
|
||||||
|
# Header
|
||||||
|
app-header-background-color = "#363941"; # Background color
|
||||||
|
|
||||||
|
# Text
|
||||||
|
primary-color = text-color;
|
||||||
|
text-primary-color = text-color;
|
||||||
|
|
||||||
|
# Left Menu
|
||||||
|
paper-listbox-background-color = background-color; # Background
|
||||||
|
sidebar-icon-color = text-medium-color; # icons
|
||||||
|
sidebar-selected-icon-color = text-medium-light-color; # Selected row icon and background (15%)
|
||||||
|
sidebar-selected-text-color = text-color; # Selected row label
|
||||||
|
|
||||||
|
# UI
|
||||||
|
paper-card-header-color = text-color; # Title in settings
|
||||||
|
primary-background-color = background-color; # Background (also title background in left menu)
|
||||||
|
mdc-theme-primary = accent-medium-color; # Action Buttons (save, restart etc.)
|
||||||
|
card-background-color = background-card-color; # Entity Registry Background
|
||||||
|
|
||||||
|
# Card
|
||||||
|
paper-card-background-color = background-card-color; # Background
|
||||||
|
dark-primary-color = text-color;
|
||||||
|
primary-text-color = text-color;
|
||||||
|
paper-listbox-color = text-color;
|
||||||
|
light-primary-color = text-dark-color;
|
||||||
|
secondary-text-color = text-medium-color;
|
||||||
|
disabled-text-color = text-dark-color;
|
||||||
|
paper-dialog-button-color = text-color;
|
||||||
|
secondary-background-color = background-color-2; # Background more info title
|
||||||
|
|
||||||
|
# Icons
|
||||||
|
paper-item-icon-color = text-dark-color; # Off
|
||||||
|
paper-item-icon-active-color = accent-color; # On
|
||||||
|
|
||||||
|
# Switches
|
||||||
|
switch-checked-button-color = text-medium-light-color; # Knob On
|
||||||
|
switch-unchecked-button-color = text-medium-light-color; # Knob Off
|
||||||
|
switch-checked-track-color = "#009FFF"; # Background On
|
||||||
|
switch-unchecked-track-color = "#767682"; # Background Off
|
||||||
|
|
||||||
|
# Slider
|
||||||
|
paper-slider-active-color = accent-color; # Line On
|
||||||
|
paper-slider-knob-color = text-medium-light-color; # Knob On
|
||||||
|
paper-slider-container-color = text-dark-color; # Line Off
|
||||||
|
paper-slider-knob-start-color = text-medium-light-color; # Knob Off
|
||||||
|
|
||||||
|
# Badges
|
||||||
|
label-badge-text-color = text-color;
|
||||||
|
label-badge-background-color = "rgba(54, 57, 65, 0.6)";
|
||||||
|
|
||||||
|
# Shadows
|
||||||
|
ha-card-box-shadow = "inset 0px 0px 0px 1px var(--border-color)";
|
||||||
|
|
||||||
|
# HACS
|
||||||
|
hacs-badge-color = accent-color; # New Badge
|
||||||
|
hacs-status-installed = text-color; # Installed Icon
|
||||||
|
hacs-status-pending-restart = text-dark-color; # Restart Icon
|
||||||
|
hacs-status-pending-update = accent-color;
|
||||||
|
}
|
||||||
52
configs/hass/themes/clear.nix
Normal file
@@ -0,0 +1,52 @@
|
|||||||
|
rec {
|
||||||
|
text-color = "#636B75"; # Grey text
|
||||||
|
text-medium-color = "#8c96a5"; # Medium grey text
|
||||||
|
text-light-color = "#BAC0C6"; # Light grey text
|
||||||
|
accent-color = "#00a1ff"; # Blue
|
||||||
|
background-color = "#F7F8F9"; # Light grey background
|
||||||
|
background-color-2 = "#F4F5F6"; # Light grey background
|
||||||
|
background-card-color = "rgba(255,255,255,1.0)"; # White background
|
||||||
|
border-color = "#E8E8E8"; # Light grey border
|
||||||
|
|
||||||
|
# Header
|
||||||
|
primary-color = text-color; # Background
|
||||||
|
text-primary-color = "#FFF"; # Text
|
||||||
|
|
||||||
|
# Left Menu
|
||||||
|
paper-listbox-background-color = background-color; # Background
|
||||||
|
# TODO = Text and Icons
|
||||||
|
|
||||||
|
# UI
|
||||||
|
paper-card-header-color = text-color; # Title in settings
|
||||||
|
primary-background-color = background-color; # Background color (also title background in left menu)
|
||||||
|
|
||||||
|
# Card
|
||||||
|
paper-card-background-color = background-card-color; # Background
|
||||||
|
dark-primary-color = text-color;
|
||||||
|
primary-text-color = text-color;
|
||||||
|
paper-listbox-color = text-color;
|
||||||
|
light-primary-color = text-light-color;
|
||||||
|
secondary-text-color = text-medium-color;
|
||||||
|
disabled-text-color = text-light-color;
|
||||||
|
paper-dialog-button-color = text-color;
|
||||||
|
secondary-background-color = background-color-2; # Background more info title
|
||||||
|
|
||||||
|
# Icons
|
||||||
|
paper-item-icon-color = text-light-color; # Off
|
||||||
|
paper-item-icon-active-color = accent-color; # On
|
||||||
|
|
||||||
|
# Switches
|
||||||
|
switch-checked-button-color = "#FFF"; # Knob On
|
||||||
|
switch-unchecked-button-color = "#FFF"; # Knob Off
|
||||||
|
switch-checked-track-color = "#0077FF"; # Background On
|
||||||
|
switch-unchecked-track-color = disabled-text-color; # Background Off
|
||||||
|
|
||||||
|
# Slider
|
||||||
|
paper-slider-active-color = accent-color; # Line On
|
||||||
|
paper-slider-container-color = "#e5e7ea"; # Line Off
|
||||||
|
paper-slider-knob-color = text-light-color; # Knob On
|
||||||
|
paper-slider-knob-start-color = text-light-color; # Knob Off
|
||||||
|
|
||||||
|
# Shadows
|
||||||
|
ha-card-box-shadow = "inset 0px 0px 0px 1px var(--border-color)";
|
||||||
|
}
|
||||||
102
configs/hass/zigbee.nix
Normal file
@@ -0,0 +1,102 @@
|
|||||||
|
{ config, pkgs, lib, ... }:
|
||||||
|
let
|
||||||
|
inherit (import <niveum/lib>) localAddresses;
|
||||||
|
in
|
||||||
|
{
|
||||||
|
services.zigbee2mqtt = {
|
||||||
|
enable = true;
|
||||||
|
config = {
|
||||||
|
permit_join = false;
|
||||||
|
homeassistant = true;
|
||||||
|
serial = {
|
||||||
|
port = "/dev/ttyACM0";
|
||||||
|
disable_led = true;
|
||||||
|
};
|
||||||
|
mqtt = {
|
||||||
|
discovery = true;
|
||||||
|
base_topic = "zigbee";
|
||||||
|
server = "mqtt://${localAddresses.toum}";
|
||||||
|
user = "albrecht";
|
||||||
|
password = lib.strings.fileContents <system-secrets/mosquitto>;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
services.mosquitto = {
|
||||||
|
enable = true;
|
||||||
|
host = "0.0.0.0";
|
||||||
|
allowAnonymous = false;
|
||||||
|
checkPasswords = true;
|
||||||
|
users."albrecht" = {
|
||||||
|
password = lib.strings.fileContents <system-secrets/mosquitto>;
|
||||||
|
acl = [ "topic readwrite #" ];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
networking.firewall.allowedTCPPorts = [ 1883 ];
|
||||||
|
|
||||||
|
environment.systemPackages = [ pkgs.mosquitto ];
|
||||||
|
|
||||||
|
services.home-assistant = {
|
||||||
|
config = {
|
||||||
|
switch = [
|
||||||
|
{
|
||||||
|
platform = "mqtt";
|
||||||
|
name = "zigbee2mqtt_join";
|
||||||
|
state_topic = "/zigbee2mqtt/bridge/config/permit_join";
|
||||||
|
command_topic = "/zigbee2mqtt/bridge/config/permit_join";
|
||||||
|
payload_on = "true";
|
||||||
|
payload_off = "false";
|
||||||
|
}
|
||||||
|
];
|
||||||
|
timer.zigbee_permit_join = {
|
||||||
|
name = "Zigbee Time remaining";
|
||||||
|
duration = 120;
|
||||||
|
};
|
||||||
|
automation = [
|
||||||
|
# Automation to start timer when enable join is turned on
|
||||||
|
{
|
||||||
|
id = "zigbee_join_enabled";
|
||||||
|
alias = "";
|
||||||
|
hide_entity = "true";
|
||||||
|
trigger = {
|
||||||
|
platform = "state";
|
||||||
|
entity_id = "switch.zigbee2mqtt_join";
|
||||||
|
to = "on";
|
||||||
|
};
|
||||||
|
action = {
|
||||||
|
service = "timer.start";
|
||||||
|
entity_id = "timer.zigbee_permit_join";
|
||||||
|
};
|
||||||
|
}
|
||||||
|
# Automation to stop timer when switch turned off and turn off switch when timer finished
|
||||||
|
{
|
||||||
|
id = "zigbee_join_disabled";
|
||||||
|
hide_entity = "true";
|
||||||
|
trigger = [
|
||||||
|
{
|
||||||
|
platform = "event";
|
||||||
|
event_type = "timer.finished";
|
||||||
|
event_data.entity_id = "timer.zigbee_permit_join";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
platform = "state";
|
||||||
|
entity_id = "switch.zigbee2mqtt_join";
|
||||||
|
to = "off";
|
||||||
|
}
|
||||||
|
];
|
||||||
|
action = [
|
||||||
|
{
|
||||||
|
service = "timer.cancel";
|
||||||
|
data.entity_id = "timer.zigbee_permit_join";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
service = "switch.turn_off";
|
||||||
|
entity_id = "switch.zigbee2mqtt_join";
|
||||||
|
}
|
||||||
|
];
|
||||||
|
}
|
||||||
|
];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
81
configs/hedgedoc.nix
Normal file
@@ -0,0 +1,81 @@
|
|||||||
|
{ config, pkgs, ... }:
|
||||||
|
let
|
||||||
|
backupLocation = "/var/lib/codimd-backup";
|
||||||
|
stateLocation = "/var/lib/codimd/state.sqlite";
|
||||||
|
nixpkgs-unstable = import <nixpkgs-unstable> {};
|
||||||
|
domain = "pad.xn--kiern-0qa.de";
|
||||||
|
in
|
||||||
|
{
|
||||||
|
imports = [ <stockholm/krebs/3modules/permown.nix> ];
|
||||||
|
|
||||||
|
services.nginx.virtualHosts.${domain} = {
|
||||||
|
enableACME = true;
|
||||||
|
forceSSL = true;
|
||||||
|
locations."/" = {
|
||||||
|
proxyPass = "https://localhost:3091";
|
||||||
|
proxyWebsockets = true;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
security.acme.certs.${domain}.group = "hedgecert";
|
||||||
|
users.groups.hedgecert.members = [ "codimd" "nginx" ];
|
||||||
|
|
||||||
|
security.dhparams = {
|
||||||
|
enable = true;
|
||||||
|
params.hedgedoc = {};
|
||||||
|
};
|
||||||
|
|
||||||
|
services.hedgedoc = {
|
||||||
|
enable = true;
|
||||||
|
configuration = {
|
||||||
|
allowOrigin = [ domain ];
|
||||||
|
allowAnonymous = true;
|
||||||
|
allowGravatar = false;
|
||||||
|
allowFreeURL = true;
|
||||||
|
db = {
|
||||||
|
dialect = "sqlite";
|
||||||
|
storage = stateLocation;
|
||||||
|
};
|
||||||
|
port = 3091;
|
||||||
|
domain = domain;
|
||||||
|
useSSL = true;
|
||||||
|
protocolUseSSL = true;
|
||||||
|
sslCAPath = [ "/etc/ssl/certs/ca-certificates.crt" ];
|
||||||
|
sslCertPath = "/var/lib/acme/${domain}/cert.pem";
|
||||||
|
sslKeyPath = "/var/lib/acme/${domain}/key.pem";
|
||||||
|
dhParamPath = config.security.dhparams.params.hedgedoc.path;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
krebs.permown.${backupLocation} = { owner = "codimd"; group = "codimd"; umask = "0002"; };
|
||||||
|
|
||||||
|
systemd.services.hedgedoc-backup = {
|
||||||
|
description = "Hedgedoc backup service";
|
||||||
|
script = ''
|
||||||
|
${nixpkgs-unstable.sqlite}/bin/sqlite3 -json ${stateLocation} "select shortid, alias, ownerId, content from Notes" \
|
||||||
|
| ${pkgs.writers.writePython3 "hedgedoc-json-to-fs.py" {} ''
|
||||||
|
import json
|
||||||
|
import pathlib
|
||||||
|
import sys
|
||||||
|
|
||||||
|
for note in json.load(sys.stdin):
|
||||||
|
user_directory = pathlib.Path()
|
||||||
|
if note["ownerId"]:
|
||||||
|
user_directory = pathlib.Path(note["ownerId"])
|
||||||
|
user_directory.mkdir(exist_ok=True)
|
||||||
|
file_path = user_directory / (
|
||||||
|
(note["alias"] if note["alias"] else note["shortid"]) + ".md"
|
||||||
|
)
|
||||||
|
file_path.write_text(note["content"])
|
||||||
|
print(f"✔ {file_path}", file=sys.stderr)
|
||||||
|
''}
|
||||||
|
'';
|
||||||
|
startAt = "hourly";
|
||||||
|
serviceConfig = {
|
||||||
|
Type = "oneshot";
|
||||||
|
User = "codimd";
|
||||||
|
Group = "codimd";
|
||||||
|
WorkingDirectory = backupLocation;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
@@ -1,15 +1,14 @@
|
|||||||
{ config, pkgs, ... }:
|
{ config, pkgs, ... }: {
|
||||||
{
|
imports = [ <niveum/modules/hledger.nix> ];
|
||||||
imports = [ <modules/hledger.nix> ];
|
|
||||||
|
|
||||||
niveum.hledger = {
|
niveum.hledger = {
|
||||||
enable = true;
|
enable = true;
|
||||||
ledgerFile = "$HOME/prog/git/ledger/current.journal";
|
ledgerFile = "$HOME/projects/ledger/all.journal";
|
||||||
server = {
|
server = {
|
||||||
enable = false;
|
enable = false;
|
||||||
user = config.users.users.me;
|
user = config.users.users.me;
|
||||||
package = pkgs.unstable.hledger-web;
|
package = pkgs.hledger-web;
|
||||||
};
|
};
|
||||||
package = pkgs.unstable.hledger;
|
package = pkgs.hledger;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,7 +0,0 @@
|
|||||||
{
|
|
||||||
services.home-assistant = {
|
|
||||||
enable = true;
|
|
||||||
configWritable = true;
|
|
||||||
lovelaceConfigWritable = true;
|
|
||||||
};
|
|
||||||
}
|
|
||||||
@@ -2,33 +2,28 @@
|
|||||||
home-manager.users.me = {
|
home-manager.users.me = {
|
||||||
programs.htop = {
|
programs.htop = {
|
||||||
enable = true;
|
enable = true;
|
||||||
colorScheme = 0;
|
settings = {
|
||||||
accountGuestInCpuMeter = true;
|
color_scheme = 0;
|
||||||
cpuCountFromZero = false;
|
account_guest_in_cpu_meter = true;
|
||||||
delay = 15;
|
cpu_count_from_zero = false;
|
||||||
detailedCpuTime = false;
|
delay = 15;
|
||||||
headerMargin = true;
|
detailed_cpu_time = false;
|
||||||
hideKernelThreads = true;
|
header_margin = true;
|
||||||
hideThreads = false;
|
hide_kernel_threads = true;
|
||||||
hideUserlandThreads = false;
|
hide_threads = true;
|
||||||
highlightBaseName = true;
|
hide_userland_threads = true;
|
||||||
highlightMegabytes = true;
|
highlight_base_name = true;
|
||||||
highlightThreads = true;
|
highlight_megabytes = true;
|
||||||
shadowOtherUsers = true;
|
highlight_threads = true;
|
||||||
showProgramPath = false;
|
shadow_other_users = true;
|
||||||
showThreadNames = true;
|
show_program_path = false;
|
||||||
sortDescending = true;
|
show_thread_names = false;
|
||||||
sortKey = "PERCENT_CPU";
|
sort_descending = true;
|
||||||
treeView = true;
|
sort_key = "PERCENT_CPU";
|
||||||
updateProcessNames = false;
|
tree_view = true;
|
||||||
meters = {
|
update_process_names = false;
|
||||||
left = [
|
right_meters = [ "Uptime" "Tasks" "LoadAverage" "Battery" ];
|
||||||
{ kind = "LeftCPUs2"; mode = 1; }
|
left_meters = [ "LeftCPUs2" "RightCPUs2" "Memory" "Swap" ];
|
||||||
{ kind = "RightCPUs2"; mode = 1; }
|
|
||||||
{ kind = "Memory"; mode = 1; }
|
|
||||||
{ kind = "Swap"; mode = 1; }
|
|
||||||
];
|
|
||||||
right = [ "Uptime" "Tasks" "LoadAverage" "Battery" ];
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -1,43 +1,80 @@
|
|||||||
{ pkgs, lib, ... }:
|
{ config, pkgs, lib, ... }:
|
||||||
let
|
let
|
||||||
|
inherit (lib.strings) fileContents;
|
||||||
|
inherit (import <niveum/lib>) sshPort;
|
||||||
eduroam = {
|
eduroam = {
|
||||||
identity = lib.strings.removeSuffix "\n" (builtins.readFile <shared-secrets/eduroam/identity>);
|
identity = fileContents <secrets/eduroam/identity>;
|
||||||
password = lib.strings.removeSuffix "\n" (builtins.readFile <shared-secrets/eduroam/password>);
|
password = fileContents <secrets/eduroam/password>;
|
||||||
};
|
};
|
||||||
eduroamAuth = ''
|
hu-berlin-cifs-options = [
|
||||||
key_mgmt=WPA-EAP
|
"uid=${toString config.users.users.me.uid}"
|
||||||
eap=TTLS
|
"gid=${toString config.users.groups.users.gid}"
|
||||||
proto=RSN
|
"sec=ntlmv2"
|
||||||
identity="${eduroam.identity}"
|
"workgroup=german"
|
||||||
anonymous_identity="anonymous@wlan.hu-berlin.de"
|
"username=meinhaki"
|
||||||
altsubject_match="DNS:srv1-radius.cms.hu-berlin.de;DNS:srv2-radius.cms.hu-berlin.de"
|
"password=${lib.strings.fileContents <secrets/mail/meinhaki>}"
|
||||||
password="${eduroam.password}"
|
"noauto"
|
||||||
ca_cert="${pkgs.fetchurl {
|
"x-systemd.requires=openvpn-hu-berlin.service"
|
||||||
url = https://www.cms.hu-berlin.de/de/dl/netze/wlan/config/eduroam/t-telesec_globalroot_class_2.pem;
|
"x-systemd.automount"
|
||||||
sha256 = "0if8aqd06sid7a0vw009zpa087wxcgdd2x6z2zs4pis5kvyqj2dk";
|
"x-systemd.device-timeout=1"
|
||||||
}}"
|
"x-systemd.idle-timeout=1min"
|
||||||
phase2="auth=PAP"
|
];
|
||||||
'';
|
|
||||||
in {
|
in {
|
||||||
networking.wireless.networks = {
|
fileSystems."/media/hu-berlin/germpro2" = {
|
||||||
eduroam_5GHz.auth = eduroamAuth;
|
device = "//hugerm31c.user.hu-berlin.de/germpro2/ling";
|
||||||
eduroam.auth = eduroamAuth;
|
fsType = "cifs";
|
||||||
|
options = hu-berlin-cifs-options;
|
||||||
};
|
};
|
||||||
|
|
||||||
services.openvpn.servers = {
|
fileSystems."/media/hu-berlin/germhome" = {
|
||||||
hu-berlin = {
|
device = "//hugerm31c.user.hu-berlin.de/germhome/ling/meinhaki";
|
||||||
config = ''
|
fsType = "cifs";
|
||||||
config ${pkgs.fetchurl {
|
options = hu-berlin-cifs-options;
|
||||||
url = https://www.cms.hu-berlin.de/de/dl/netze/vpn/openvpn/hu-berlin.ovpn;
|
};
|
||||||
sha256 = "15b55aibik5460svjq2gwxrcyh6ay4k8savd6cd5lncgndmd8p8h";
|
|
||||||
}}
|
environment.systemPackages = [
|
||||||
# route-nopull
|
(pkgs.writers.writeDashBin "hu-ip" ''
|
||||||
# route 141.20.0.0 255.255.0.0
|
${pkgs.w3m}/bin/w3m -dump meineip.hu-berlin.de | head --lines=-4 | tail --lines=+3
|
||||||
'';
|
'')
|
||||||
authUserPass = {
|
(pkgs.writers.writePython3Bin "hu-eduroam-install"
|
||||||
username = eduroam.identity;
|
{
|
||||||
password = eduroam.password;
|
libraries = with pkgs.python3Packages; [ distro pyopenssl dbus-python ];
|
||||||
};
|
flakeIgnore = [ "E501" "E123" "W504" "E722" "F821" "E226" "E126" "E265" "W291" ];
|
||||||
|
}
|
||||||
|
(builtins.readFile (builtins.fetchurl {
|
||||||
|
url = "https://www.cms.hu-berlin.de/de/dl/netze/wlan/config/eduroam/linux-installer/eduroam-linux-hub.py";
|
||||||
|
sha256 = "19x2kvwxx13265b2hj5fjf53g0liw6dw7xf9j9cav67cswmz60kf";
|
||||||
|
}))
|
||||||
|
)
|
||||||
|
];
|
||||||
|
|
||||||
|
systemd.services.hu-vpn = {
|
||||||
|
enable = false;
|
||||||
|
wants = [ "network-online.target" ];
|
||||||
|
conflicts = [ "openvpn-hu-berlin.service" ];
|
||||||
|
script = ''
|
||||||
|
${pkgs.openfortivpn}/bin/openfortivpn -c ${pkgs.writeText "hu-berlin.config" ''
|
||||||
|
host = forti-ssl.vpn.hu-berlin.de
|
||||||
|
port = 443
|
||||||
|
trusted-cert = 42193a913d276d9eb86217612956e1e6464d6f07bed5393a4787c87adc4bd359
|
||||||
|
username = ${eduroam.identity}
|
||||||
|
password = ${eduroam.password}
|
||||||
|
''}
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
|
||||||
|
systemd.services.openvpn-hu-berlin.conflicts = [ "hu-vpn.service" ];
|
||||||
|
|
||||||
|
services.openvpn.servers.hu-berlin = {
|
||||||
|
autoStart = false;
|
||||||
|
authUserPass = {
|
||||||
|
username = eduroam.identity;
|
||||||
|
password = eduroam.password;
|
||||||
};
|
};
|
||||||
|
config = fileContents (pkgs.fetchurl {
|
||||||
|
url =
|
||||||
|
"https://www.cms.hu-berlin.de/de/dl/netze/vpn/openvpn/hu-berlin.ovpn";
|
||||||
|
sha256 = "15b55aibik5460svjq2gwxrcyh6ay4k8savd6cd5lncgndmd8p8h";
|
||||||
|
});
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
328
configs/i3.nix
@@ -1,56 +1,140 @@
|
|||||||
{ config, pkgs, lib, ... }:
|
{ config, pkgs, lib, ... }:
|
||||||
let
|
let
|
||||||
new-workspace = pkgs.unstable.writers.writeDash "new-workspace" ''
|
inherit (import <niveum/lib>) defaultApplications colours;
|
||||||
|
klem = import <niveum/packages/scripts/klem.nix> {
|
||||||
|
inherit pkgs lib;
|
||||||
|
config.scripts = {
|
||||||
|
"p.r" = pkgs.writers.writeDash "p.r" ''
|
||||||
|
${pkgs.curl}/bin/curl -fSs http://p.r --data-binary @- \
|
||||||
|
| ${pkgs.coreutils}/bin/tail --lines=1 \
|
||||||
|
| ${pkgs.gnused}/bin/sed 's/\\<r\\>/krebsco.de/'
|
||||||
|
'';
|
||||||
|
"ix.io" = pkgs.writers.writeDash "ix.io" ''
|
||||||
|
${pkgs.curl}/bin/curl -fSs -F 'f:1=<-' ix.io
|
||||||
|
'';
|
||||||
|
"go.r" = pkgs.writers.writeDash "go.r" ''
|
||||||
|
${pkgs.curl}/bin/curl -fSs http://go.r -F "uri=$(${pkgs.coreutils}/bin/cat)"
|
||||||
|
'';
|
||||||
|
"0x0.st" = pkgs.writers.writeDash "0x0.st" ''
|
||||||
|
${pkgs.curl}/bin/curl -fSs https://0x0.st -F "shorten=$(${pkgs.coreutils}/bin/cat)"
|
||||||
|
'';
|
||||||
|
"rot13" = pkgs.writers.writeDash "rot13" ''
|
||||||
|
${pkgs.coreutils}/bin/tr '[A-Za-z]' '[N-ZA-Mn-za-m]'
|
||||||
|
'';
|
||||||
|
"ipa" = pkgs.writers.writeDash "ipa" ''
|
||||||
|
${pkgs.scripts.ipa}/bin/ipa
|
||||||
|
'';
|
||||||
|
"betacode" = pkgs.writers.writeDash "betacode" ''
|
||||||
|
${pkgs.scripts.betacode}/bin/betacode
|
||||||
|
'';
|
||||||
|
"devanagari" = pkgs.writers.writeDash "devanagari" ''
|
||||||
|
${pkgs.scripts.devanagari}/bin/devanagari
|
||||||
|
'';
|
||||||
|
"curl" = pkgs.writers.writeDash "curl" ''
|
||||||
|
${pkgs.curl}/bin/curl -fSs "$(${pkgs.coreutils}/bin/cat)"
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
new-workspace = pkgs.writers.writeDash "new-workspace" ''
|
||||||
i3-msg workspace $(($(i3-msg -t get_workspaces | tr , '\n' | grep '"num":' | cut -d : -f 2 | sort -rn | head -1) + 1))
|
i3-msg workspace $(($(i3-msg -t get_workspaces | tr , '\n' | grep '"num":' | cut -d : -f 2 | sort -rn | head -1) + 1))
|
||||||
'';
|
'';
|
||||||
move-to-new-workspace = pkgs.unstable.writers.writeDash "new-workspace" ''
|
move-to-new-workspace = pkgs.writers.writeDash "new-workspace" ''
|
||||||
i3-msg move container to workspace $(($(i3-msg -t get_workspaces | tr , '\n' | grep '"num":' | cut -d : -f 2 | sort -rn | head -1) + 1))
|
i3-msg move container to workspace $(($(i3-msg -t get_workspaces | tr , '\n' | grep '"num":' | cut -d : -f 2 | sort -rn | head -1) + 1))
|
||||||
'';
|
'';
|
||||||
in with config.niveum; {
|
|
||||||
|
in {
|
||||||
services.xserver = {
|
services.xserver = {
|
||||||
windowManager.default = "i3";
|
displayManager.defaultSession = "none+i3";
|
||||||
windowManager.i3.enable = true;
|
windowManager.i3 = {
|
||||||
|
enable = true;
|
||||||
|
package = pkgs.i3-gaps;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
services.xserver = {
|
||||||
|
monitorSection = ''Option "DPMS" "false"'';
|
||||||
|
serverFlagsSection = ''
|
||||||
|
Option "BlankTime" "0"
|
||||||
|
Option "StandbyTime" "0"
|
||||||
|
Option "SuspendTime" "0"
|
||||||
|
Option "OffTime" "0"
|
||||||
|
'';
|
||||||
|
extraConfig = ''
|
||||||
|
Section "Extensions"
|
||||||
|
Option "DPMS" "Disable"
|
||||||
|
EndSection
|
||||||
|
'';
|
||||||
};
|
};
|
||||||
|
|
||||||
home-manager.users.me.xsession.windowManager.i3 = {
|
home-manager.users.me.xsession.windowManager.i3 = {
|
||||||
enable = true;
|
enable = true;
|
||||||
config = rec {
|
config = rec {
|
||||||
fonts = [ "${config.niveum.fonts.ui.name} ${toString config.niveum.fonts.ui.size}" ];
|
fonts = {names = ["Sans"]; size = 10.0;};
|
||||||
modifier = "Mod4";
|
modifier = "Mod4";
|
||||||
window = {
|
window = {
|
||||||
titlebar = false;
|
titlebar = false;
|
||||||
border = 1;
|
border = 1;
|
||||||
hideEdgeBorders = "smart";
|
hideEdgeBorders = "smart";
|
||||||
|
commands = [
|
||||||
|
{
|
||||||
|
criteria = { class = "floating"; };
|
||||||
|
command = "floating enable";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
criteria = { class = "fzfmenu"; };
|
||||||
|
command = "floating enable";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
criteria = { class = "mpv"; };
|
||||||
|
command = lib.strings.concatStringsSep ", " [
|
||||||
|
"floating enable"
|
||||||
|
"sticky enable"
|
||||||
|
"fullscreen disable"
|
||||||
|
"resize set 640 480"
|
||||||
|
"move position mouse"
|
||||||
|
];
|
||||||
|
}
|
||||||
|
];
|
||||||
};
|
};
|
||||||
|
gaps.inner = 4;
|
||||||
floating = {
|
floating = {
|
||||||
titlebar = false;
|
titlebar = false;
|
||||||
border = 1;
|
border = 1;
|
||||||
};
|
};
|
||||||
colors =
|
colors = let
|
||||||
let scheme = { background = colours.background; text = colours.foreground; };
|
scheme = {
|
||||||
in rec {
|
background = colours.background;
|
||||||
focused = scheme // {
|
text = colours.foreground;
|
||||||
border = colours.background;
|
|
||||||
indicator = colours.background;
|
|
||||||
childBorder = colours.background;
|
|
||||||
};
|
|
||||||
focusedInactive = focused;
|
|
||||||
unfocused = focused;
|
|
||||||
urgent = scheme // {
|
|
||||||
border = colours.red.bright;
|
|
||||||
indicator = colours.red.bright;
|
|
||||||
childBorder = colours.red.bright;
|
|
||||||
};
|
|
||||||
placeholder = scheme // {
|
|
||||||
border = colours.green.bright;
|
|
||||||
indicator = colours.green.bright;
|
|
||||||
childBorder = colours.green.bright;
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
|
in rec {
|
||||||
|
focused = scheme // {
|
||||||
|
border = colours.cyan.bright;
|
||||||
|
indicator = colours.cyan.bright;
|
||||||
|
childBorder = colours.cyan.bright;
|
||||||
|
};
|
||||||
|
unfocused = scheme // {
|
||||||
|
border = colours.background;
|
||||||
|
indicator = colours.background;
|
||||||
|
childBorder = colours.background;
|
||||||
|
};
|
||||||
|
focusedInactive = unfocused;
|
||||||
|
urgent = scheme // {
|
||||||
|
border = colours.red.bright;
|
||||||
|
indicator = colours.red.bright;
|
||||||
|
childBorder = colours.red.bright;
|
||||||
|
};
|
||||||
|
placeholder = scheme // {
|
||||||
|
border = colours.green.bright;
|
||||||
|
indicator = colours.green.bright;
|
||||||
|
childBorder = colours.green.bright;
|
||||||
|
};
|
||||||
|
};
|
||||||
bars = [{
|
bars = [{
|
||||||
workspaceButtons = false;
|
workspaceButtons = false;
|
||||||
fonts = [ "${config.niveum.fonts.terminal.name} ${toString config.niveum.fonts.terminal.size}" ];
|
fonts = {names = ["Sans"]; size = 8.0;};
|
||||||
mode = "hide";
|
mode = "hide"; # "dock"
|
||||||
|
position = "bottom";
|
||||||
colors = rec {
|
colors = rec {
|
||||||
background = colours.background;
|
background = colours.background;
|
||||||
separator = background;
|
separator = background;
|
||||||
@@ -61,108 +145,118 @@ in with config.niveum; {
|
|||||||
text = colours.foreground;
|
text = colours.foreground;
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
statusCommand = "${pkgs.i3status}/bin/i3status -c ${pkgs.writeText "i3status.conf" ''
|
statusCommand = "${pkgs.i3status-rust}/bin/i3status-rs ${
|
||||||
general {
|
(pkgs.formats.toml {}).generate "i3status-rust.toml" (import <niveum/lib/i3status-rust.nix> {
|
||||||
colors = true
|
inherit (config.niveum) batteryName wirelessInterface;
|
||||||
color_good = "${colours.green.dark}"
|
inherit colours;
|
||||||
color_bad = "${colours.red.dark}"
|
inherit pkgs;
|
||||||
color_degraded = "${colours.white.dark}"
|
})
|
||||||
interval = 5
|
}";
|
||||||
separator = " "
|
|
||||||
}
|
|
||||||
|
|
||||||
# order += "run_watch retiolum"
|
|
||||||
order += "path_exists openvpn"
|
|
||||||
order += "wireless ${networkInterfaces.wireless}"
|
|
||||||
order += "battery all"
|
|
||||||
order += "volume master"
|
|
||||||
order += "load"
|
|
||||||
order += "tztime local"
|
|
||||||
|
|
||||||
wireless ${networkInterfaces.wireless} {
|
|
||||||
format_up = "%essid"
|
|
||||||
format_down = "offline"
|
|
||||||
}
|
|
||||||
|
|
||||||
# run_watch retiolum {
|
|
||||||
# pidfile = "/var/run/tinc.retiolum.pid"
|
|
||||||
# format = "%title"
|
|
||||||
# }
|
|
||||||
|
|
||||||
path_exists openvpn {
|
|
||||||
path = "/proc/sys/net/ipv4/conf/tun0"
|
|
||||||
format = "%title"
|
|
||||||
}
|
|
||||||
|
|
||||||
battery all {
|
|
||||||
format = "%status%percentage"
|
|
||||||
format_down = "No battery"
|
|
||||||
status_chr = "↑"
|
|
||||||
status_bat = "↓"
|
|
||||||
status_unk = ""
|
|
||||||
status_full = "↯"
|
|
||||||
path = "/sys/class/power_supply/BAT%d/uevent"
|
|
||||||
low_threshold = 15
|
|
||||||
threshold_type = "percentage"
|
|
||||||
integer_battery_capacity = true
|
|
||||||
}
|
|
||||||
|
|
||||||
volume master {
|
|
||||||
format = "%volume"
|
|
||||||
format_muted = "%volume"
|
|
||||||
device = "default"
|
|
||||||
mixer = "Master"
|
|
||||||
mixer_idx = 0
|
|
||||||
}
|
|
||||||
|
|
||||||
tztime local {
|
|
||||||
format = "%Y-%m-%d %H:%M"
|
|
||||||
}
|
|
||||||
|
|
||||||
load {
|
|
||||||
format = "%1min"
|
|
||||||
}''}";
|
|
||||||
}];
|
}];
|
||||||
|
modes.resize = {
|
||||||
|
"Escape" = ''mode "default"'';
|
||||||
|
"Return" = ''mode "default"'';
|
||||||
|
"h" = "resize shrink width 10 px or 5 ppt";
|
||||||
|
"j" = "resize grow height 10 px or 5 ppt";
|
||||||
|
"k" = "resize shrink height 10 px or 5 ppt";
|
||||||
|
"l" = "resize grow width 10 px or 5 ppt";
|
||||||
|
};
|
||||||
keybindings = {
|
keybindings = {
|
||||||
"${modifier}+Down" = "focus down";
|
"${modifier}+Shift+h" = "move left 25 px";
|
||||||
"${modifier}+Left" = "focus left";
|
"${modifier}+Shift+j" = "move down 25 px";
|
||||||
"${modifier}+Return" = "exec ${applications.terminal}";
|
"${modifier}+Shift+k" = "move up 25 px";
|
||||||
"${modifier}+Right" = "focus right";
|
"${modifier}+Shift+l" = "move right 25 px";
|
||||||
"${modifier}+Shift+Down" = "move down";
|
|
||||||
"${modifier}+Shift+Left" = "move left";
|
|
||||||
"${modifier}+Shift+Right" = "move right";
|
|
||||||
"${modifier}+Shift+Up" = "move up";
|
|
||||||
"${modifier}+Shift+b" = "move window to workspace prev";
|
|
||||||
"${modifier}+Shift+c" = "reload";
|
|
||||||
"${modifier}+Shift+n" = "move window to workspace next";
|
|
||||||
"${modifier}+Shift+q" = "kill";
|
|
||||||
"${modifier}+Shift+r" = "restart";
|
|
||||||
"${modifier}+Shift+w" = "exec ${pkgs.xautolock}/bin/xautolock -locknow";
|
|
||||||
"${modifier}+Shift+x" = "exec --no-startup-id ${move-to-new-workspace}";
|
|
||||||
"${modifier}+Shift+z" = "floating toggle";
|
|
||||||
"${modifier}+Up" = "focus up";
|
|
||||||
"${modifier}+a" = "exec ${pkgs.rofi}/bin/rofi -display-window — -show window";
|
|
||||||
"${modifier}+b" = "workspace prev";
|
|
||||||
"${modifier}+c" = "split h";
|
|
||||||
"${modifier}+d" = "exec ${pkgs.rofi}/bin/rofi -display-run — -show run";
|
|
||||||
"${modifier}+e" = "layout toggle split";
|
|
||||||
"${modifier}+f" = "fullscreen toggle";
|
|
||||||
"${modifier}+h" = "focus left";
|
"${modifier}+h" = "focus left";
|
||||||
"${modifier}+j" = "focus down";
|
"${modifier}+j" = "focus down";
|
||||||
"${modifier}+k" = "focus up";
|
"${modifier}+k" = "focus up";
|
||||||
"${modifier}+l" = "focus right";
|
"${modifier}+l" = "focus right";
|
||||||
|
|
||||||
|
"${modifier}+Shift+b" = "move window to workspace prev";
|
||||||
|
"${modifier}+Shift+n" = "move window to workspace next";
|
||||||
|
"${modifier}+Shift+x" = "exec --no-startup-id ${move-to-new-workspace}";
|
||||||
|
"${modifier}+b" = "workspace prev";
|
||||||
"${modifier}+n" = "workspace next";
|
"${modifier}+n" = "workspace next";
|
||||||
"${modifier}+p" = "exec ${pkgs.rofi-pass}/bin/rofi-pass";
|
"${modifier}+x" = "exec --no-startup-id ${new-workspace}";
|
||||||
|
|
||||||
|
"${modifier}+Shift+c" = "reload";
|
||||||
|
"${modifier}+Shift+q" = "kill";
|
||||||
|
"${modifier}+Shift+r" = "restart";
|
||||||
|
|
||||||
|
"${modifier}+z" = "sticky toggle";
|
||||||
|
"${modifier}+Shift+z" = "floating toggle";
|
||||||
|
|
||||||
|
"${modifier}+s" = "scratchpad show";
|
||||||
|
"${modifier}+Shift+s" = "move scratchpad";
|
||||||
|
|
||||||
|
"${modifier}+c" = "split h";
|
||||||
|
"${modifier}+e" = "layout toggle split";
|
||||||
|
"${modifier}+f" = "fullscreen toggle";
|
||||||
"${modifier}+r" = "mode resize";
|
"${modifier}+r" = "mode resize";
|
||||||
"${modifier}+s" = "layout stacking";
|
|
||||||
"${modifier}+t" = "exec ${applications.fileManager}";
|
|
||||||
"${modifier}+v" = "split v";
|
"${modifier}+v" = "split v";
|
||||||
"${modifier}+w" = "layout tabbed";
|
"${modifier}+w" = "layout tabbed";
|
||||||
"${modifier}+x" = "exec --no-startup-id ${new-workspace}";
|
|
||||||
"${modifier}+y" = "exec ${applications.browser}";
|
# "${modifier}+Shift+y" = "exec ${pkgs.qutebrowser}/bin/qutebrowser";
|
||||||
|
"${modifier}+Return" = "exec ${(defaultApplications pkgs).terminal}";
|
||||||
|
"${modifier}+t" = "exec ${(defaultApplications pkgs).fileManager}";
|
||||||
|
"${modifier}+y" = "exec ${(defaultApplications pkgs).browser}";
|
||||||
|
"${modifier}+0" = "exec ${pkgs.scripts.menu-calc}/bin/=";
|
||||||
|
|
||||||
|
"${modifier}+Shift+w" = "exec ${pkgs.scripts.k-lock}/bin/k-lock";
|
||||||
|
"${modifier}+a" =
|
||||||
|
"exec --no-startup-id ${pkgs.rofi}/bin/rofi -display-window — -show window";
|
||||||
|
"${modifier}+d" = "exec --no-startup-id ${pkgs.dmenu}/bin/dmenu_run";
|
||||||
|
"${modifier}+Shift+d" = "exec ${
|
||||||
|
pkgs.writers.writeDash "notemenu" ''
|
||||||
|
set -efu
|
||||||
|
PATH=$PATH:${
|
||||||
|
lib.makeBinPath [ pkgs.dmenu pkgs.findutils pkgs.coreutils ]
|
||||||
|
}
|
||||||
|
|
||||||
|
cd ~/notes
|
||||||
|
note_file=$(find . -type f -printf "%T@ %p\n" | sort --reverse --numeric-sort | cut --delimiter=" " --fields=2 | dmenu -i)
|
||||||
|
if test "$note_file"
|
||||||
|
then
|
||||||
|
i3-sensible-terminal -e "$EDITOR" "$note_file"
|
||||||
|
fi
|
||||||
|
''
|
||||||
|
}";
|
||||||
|
"${modifier}+p" = "exec --no-startup-id ${pkgs.pass}/bin/passmenu -l 5";
|
||||||
|
"${modifier}+u" = "exec ${pkgs.scripts.unicodmenu}/bin/unicodmenu";
|
||||||
|
|
||||||
|
"${modifier}+F7" = "exec ${pkgs.scripts.showkeys-toggle}/bin/showkeys-toggle";
|
||||||
|
"${modifier}+F8" = "exec ${pkgs.xorg.xkill}/bin/xkill";
|
||||||
|
"${modifier}+F9" = "exec ${pkgs.redshift}/bin/redshift -O 4000 -b 0.85";
|
||||||
|
"${modifier}+F10" = "exec ${pkgs.redshift}/bin/redshift -x";
|
||||||
|
"${modifier}+F11" = "exec ${pkgs.xcalib}/bin/xcalib -invert -alter";
|
||||||
|
"${modifier}+F12" = "exec ${klem}/bin/klem";
|
||||||
|
|
||||||
|
"Print" = "exec flameshot gui -p /tmp";
|
||||||
"XF86AudioLowerVolume" = "exec --no-startup-id ${pkgs.pamixer}/bin/pamixer -d 5";
|
"XF86AudioLowerVolume" = "exec --no-startup-id ${pkgs.pamixer}/bin/pamixer -d 5";
|
||||||
"XF86AudioMute" = "exec --no-startup-id ${pkgs.pamixer}/bin/pamixer -t";
|
"XF86AudioMute" = "exec --no-startup-id ${pkgs.pamixer}/bin/pamixer -t";
|
||||||
"XF86AudioRaiseVolume" = "exec --no-startup-id ${pkgs.pamixer}/bin/pamixer -i 5";
|
"XF86AudioRaiseVolume" = "exec --no-startup-id ${pkgs.pamixer}/bin/pamixer -i 5";
|
||||||
|
"XF86Calculator" = "exec ${pkgs.st}/bin/st -c floating -e ${pkgs.bc}/bin/bc";
|
||||||
|
"XF86AudioPause" = "exec --no-startup-id ${pkgs.playerctl}/bin/playerctl pause";
|
||||||
|
"XF86AudioPlay" = "exec --no-startup-id ${pkgs.playerctl}/bin/playerctl play-pause";
|
||||||
|
"XF86AudioNext" = "exec --no-startup-id ${pkgs.playerctl}/bin/playerctl next";
|
||||||
|
"XF86AudioPrev" = "exec --no-startup-id ${pkgs.playerctl}/bin/playerctl previous";
|
||||||
|
"XF86AudioStop" = "exec --no-startup-id ${pkgs.playerctl}/bin/playerctl stop";
|
||||||
|
"XF86ScreenSaver" = "exec ${pkgs.scripts.k-lock}/bin/k-lock";
|
||||||
|
|
||||||
|
"XF86Display" = "exec ${pkgs.scripts.dmenurandr}/bin/dmenurandr";
|
||||||
|
|
||||||
|
# key names detected with xorg.xev:
|
||||||
|
# XF86WakeUp (fn twice)
|
||||||
|
# XF86Battery (fn f3)
|
||||||
|
# XF86Sleep (fn f4) - actually suspends
|
||||||
|
# XF86WLAN
|
||||||
|
# XF86WebCam (fn f6)
|
||||||
|
# XF86TouchpadToggle (fn f8)
|
||||||
|
# XF86Suspend (fn f12) - actually suspends to disk
|
||||||
|
# Num_Lock (fn Roll) - numlocks
|
||||||
|
# XF86Audio{Prev,Next,Mute,Play,Stop}
|
||||||
|
# XF86Forward
|
||||||
|
# XF86Back
|
||||||
|
# XF86Launch1 (thinkvantage)
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -1,7 +1,13 @@
|
|||||||
{
|
{
|
||||||
networking.firewall = {
|
networking.firewall = {
|
||||||
allowedTCPPortRanges = [ { from = 1714; to = 1764; } ];
|
allowedTCPPortRanges = [{
|
||||||
allowedUDPPortRanges = [ { from = 1714; to = 1764; } ];
|
from = 1714;
|
||||||
|
to = 1764;
|
||||||
|
}];
|
||||||
|
allowedUDPPortRanges = [{
|
||||||
|
from = 1714;
|
||||||
|
to = 1764;
|
||||||
|
}];
|
||||||
};
|
};
|
||||||
|
|
||||||
home-manager.users.me = {
|
home-manager.users.me = {
|
||||||
|
|||||||
@@ -1,9 +0,0 @@
|
|||||||
{ config, ... }:
|
|
||||||
{
|
|
||||||
services.keybase.enable = true;
|
|
||||||
|
|
||||||
services.kbfs = {
|
|
||||||
enable = true;
|
|
||||||
mountPoint = "%h/cloud/keybase";
|
|
||||||
};
|
|
||||||
}
|
|
||||||
@@ -1,11 +1,17 @@
|
|||||||
with import <lib>;
|
{ pkgs, lib, ... }:
|
||||||
{
|
let commaSep = builtins.concatStringsSep ",";
|
||||||
|
in {
|
||||||
services.xserver = {
|
services.xserver = {
|
||||||
layout = commaSep [ "de" "gr" "ru" ];
|
layout = commaSep [ "de" "gr" "ru" ];
|
||||||
xkbVariant = commaSep [ "T3" "polytonic" "phonetic_winkeys" ];
|
xkbVariant = commaSep [ "T3" "polytonic" "phonetic" ];
|
||||||
xkbOptions = commaSep [ "compose:caps" "terminate:ctrl_alt_bksp" "grp:ctrls_toggle" ];
|
xkbOptions =
|
||||||
|
commaSep [ "compose:caps" "terminate:ctrl_alt_bksp" "grp:ctrls_toggle" ];
|
||||||
libinput.enable = true;
|
libinput.enable = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
i18n.consoleKeyMap = "de";
|
console.keyMap = "de";
|
||||||
|
|
||||||
|
# improve held key rate
|
||||||
|
services.xserver.displayManager.sessionCommands =
|
||||||
|
"${pkgs.xorg.xset}/bin/xset r rate 300 50";
|
||||||
}
|
}
|
||||||
|
|||||||
167
configs/khal.nix
Normal file
@@ -0,0 +1,167 @@
|
|||||||
|
{ config, pkgs, lib, ... }:
|
||||||
|
let
|
||||||
|
davHome = "~/.local/share/dav";
|
||||||
|
kmeinCloud = {
|
||||||
|
davEndpoint = "https://cloud.xn--kiern-0qa.de/remote.php/dav";
|
||||||
|
username = "kieran";
|
||||||
|
password = lib.fileContents <secrets/nextcloud/password>;
|
||||||
|
};
|
||||||
|
fysiCloud = {
|
||||||
|
davEndpoint = "https://nextcloud.fysi.dev/remote.php/dav";
|
||||||
|
username = "kmein";
|
||||||
|
password = lib.fileContents <secrets/nextcloud-fysi/password>;
|
||||||
|
};
|
||||||
|
in
|
||||||
|
{
|
||||||
|
environment.systemPackages = [ pkgs.khal pkgs.vdirsyncer pkgs.khard pkgs.todoman ];
|
||||||
|
|
||||||
|
systemd.user.services.vdirsyncer = {
|
||||||
|
enable = true;
|
||||||
|
wants = [ "network-online.target" ];
|
||||||
|
wantedBy = [ "default.target" ];
|
||||||
|
startAt = "*:00/10";
|
||||||
|
script = ''
|
||||||
|
${pkgs.vdirsyncer}/bin/vdirsyncer sync
|
||||||
|
${pkgs.khal}/bin/khal printcalendars # https://lostpackets.de/khal/configure.html#syncing
|
||||||
|
'';
|
||||||
|
serviceConfig = {
|
||||||
|
Type = "oneshot";
|
||||||
|
Restart = "on-failure";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
home-manager.users.me = {
|
||||||
|
xdg.configFile = {
|
||||||
|
"khard/khard.conf".text = ''
|
||||||
|
[addressbooks]
|
||||||
|
[[contacts]]
|
||||||
|
path = ${davHome}/contacts/contacts/
|
||||||
|
|
||||||
|
[general]
|
||||||
|
debug = no
|
||||||
|
default_action = list
|
||||||
|
editor = ${config.environment.variables.EDITOR}
|
||||||
|
merge_editor = ${pkgs.vim}/bin/vimdiff
|
||||||
|
|
||||||
|
[contact table]
|
||||||
|
display = first_name
|
||||||
|
group_by_addressbook = no
|
||||||
|
reverse = no
|
||||||
|
show_nicknames = no
|
||||||
|
show_uids = no
|
||||||
|
sort = last_name
|
||||||
|
localize_dates = yes
|
||||||
|
preferred_phone_number_type = pref, cell, home
|
||||||
|
preferred_email_address_type = pref, work, home
|
||||||
|
|
||||||
|
[vcard]
|
||||||
|
search_in_source_files = no
|
||||||
|
skip_unparsable = no
|
||||||
|
'';
|
||||||
|
|
||||||
|
"todoman/todoman.conf".text = ''
|
||||||
|
[main]
|
||||||
|
path = ${davHome}/calendar/*
|
||||||
|
date_format = %Y-%m-%d
|
||||||
|
time_format = %H:%M
|
||||||
|
default_due = 0
|
||||||
|
default_list = Personal
|
||||||
|
startable = True
|
||||||
|
'';
|
||||||
|
|
||||||
|
"khal/config".text = ''
|
||||||
|
[calendars]
|
||||||
|
|
||||||
|
[[alew]]
|
||||||
|
path = ${davHome}/calendar/alew
|
||||||
|
color = "light gray"
|
||||||
|
|
||||||
|
[[personal]]
|
||||||
|
path = ${davHome}/calendar/personal
|
||||||
|
color = "light cyan"
|
||||||
|
|
||||||
|
[[uni]]
|
||||||
|
path = ${davHome}/calendar/uni-1
|
||||||
|
color = "yellow"
|
||||||
|
|
||||||
|
[[fysi]]
|
||||||
|
path = ${davHome}/calendar/fysi-1
|
||||||
|
color = "light magenta"
|
||||||
|
|
||||||
|
[[fysi_team]]
|
||||||
|
path = ${davHome}/calendar/personal_shared_by_fdf
|
||||||
|
color = "light red"
|
||||||
|
|
||||||
|
[[birthdays]]
|
||||||
|
path = ${davHome}/contacts/contacts
|
||||||
|
type = birthdays
|
||||||
|
color = "light green"
|
||||||
|
|
||||||
|
[default]
|
||||||
|
highlight_event_days = True
|
||||||
|
timedelta = 5d
|
||||||
|
|
||||||
|
[locale]
|
||||||
|
timeformat = %H:%M
|
||||||
|
dateformat = %Y-%m-%d
|
||||||
|
longdateformat = %Y-%m-%d
|
||||||
|
datetimeformat = %Y-%m-%d %H:%M
|
||||||
|
longdatetimeformat = %Y-%m-%d %H:%M
|
||||||
|
local_timezone = ${config.time.timeZone}
|
||||||
|
default_timezone = ${config.time.timeZone}
|
||||||
|
weeknumbers = left
|
||||||
|
'';
|
||||||
|
|
||||||
|
"vdirsyncer/config".text = ''
|
||||||
|
[general]
|
||||||
|
status_path = "~/.local/share/vdirsyncer/status/"
|
||||||
|
|
||||||
|
[pair kontakte]
|
||||||
|
a = "kontakte_local"
|
||||||
|
b = "kontakte_cloud"
|
||||||
|
collections = ["contacts"]
|
||||||
|
conflict_resolution = "b wins"
|
||||||
|
|
||||||
|
[pair kalender]
|
||||||
|
a = "kalender_local"
|
||||||
|
b = "kalender_cloud"
|
||||||
|
collections = ["personal", "alew", "uni-1"]
|
||||||
|
conflict_resolution = "b wins"
|
||||||
|
|
||||||
|
[pair fysi]
|
||||||
|
a = "kalender_local"
|
||||||
|
b = "fysi_cloud"
|
||||||
|
collections = ["fysi-1", "personal_shared_by_fdf"]
|
||||||
|
conflict_resolution = "b wins"
|
||||||
|
|
||||||
|
[storage kontakte_local]
|
||||||
|
type = "filesystem"
|
||||||
|
path = "${davHome}/contacts/"
|
||||||
|
fileext = ".vcf"
|
||||||
|
|
||||||
|
[storage kalender_local]
|
||||||
|
type = "filesystem"
|
||||||
|
path = "${davHome}/calendar/"
|
||||||
|
fileext = ".ics"
|
||||||
|
|
||||||
|
[storage kontakte_cloud]
|
||||||
|
type = "carddav"
|
||||||
|
url = "${kmeinCloud.davEndpoint}/addressbooks/users/${kmeinCloud.username}/"
|
||||||
|
username = "${kmeinCloud.username}"
|
||||||
|
password = "${kmeinCloud.password}"
|
||||||
|
|
||||||
|
[storage kalender_cloud]
|
||||||
|
type = "caldav"
|
||||||
|
url = "${kmeinCloud.davEndpoint}/calendars/${kmeinCloud.username}/"
|
||||||
|
username = "${kmeinCloud.username}"
|
||||||
|
password = "${kmeinCloud.password}"
|
||||||
|
|
||||||
|
[storage fysi_cloud]
|
||||||
|
type = "caldav"
|
||||||
|
url = "${fysiCloud.davEndpoint}/calendars/${fysiCloud.username}/"
|
||||||
|
username = "${fysiCloud.username}"
|
||||||
|
password = "${fysiCloud.password}"
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
27
configs/lb.nix
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
{ lib, pkgs, ... }:
|
||||||
|
let
|
||||||
|
nixpkgs-unstable = import <nixpkgs-unstable> {};
|
||||||
|
in
|
||||||
|
{
|
||||||
|
systemd.services.lb-subscription = {
|
||||||
|
enable = true;
|
||||||
|
wants = [ "network-online.target" ];
|
||||||
|
startAt = "weekly";
|
||||||
|
serviceConfig = {
|
||||||
|
user = "kfm";
|
||||||
|
WorkingDirectory = "/home/kfm/cloud/Seafile/Books/Germanistik/LB";
|
||||||
|
};
|
||||||
|
script = ''
|
||||||
|
first_year=2019
|
||||||
|
for year in $(${pkgs.coreutils}/bin/seq "$first_year" "$(date +%Y)"); do
|
||||||
|
${pkgs.curl}/bin/curl -sSL "https://www.literarische-blaetter.de/jahrgang-$year/" \
|
||||||
|
| ${nixpkgs-unstable.htmlq}/bin/htmlq --attribute href 'ul.slides a' \
|
||||||
|
| while read -r month; do
|
||||||
|
${pkgs.curl}/bin/curl -sSL "$month" \
|
||||||
|
| ${nixpkgs-unstable.htmlq}/bin/htmlq --attribute src iframe \
|
||||||
|
| ${pkgs.gnused}/bin/sed 's/.*?pdf=//;s/?wp-hosted.*//'
|
||||||
|
done
|
||||||
|
done | ${pkgs.findutils}/bin/xargs ${pkgs.wget}/bin/wget --no-clobber
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
}
|
||||||
@@ -1,39 +0,0 @@
|
|||||||
{ config, pkgs, ... }:
|
|
||||||
{
|
|
||||||
environment.systemPackages = [
|
|
||||||
pkgs.notmuch
|
|
||||||
pkgs.offlineimap
|
|
||||||
pkgs.msmtp
|
|
||||||
pkgs.neomutt
|
|
||||||
];
|
|
||||||
|
|
||||||
home-manager.users.me = {
|
|
||||||
accounts.email.maildirBasePath = "${config.users.users.me.home}/mail";
|
|
||||||
accounts.email.accounts.hu-berlin = {
|
|
||||||
address = "meinhark@hu-berlin.de";
|
|
||||||
userName = "meinhark";
|
|
||||||
realName = config.niveum.user.fullName;
|
|
||||||
imap = {
|
|
||||||
host = "mailbox.cms.hu-berlin.de";
|
|
||||||
port = 993;
|
|
||||||
tls.enable = true;
|
|
||||||
};
|
|
||||||
smtp = {
|
|
||||||
host = "mailhost.cms.hu-berlin.de";
|
|
||||||
port = 25;
|
|
||||||
tls.enable = true;
|
|
||||||
};
|
|
||||||
msmtp.enable = true;
|
|
||||||
notmuch.enable = true;
|
|
||||||
offlineimap = {
|
|
||||||
enable = true;
|
|
||||||
postSyncHookCommand = "notmuch new";
|
|
||||||
};
|
|
||||||
primary = true;
|
|
||||||
};
|
|
||||||
|
|
||||||
programs.offlineimap = {
|
|
||||||
enable = true;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}
|
|
||||||
56
configs/matterbridge.nix
Normal file
@@ -0,0 +1,56 @@
|
|||||||
|
{ pkgs, lib, ... }:
|
||||||
|
{
|
||||||
|
nixpkgs.overlays = [
|
||||||
|
(self: super: {
|
||||||
|
matterbridge = (import (super.fetchFromGitHub {
|
||||||
|
owner = "NixOS";
|
||||||
|
repo = "nixpkgs";
|
||||||
|
rev = "e45d91ee65db293a172ec506759d1248e40c35f5";
|
||||||
|
sha256 = "03cjs5xcx09lw0djyrx2kfakw7gkg4iqmy9w25azai62im39l30k";
|
||||||
|
}) {}).matterbridge;
|
||||||
|
})
|
||||||
|
];
|
||||||
|
|
||||||
|
services.matterbridge = {
|
||||||
|
enable = true;
|
||||||
|
configPath =
|
||||||
|
let bridgeBotToken = lib.strings.fileContents <system-secrets/telegram/kmein.token>;
|
||||||
|
in toString ((pkgs.formats.toml {}).generate "config.toml" {
|
||||||
|
general = {
|
||||||
|
RemoteNickFormat = "[{NICK}] ";
|
||||||
|
Charset = "utf-8";
|
||||||
|
};
|
||||||
|
telegram.kmein.Token = bridgeBotToken;
|
||||||
|
irc =
|
||||||
|
let Nick = "ponte";
|
||||||
|
in {
|
||||||
|
hackint = { Server = "irc.hackint.org:6697"; UseTLS = true; inherit Nick; };
|
||||||
|
};
|
||||||
|
mumble.lassulus = {
|
||||||
|
Server = "lassul.us:64738";
|
||||||
|
Nick = "krebs_bridge";
|
||||||
|
SkipTLSVerify = true;
|
||||||
|
};
|
||||||
|
gateway = [
|
||||||
|
{
|
||||||
|
name = "krebs-bridge";
|
||||||
|
enable = true;
|
||||||
|
inout = [
|
||||||
|
{
|
||||||
|
account = "irc.hackint";
|
||||||
|
channel = "#krebs";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
account = "telegram.kmein";
|
||||||
|
channel = "-330372458";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
account = "mumble.lassulus";
|
||||||
|
channel = 6; # "nixos"
|
||||||
|
}
|
||||||
|
];
|
||||||
|
}
|
||||||
|
];
|
||||||
|
});
|
||||||
|
};
|
||||||
|
}
|
||||||
41
configs/menstruation.nix
Normal file
@@ -0,0 +1,41 @@
|
|||||||
|
{ pkgs, lib, ... }:
|
||||||
|
let
|
||||||
|
backend = pkgs.callPackage <niveum/submodules/menstruation-backend> {};
|
||||||
|
telegram = pkgs.callPackage <niveum/submodules/menstruation-telegram> {};
|
||||||
|
backendPort = 8000;
|
||||||
|
in
|
||||||
|
{
|
||||||
|
containers.menstruation.autoStart = true;
|
||||||
|
containers.menstruation.config = { config, pkgs, ... }: {
|
||||||
|
services.redis.enable = true;
|
||||||
|
|
||||||
|
systemd.services.menstruation-telegram = {
|
||||||
|
wants = [
|
||||||
|
"network-online.target"
|
||||||
|
"menstruation-backend.service"
|
||||||
|
"redis.service"
|
||||||
|
];
|
||||||
|
wantedBy = [ "multi-user.target" ];
|
||||||
|
environment = {
|
||||||
|
MENSTRUATION_TOKEN = lib.strings.fileContents <system-secrets/telegram/menstruation.token>;
|
||||||
|
MENSTRUATION_ENDPOINT = "http://localhost:${toString backendPort}";
|
||||||
|
MENSTRUATION_MODERATORS = "18980945";
|
||||||
|
};
|
||||||
|
serviceConfig = {
|
||||||
|
Restart = "always";
|
||||||
|
DynamicUser = true;
|
||||||
|
ExecStart = "${telegram}/bin/menstruation-telegram";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
systemd.services.menstruation-backend = {
|
||||||
|
wants = [ "network-online.target" ];
|
||||||
|
environment.ROCKET_PORT = toString backendPort;
|
||||||
|
serviceConfig = {
|
||||||
|
Restart = "always";
|
||||||
|
DynamicUser = true;
|
||||||
|
ExecStart = "${backend}/bin/menstruation_server";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
27
configs/mime.nix
Normal file
@@ -0,0 +1,27 @@
|
|||||||
|
{
|
||||||
|
home-manager.users.me = {
|
||||||
|
xdg.mimeApps = {
|
||||||
|
enable = true;
|
||||||
|
defaultApplications = {
|
||||||
|
"application/epub+zip" = "org.pwmt.zathura.desktop";
|
||||||
|
"application/pdf" = "org.pwmt.zathura.desktop";
|
||||||
|
"application/vnd.oasis.opendocument.text" = "writer.desktop";
|
||||||
|
"application/vnd.openxmlformats-officedocument.wordprocessingml.document" = "writer.desktop";
|
||||||
|
"image/jpeg" = "sxiv.desktop";
|
||||||
|
"image/png" = "sxiv.desktop";
|
||||||
|
"image/vnd.djvu+multipage" = "org.pwmt.zathura.desktop";
|
||||||
|
"text/html" = "brave-browser.desktop";
|
||||||
|
"text/markdown" = "nvim.desktop";
|
||||||
|
"text/plain" = "nvim.desktop";
|
||||||
|
"x-scheme-handler/about" = "brave-browser.desktop";
|
||||||
|
"x-scheme-handler/http" = "brave-browser.desktop";
|
||||||
|
"x-scheme-handler/https" = "brave-browser.desktop";
|
||||||
|
"x-scheme-handler/mailto" = "brave-browser.desktop";
|
||||||
|
"x-scheme-handler/unknown" = "brave-browser.desktop";
|
||||||
|
"x-scheme-handler/webcal" = "brave-browser.desktop";
|
||||||
|
"inode/directory" = "pcmanfm.desktop";
|
||||||
|
};
|
||||||
|
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
60
configs/monitoring/loki.nix
Normal file
@@ -0,0 +1,60 @@
|
|||||||
|
{
|
||||||
|
auth_enabled = false;
|
||||||
|
server = {
|
||||||
|
http_listen_port = 3100;
|
||||||
|
grpc_listen_port = 9096;
|
||||||
|
};
|
||||||
|
ingester = {
|
||||||
|
wal = {
|
||||||
|
enabled = true;
|
||||||
|
dir = "/tmp/wal";
|
||||||
|
};
|
||||||
|
lifecycler = {
|
||||||
|
address = "127.0.0.1";
|
||||||
|
ring = {
|
||||||
|
kvstore.store = "inmemory";
|
||||||
|
replication_factor = 1;
|
||||||
|
};
|
||||||
|
final_sleep = "0s";
|
||||||
|
};
|
||||||
|
chunk_idle_period = "1h"; # Any chunk not receiving new logs in this time will be flushed
|
||||||
|
max_chunk_age = "1h"; # All chunks will be flushed when they hit this age, default is 1h
|
||||||
|
chunk_target_size = 1048576; # Loki will attempt to build chunks up to 1.5MB, flushing first if chunk_idle_period or max_chunk_age is reached first
|
||||||
|
chunk_retain_period = "30s"; # Must be greater than index read cache TTL if using an index cache (Default index read cache TTL is 5m)
|
||||||
|
max_transfer_retries = 0; # Chunk transfers disabled
|
||||||
|
};
|
||||||
|
schema_config.configs = [
|
||||||
|
{
|
||||||
|
from = "2020-10-24";
|
||||||
|
store = "boltdb-shipper";
|
||||||
|
object_store = "filesystem";
|
||||||
|
schema = "v11";
|
||||||
|
index = {
|
||||||
|
prefix = "index_";
|
||||||
|
period = "24h";
|
||||||
|
};
|
||||||
|
}
|
||||||
|
];
|
||||||
|
storage_config = {
|
||||||
|
boltdb_shipper = {
|
||||||
|
active_index_directory = "/tmp/loki/boltdb-shipper-active";
|
||||||
|
cache_location = "/tmp/loki/boltdb-shipper-cache";
|
||||||
|
cache_ttl = "24h"; # Can be increased for faster performance over longer query periods, uses more disk space
|
||||||
|
shared_store = "filesystem";
|
||||||
|
};
|
||||||
|
filesystem.directory = "/tmp/loki/chunks";
|
||||||
|
};
|
||||||
|
compactor = {
|
||||||
|
working_directory = "/tmp/loki/boltdb-shipper-compactor";
|
||||||
|
shared_store = "filesystem";
|
||||||
|
};
|
||||||
|
limits_config = {
|
||||||
|
reject_old_samples = true;
|
||||||
|
reject_old_samples_max_age = "168h";
|
||||||
|
};
|
||||||
|
chunk_store_config.max_look_back_period = "0s";
|
||||||
|
table_manager = {
|
||||||
|
retention_deletes_enabled = false;
|
||||||
|
retention_period = "0s";
|
||||||
|
};
|
||||||
|
}
|
||||||
177
configs/monitoring/pull.nix
Normal file
@@ -0,0 +1,177 @@
|
|||||||
|
{ lib, config, pkgs, ... }:
|
||||||
|
let
|
||||||
|
lokiConfig = import ./loki.nix;
|
||||||
|
in
|
||||||
|
{
|
||||||
|
services.grafana = {
|
||||||
|
enable = true;
|
||||||
|
domain = "grafana.kmein.r";
|
||||||
|
port = 9444;
|
||||||
|
addr = "127.0.0.1";
|
||||||
|
};
|
||||||
|
|
||||||
|
services.nginx.virtualHosts.${config.services.grafana.domain} = {
|
||||||
|
locations."/" = {
|
||||||
|
proxyPass = "http://127.0.0.1:${toString config.services.grafana.port}";
|
||||||
|
proxyWebsockets = true;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
services.prometheus.rules = let diskFreeThreshold = 10; in [(builtins.toJSON {
|
||||||
|
groups = [{
|
||||||
|
name = "niveum";
|
||||||
|
rules = [
|
||||||
|
{
|
||||||
|
alert = "ServiceDown";
|
||||||
|
expr = ''node_systemd_unit_state{state="failed"} == 1'';
|
||||||
|
annotations = {
|
||||||
|
summary = "{{$labels.job}}: Service {{$labels.name}} failed to start.";
|
||||||
|
};
|
||||||
|
}
|
||||||
|
{
|
||||||
|
alert = "RootPartitionFull";
|
||||||
|
for = "10m";
|
||||||
|
expr = ''(node_filesystem_free_bytes{mountpoint="/"} * 100) / node_filesystem_size_bytes{mountpoint="/"} < ${toString diskFreeThreshold}'';
|
||||||
|
annotations = {
|
||||||
|
summary = "{{ $labels.job }}: Filesystem is running out of space soon.";
|
||||||
|
description = ''The root disk of {{ $labels.job }} has {{ $value | printf "%.2f" }}% free disk space (threshold at ${toString diskFreeThreshold}%).'';
|
||||||
|
};
|
||||||
|
}
|
||||||
|
{
|
||||||
|
alert = "RootPartitionFullWeek";
|
||||||
|
for = "1h";
|
||||||
|
expr = ''node_filesystem_free_bytes{mountpoint="/"} ''
|
||||||
|
+ ''and predict_linear(node_filesystem_free_bytes{mountpoint="/"}[2d], 7*24*3600) <= 0'';
|
||||||
|
annotations = {
|
||||||
|
summary = "{{$labels.job}}: Filesystem is running out of space in 7 days.";
|
||||||
|
};
|
||||||
|
}
|
||||||
|
{
|
||||||
|
alert = "HighLoad";
|
||||||
|
expr = ''node_load15 / on(job) count(node_cpu_seconds_total{mode="system"}) by (job) >= 1.0'';
|
||||||
|
for = "10m";
|
||||||
|
annotations = {
|
||||||
|
summary = "{{$labels.job}}: Running on high load: {{$value}}";
|
||||||
|
};
|
||||||
|
}
|
||||||
|
{
|
||||||
|
alert = "HighRAM";
|
||||||
|
expr = "node_memory_MemFree_bytes + node_memory_Buffers_bytes + node_memory_Cached_bytes < node_memory_MemTotal_bytes * 0.1";
|
||||||
|
for = "1h";
|
||||||
|
annotations.summary = "{{$labels.job}}: Using lots of RAM.";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
alert = "UptimeMonster";
|
||||||
|
expr = "time() - node_boot_time_seconds > 2592000";
|
||||||
|
annotations.summary = "{{$labels.job}}: up for more than 30 days.";
|
||||||
|
}
|
||||||
|
{
|
||||||
|
alert = "HostDown";
|
||||||
|
expr = ''up == 0'';
|
||||||
|
for = "5m";
|
||||||
|
annotations = {
|
||||||
|
summary = "Host {{ $labels.job }} down for 5 minutes.";
|
||||||
|
};
|
||||||
|
}
|
||||||
|
{
|
||||||
|
alert = "Reboot";
|
||||||
|
expr = "time() - node_boot_time_seconds < 300";
|
||||||
|
annotations.summary = "{{$labels.job}}: Reboot";
|
||||||
|
}
|
||||||
|
];
|
||||||
|
}];
|
||||||
|
})];
|
||||||
|
|
||||||
|
systemd.services.alertmanager-bot-telegram =
|
||||||
|
let
|
||||||
|
alertmanager-bot-telegram = pkgs.buildGoModule rec {
|
||||||
|
pname = "alertmanager-bot";
|
||||||
|
version = "2020-07-13";
|
||||||
|
src = pkgs.fetchFromGitHub {
|
||||||
|
owner = "metalmatze";
|
||||||
|
repo = "alertmanager-bot";
|
||||||
|
rev = "5efc0bbbf8023d4324e9da98562f064a714a7206";
|
||||||
|
sha256 = "09cciml1j8x76jpm2v5v6h2q6j1fkhsz1kswslmx8wl4wk40xgp4";
|
||||||
|
};
|
||||||
|
vendorSha256 = "1v0fgin8dn81b559zz4lqmrl7hikr46g4gb18sci4riql5qs1isj";
|
||||||
|
postInstall = ''
|
||||||
|
install -D ./default.tmpl $out/templates/default.tmpl
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
in {
|
||||||
|
wantedBy = [ "multi-user.target" ];
|
||||||
|
after = [ "ip-up.target" ];
|
||||||
|
environment.TELEGRAM_ADMIN = "18980945";
|
||||||
|
environment.TELEGRAM_TOKEN = lib.strings.fileContents <system-secrets/telegram/prometheus.token>;
|
||||||
|
serviceConfig = {
|
||||||
|
DynamicUser = true;
|
||||||
|
StateDirectory = "alertbot";
|
||||||
|
ExecStart = ''${alertmanager-bot-telegram}/bin/alertmanager-bot \
|
||||||
|
--alertmanager.url=http://localhost:9093 --log.level=info \
|
||||||
|
--store=bolt --bolt.path=/var/lib/alertbot/bot.db \
|
||||||
|
--listen.addr="0.0.0.0:16320" \
|
||||||
|
--template.paths=${pkgs.writeText "template.tmpl" ''
|
||||||
|
{{ define "telegram.default" }}
|
||||||
|
{{range .Alerts -}}
|
||||||
|
{{ if eq .Status "firing" }}
|
||||||
|
⚠ <b>{{ index .Annotations "summary"}}</b>
|
||||||
|
{{ index .Annotations "description" }}
|
||||||
|
|
||||||
|
See on Grafana: http://${config.services.grafana.domain}/d/alpUteInz/niveum
|
||||||
|
{{ else -}}
|
||||||
|
RESOLVED 😌 <del>{{ index .Annotations "summary"}}</del>
|
||||||
|
{{- end }}
|
||||||
|
{{end -}}
|
||||||
|
{{end}}
|
||||||
|
''}'';
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
services.prometheus.alertmanager = {
|
||||||
|
enable = true;
|
||||||
|
listenAddress = "localhost";
|
||||||
|
configuration = {
|
||||||
|
route = {
|
||||||
|
group_wait = "30s";
|
||||||
|
repeat_interval = "4h";
|
||||||
|
receiver = "me";
|
||||||
|
};
|
||||||
|
receivers = [{
|
||||||
|
name = "me";
|
||||||
|
webhook_configs = [{
|
||||||
|
url = "http://localhost:16320";
|
||||||
|
send_resolved = true;
|
||||||
|
}];
|
||||||
|
}];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
services.prometheus.alertmanagers = [{
|
||||||
|
scheme = "http";
|
||||||
|
path_prefix = "/";
|
||||||
|
static_configs = [ { targets = [ "localhost:9093" ]; } ];
|
||||||
|
}];
|
||||||
|
|
||||||
|
services.prometheus.scrapeConfigs = [
|
||||||
|
{
|
||||||
|
job_name = "makanek";
|
||||||
|
static_configs = [ { targets = [
|
||||||
|
"127.0.0.1:${toString config.services.prometheus.exporters.node.port}"
|
||||||
|
# "127.0.0.1:${toString config.services.prometheus.exporters.nginx.port}"
|
||||||
|
]; } ];
|
||||||
|
}
|
||||||
|
{
|
||||||
|
job_name = "zaatar";
|
||||||
|
static_configs = [ { targets = [ "zaatar.r:${toString config.services.prometheus.exporters.node.port}" ]; } ];
|
||||||
|
}
|
||||||
|
];
|
||||||
|
|
||||||
|
networking.firewall.allowedTCPPorts = [
|
||||||
|
lokiConfig.server.http_listen_port
|
||||||
|
];
|
||||||
|
|
||||||
|
services.loki = {
|
||||||
|
enable = true;
|
||||||
|
configFile = (pkgs.formats.yaml {}).generate "loki.yaml" lokiConfig;
|
||||||
|
};
|
||||||
|
}
|
||||||
75
configs/monitoring/push.nix
Normal file
@@ -0,0 +1,75 @@
|
|||||||
|
{ config, pkgs, ... }:
|
||||||
|
{
|
||||||
|
services.nginx.virtualHosts.default = {
|
||||||
|
locations."= /stub_status".extraConfig = "stub_status;";
|
||||||
|
};
|
||||||
|
|
||||||
|
services.prometheus = {
|
||||||
|
enable = true;
|
||||||
|
port = 9001;
|
||||||
|
exporters = {
|
||||||
|
nginx.enable = false;
|
||||||
|
node = {
|
||||||
|
enable = true;
|
||||||
|
enabledCollectors = [
|
||||||
|
"conntrack"
|
||||||
|
"diskstats"
|
||||||
|
"entropy"
|
||||||
|
"filefd"
|
||||||
|
"filesystem"
|
||||||
|
"loadavg"
|
||||||
|
"mdadm"
|
||||||
|
"meminfo"
|
||||||
|
"netdev"
|
||||||
|
"netstat"
|
||||||
|
"stat"
|
||||||
|
"time"
|
||||||
|
"vmstat"
|
||||||
|
"systemd"
|
||||||
|
"logind"
|
||||||
|
"interrupts"
|
||||||
|
"ksmd"
|
||||||
|
];
|
||||||
|
port = 9002;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
networking.firewall.allowedTCPPorts = [ config.services.prometheus.exporters.node.port ];
|
||||||
|
|
||||||
|
systemd.services.promtail = {
|
||||||
|
description = "Promtail service for Loki";
|
||||||
|
wantedBy = [ "multi-user.target" ];
|
||||||
|
|
||||||
|
serviceConfig = {
|
||||||
|
ExecStart = ''
|
||||||
|
${pkgs.grafana-loki}/bin/promtail --config.file ${(pkgs.formats.yaml {}).generate "promtail.yaml" {
|
||||||
|
server = {
|
||||||
|
http_listen_port = 28183;
|
||||||
|
grpc_listen_port = 0;
|
||||||
|
};
|
||||||
|
positions.filename = "/tmp/positions.yaml";
|
||||||
|
clients = [
|
||||||
|
{ url = "http://${if config.networking.hostName == "makanek" then "127.0.0.1" else "makanek.r"}:3100/loki/api/v1/push"; }
|
||||||
|
];
|
||||||
|
scrape_configs = [
|
||||||
|
{
|
||||||
|
job_name = "journal";
|
||||||
|
journal = {
|
||||||
|
max_age = "12h";
|
||||||
|
labels.job = "systemd-journal";
|
||||||
|
labels.host = config.networking.hostName;
|
||||||
|
};
|
||||||
|
relabel_configs = [
|
||||||
|
{
|
||||||
|
source_labels = [ "__journal__systemd_unit" ];
|
||||||
|
target_label = "unit";
|
||||||
|
}
|
||||||
|
];
|
||||||
|
}
|
||||||
|
];
|
||||||
|
}}
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
31
configs/moodle-dl/borsfaye.nix
Normal file
@@ -0,0 +1,31 @@
|
|||||||
|
{ config, pkgs, lib, ... }:
|
||||||
|
let
|
||||||
|
moodle-dl-package = pkgs.moodle-dl.overrideAttrs (old: old // {
|
||||||
|
patches = [ <niveum/packages/moodle-dl/telegram-format.patch> ];
|
||||||
|
});
|
||||||
|
in
|
||||||
|
{
|
||||||
|
containers.moodle-dl-borsfaye = {
|
||||||
|
autoStart = true;
|
||||||
|
config = { lib, pkgs, ...}: {
|
||||||
|
imports = [ <niveum/modules/moodle-dl.nix> ];
|
||||||
|
|
||||||
|
services.moodle-dl = {
|
||||||
|
enable = true;
|
||||||
|
startAt = "hourly";
|
||||||
|
package = moodle-dl-package;
|
||||||
|
notifyOnly = true;
|
||||||
|
settings = {
|
||||||
|
telegram = {
|
||||||
|
token = lib.strings.fileContents <system-secrets/telegram/moodle-dl.token>;
|
||||||
|
chat_id = "311425510";
|
||||||
|
send_error_msg = false;
|
||||||
|
};
|
||||||
|
token = lib.strings.fileContents <system-secrets/moodle-dl/faye.token>;
|
||||||
|
moodle_domain = "moodle.hu-berlin.de";
|
||||||
|
moodle_path = "/";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
};
|
||||||
|
}
|
||||||
92
configs/moodle-dl/meinhark.nix
Normal file
@@ -0,0 +1,92 @@
|
|||||||
|
{ config, pkgs, lib, ... }:
|
||||||
|
let
|
||||||
|
moodle-dl-package = pkgs.moodle-dl.overrideAttrs (old: old // {
|
||||||
|
patches = [ <niveum/packages/moodle-dl/telegram-format.patch> ];
|
||||||
|
});
|
||||||
|
in
|
||||||
|
{
|
||||||
|
imports = [ <niveum/modules/moodle-dl.nix> ];
|
||||||
|
|
||||||
|
services.moodle-dl = {
|
||||||
|
enable = true;
|
||||||
|
startAt = "hourly";
|
||||||
|
package = moodle-dl-package;
|
||||||
|
settings = {
|
||||||
|
telegram = {
|
||||||
|
token = lib.strings.fileContents <system-secrets/telegram/moodle-dl.token>;
|
||||||
|
chat_id = "18980945";
|
||||||
|
send_error_msg = false;
|
||||||
|
};
|
||||||
|
token = lib.strings.fileContents <system-secrets/moodle.token>;
|
||||||
|
moodle_domain = "moodle.hu-berlin.de";
|
||||||
|
moodle_path = "/";
|
||||||
|
download_course_ids = [
|
||||||
|
# WS 2020
|
||||||
|
99881 # Dialektologie
|
||||||
|
100183 # Onomastik
|
||||||
|
100353 # Sanskrit I
|
||||||
|
100692 # Sanskrit Tutorium
|
||||||
|
99832 # Germanisch
|
||||||
|
99823 # Gotisch
|
||||||
|
99813 # Altalbanisch
|
||||||
|
98681 # Geistliche Lyrik von Luther bis Lehnert
|
||||||
|
99667 # Antike Mythologie
|
||||||
|
# 52365 # FSR KlassPhil
|
||||||
|
|
||||||
|
# SS 2021
|
||||||
|
104850 # Metrik
|
||||||
|
103274 # Marc Aurel
|
||||||
|
102909 # Sanskrit II
|
||||||
|
104937 # Altirisch
|
||||||
|
104925 # Gradierung und Komparation
|
||||||
|
105264 # Was andere Sprachen anders machen
|
||||||
|
104991 # Warum klingt Orkisch böse
|
||||||
|
105074 # Litauisch
|
||||||
|
103685 # Griechische Sprache und Übersetzung I
|
||||||
|
105455 # Elegia greca
|
||||||
|
105335 # Homerische Epen
|
||||||
|
|
||||||
|
# WS 2021
|
||||||
|
108122 # Griechisch
|
||||||
|
107986 # Altostslavisch
|
||||||
|
107792 # Elegie in Rom
|
||||||
|
107369 # Tusculanae Disputationes
|
||||||
|
108586 # Griechische Religion
|
||||||
|
107988 # Balkanindogermanisch
|
||||||
|
108312 # Altnordisch
|
||||||
|
107281 # NLP
|
||||||
|
108736 # Grammatiktheorie
|
||||||
|
109438 # Warum klingt Orkisch böse
|
||||||
|
108025 # Poetik der Nordgermanen
|
||||||
|
107280 # Statistik
|
||||||
|
108350 # Attische Redner
|
||||||
|
107461 # Argonautika
|
||||||
|
108283 # Digital Classicist
|
||||||
|
109211 # Altlitauisch
|
||||||
|
109185 # Etymologie
|
||||||
|
];
|
||||||
|
download_submissions = true;
|
||||||
|
download_descriptions = true;
|
||||||
|
download_links_in_descriptions = false;
|
||||||
|
download_databases = false;
|
||||||
|
download_forums = false;
|
||||||
|
download_linked_files = false;
|
||||||
|
download_also_with_cookie = false;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
fileSystems."/export/moodle" = {
|
||||||
|
device = config.services.moodle-dl.directory;
|
||||||
|
options = [ "bind" ];
|
||||||
|
};
|
||||||
|
|
||||||
|
networking.firewall.allowedTCPPorts = [ 2049 ];
|
||||||
|
|
||||||
|
services.nfs.server = {
|
||||||
|
enable = true;
|
||||||
|
exports = let machines = with (import <niveum/lib>).retiolumAddresses; [kabsa manakish]; in ''
|
||||||
|
/export ${lib.concatMapStringsSep " " (machine: "${machine.ipv4}(fsid=0)") machines}
|
||||||
|
/export/moodle ${lib.concatMapStringsSep " " (machine: "${machine.ipv4}(insecure,rw)") machines}
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
}
|
||||||
@@ -1,30 +0,0 @@
|
|||||||
{ pkgs, ... }:
|
|
||||||
let secrets = import <dot/secrets.nix>;
|
|
||||||
in {
|
|
||||||
services.mopidy = {
|
|
||||||
enable = true;
|
|
||||||
extensionPackages = [
|
|
||||||
pkgs.mopidy-gmusic
|
|
||||||
pkgs.mopidy-iris
|
|
||||||
pkgs.mopidy-moped
|
|
||||||
pkgs.mopidy-mopify
|
|
||||||
pkgs.mopidy-soundcloud
|
|
||||||
pkgs.mopidy-spotify
|
|
||||||
pkgs.mopidy-spotify-tunigo
|
|
||||||
pkgs.mopidy-youtube
|
|
||||||
];
|
|
||||||
configuration = ''
|
|
||||||
[mpd]
|
|
||||||
hostname = ::
|
|
||||||
|
|
||||||
[spotify]
|
|
||||||
username = ${secrets.spotify.username}
|
|
||||||
password = ${secrets.spotify.password}
|
|
||||||
client_id = ${secrets.spotify.clientId}
|
|
||||||
client_secret = ${secrets.spotify.clientSecret}
|
|
||||||
|
|
||||||
[soundcloud]
|
|
||||||
auth_token = ${secrets.soundcloud.authToken}
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
}
|
|
||||||
@@ -1,17 +1,29 @@
|
|||||||
{ pkgs, ... }:
|
{ pkgs, lib, ... }: let
|
||||||
{
|
swallow = command: "${pkgs.scripts.swallow}/bin/swallow ${command}";
|
||||||
environment.systemPackages = [ pkgs.mpv pkgs.mpv-poll ];
|
nixpkgs-unstable = import <nixpkgs-unstable> { config.allowUnfree = true; };
|
||||||
|
in {
|
||||||
|
environment.shellAliases.smpv = swallow "mpv";
|
||||||
|
|
||||||
home-manager.users.me.xdg.configFile = {
|
home-manager.users.me = {
|
||||||
"mpv/input.conf".text = ''
|
programs.mpv = {
|
||||||
Alt+RIGHT add video-rotate 90
|
enable = true;
|
||||||
Alt+LEFT add video-rotate -90
|
config = {
|
||||||
Alt+- add video-zoom -0.25
|
ytdl-raw-options = lib.concatStringsSep "," [ ''sub-lang="de,en"'' "write-sub=" "write-auto-sub=" ];
|
||||||
Alt+= add video-zoom 0.25
|
screenshot-template = "%F-%wH%wM%wS-%#04n";
|
||||||
Alt+l add video-pan-x -0.05
|
};
|
||||||
Alt+h add video-pan-x 0.05
|
bindings = {
|
||||||
Alt+k add video-pan-y 0.05
|
"Alt+RIGHT" = "add video-rotate 90";
|
||||||
Alt+j add video-pan-y -0.05
|
"Alt+LEFT" = "add video-rotate -90";
|
||||||
'';
|
"Alt+-" = "add video-zoom -0.25";
|
||||||
|
"Alt+=" = "add video-zoom 0.25";
|
||||||
|
"Alt+l" = "add video-pan-x -0.05";
|
||||||
|
"Alt+h" = "add video-pan-x 0.05";
|
||||||
|
"Alt+k" = "add video-pan-y 0.05";
|
||||||
|
"Alt+j" = "add video-pan-y -0.05";
|
||||||
|
};
|
||||||
|
scripts = [
|
||||||
|
nixpkgs-unstable.mpvScripts.youtube-quality
|
||||||
|
];
|
||||||
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
38
configs/names.nix
Normal file
@@ -0,0 +1,38 @@
|
|||||||
|
{ pkgs, lib, ... }:
|
||||||
|
let
|
||||||
|
port = 5703;
|
||||||
|
geogen = (pkgs.fetchFromGitHub {
|
||||||
|
owner = "kmein";
|
||||||
|
repo = "scripts";
|
||||||
|
rev = "c553c212efb04c300edf675c39a87fffd32d4def";
|
||||||
|
sha256 = "0b5xjr7qqgvwc76pqr84p81svzk6nqr5pdvc6daw94rcgdy02mva";
|
||||||
|
}) + "/onomastics";
|
||||||
|
inherit (pkgs.callPackage geogen {}) dependencyEnv;
|
||||||
|
in
|
||||||
|
{
|
||||||
|
systemd.services.names = {
|
||||||
|
wants = [ "network-online.target" ];
|
||||||
|
wantedBy = [ "multi-user.target" ];
|
||||||
|
description = "Better clone of geogen.stoepel.net";
|
||||||
|
serviceConfig = {
|
||||||
|
DynamicUser = true;
|
||||||
|
};
|
||||||
|
script = ''
|
||||||
|
cd $(mktemp -d)
|
||||||
|
ln -s "${geogen}/wsgi.py" wsgi.py
|
||||||
|
${dependencyEnv}/bin/gunicorn wsgi:app -b :${toString port}
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
|
||||||
|
services.nginx = {
|
||||||
|
enable = true;
|
||||||
|
recommendedGzipSettings = true;
|
||||||
|
recommendedOptimisation = true;
|
||||||
|
recommendedProxySettings = true;
|
||||||
|
recommendedTlsSettings = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
services.nginx.virtualHosts."names.kmein.r" = {
|
||||||
|
locations."/".proxyPass = "http://127.0.0.1:${toString port}";
|
||||||
|
};
|
||||||
|
}
|
||||||
248
configs/neomutt.nix
Normal file
@@ -0,0 +1,248 @@
|
|||||||
|
{ pkgs, lib, ... }:
|
||||||
|
let
|
||||||
|
mainMailbox = "posteo";
|
||||||
|
|
||||||
|
accounts.uni = {
|
||||||
|
user = "meinhark";
|
||||||
|
password = lib.strings.fileContents <secrets/eduroam/password>;
|
||||||
|
address = "kieran.felix.meinhardt@hu-berlin.de";
|
||||||
|
imap = "mailbox.cms.hu-berlin.de";
|
||||||
|
smtp = "mailhost.cms.hu-berlin.de";
|
||||||
|
smtpSettings = smtp: "smtp://${smtp}";
|
||||||
|
folders = {
|
||||||
|
drafts = "Drafts";
|
||||||
|
sent = "Sent";
|
||||||
|
trash = "Trash";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
accounts.uni-old = {
|
||||||
|
user = "meinhark";
|
||||||
|
password = lib.strings.fileContents <secrets/eduroam/password>;
|
||||||
|
address = "meinhark@informatik.hu-berlin.de";
|
||||||
|
imap = "mailbox.informatik.hu-berlin.de";
|
||||||
|
smtp = "mailhost.informatik.hu-berlin.de";
|
||||||
|
smtpSettings = smtp: "smtp://${smtp}";
|
||||||
|
folders = {
|
||||||
|
drafts = "Drafts";
|
||||||
|
sent = "Sent";
|
||||||
|
trash = "Trash";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
accounts.work-uni = {
|
||||||
|
user = "meinhaki";
|
||||||
|
password = lib.strings.fileContents <secrets/mail/meinhaki>;
|
||||||
|
address = "kieran.meinhardt@hu-berlin.de";
|
||||||
|
imap = "mailbox.cms.hu-berlin.de";
|
||||||
|
smtp = "mailhost.cms.hu-berlin.de";
|
||||||
|
smtpSettings = smtp: "smtp://${smtp}";
|
||||||
|
folders = {
|
||||||
|
drafts = "Drafts";
|
||||||
|
sent = "Sent";
|
||||||
|
trash = "Trash";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
accounts.work-fysi = rec {
|
||||||
|
user = "kieran@fysi.tech";
|
||||||
|
address = user;
|
||||||
|
password = lib.strings.fileContents <secrets/mail/fastmail>;
|
||||||
|
imap = "imap.fastmail.com";
|
||||||
|
smtp = "smtp.fastmail.com";
|
||||||
|
smtpSettings = smtp: "smtps://${smtp}:465";
|
||||||
|
folders = {
|
||||||
|
drafts = "Drafts";
|
||||||
|
sent = "Sent";
|
||||||
|
trash = "Trash";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
accounts.cock = rec {
|
||||||
|
user = "2210@cock.li";
|
||||||
|
address = user;
|
||||||
|
password = lib.strings.fileContents <secrets/mail/cock>;
|
||||||
|
imap = "mail.cock.li";
|
||||||
|
smtp = imap;
|
||||||
|
smtpSettings = smtp: "smtp://${smtp}:587";
|
||||||
|
folders = {
|
||||||
|
drafts = "Drafts";
|
||||||
|
sent = "Sent";
|
||||||
|
trash = "Trash";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
accounts."${mainMailbox}" = rec {
|
||||||
|
user = "kieran.meinhardt@posteo.net";
|
||||||
|
address = user;
|
||||||
|
password = lib.strings.fileContents <secrets/mail/posteo>;
|
||||||
|
imap = "posteo.de";
|
||||||
|
smtp = imap;
|
||||||
|
smtpSettings = smtp: "smtp://${smtp}";
|
||||||
|
folders = {
|
||||||
|
drafts = "Drafts";
|
||||||
|
sent = "Sent";
|
||||||
|
trash = "Trash";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
accounts.google-amro = rec {
|
||||||
|
user = "amroplay@gmail.com";
|
||||||
|
address = user;
|
||||||
|
password = lib.strings.fileContents <secrets/mail/gmail/amroplay>;
|
||||||
|
imap = "imap.gmail.com";
|
||||||
|
smtp = "smtp.gmail.com";
|
||||||
|
smtpSettings = smtp: "smtps://${smtp}:465";
|
||||||
|
folders = {
|
||||||
|
drafts = "[Gmail]/Drafts";
|
||||||
|
sent = "[Gmail]/Sent Mail";
|
||||||
|
trash = "[Gmail]/Bin";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
accounts.google-kieran = rec {
|
||||||
|
user = "kieran.meinhardt@gmail.com";
|
||||||
|
address = user;
|
||||||
|
password = lib.strings.fileContents <secrets/mail/gmail/kieran.meinhardt>;
|
||||||
|
imap = "imap.gmail.com";
|
||||||
|
smtp = "smtp.gmail.com";
|
||||||
|
smtpSettings = smtp: "smtps://${smtp}:465";
|
||||||
|
folders = {
|
||||||
|
drafts = "[Gmail]/Entwürfe";
|
||||||
|
sent = "[Gmail]/Gesendet";
|
||||||
|
trash = "[Gmail]/Papierkorb";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
in
|
||||||
|
{
|
||||||
|
environment.systemPackages = [ pkgs.neomutt ];
|
||||||
|
environment.shellAliases.mua = "${pkgs.neomutt}/bin/neomutt -f ${mainMailbox}←";
|
||||||
|
|
||||||
|
home-manager.users.me.xdg.configFile."neomutt/neomuttrc".text = ''
|
||||||
|
set mailcap_path = ${pkgs.writeText "mailcap" ''
|
||||||
|
text/plain; $EDITOR %s ;
|
||||||
|
text/html; ${pkgs.lynx}/bin/lynx -assume_charset=%{charset} -display_charset=utf-8 -dump %s; nametemplate=%s.html; copiousoutput;
|
||||||
|
image/*; ${pkgs.sxiv}/bin/sxiv %s ;
|
||||||
|
video/*; ${pkgs.utillinux}/bin/setsid ${pkgs.mpv}/bin/mpv --quiet %s &; copiousoutput
|
||||||
|
audio/*; ${pkgs.mpv}/bin/mpv %s ;
|
||||||
|
application/pdf; ${pkgs.zathura}/bin/zathura %s ;
|
||||||
|
application/pgp-encrypted; ${pkgs.gnupg}/bin/gpg -d '%s'; copiousoutput;
|
||||||
|
application/pgp-keys; ${pkgs.gnupg}/bin/gpg --import '%s'; copiousoutput;
|
||||||
|
''}:$mailcap_path
|
||||||
|
|
||||||
|
set sidebar_visible
|
||||||
|
set sidebar_format = "%D%?F? [%F]?%* %?N?%N/?%S"
|
||||||
|
set sidebar_width = 25 # Plenty of space
|
||||||
|
set sidebar_divider_char = '│' # Pretty line-drawing character
|
||||||
|
set mail_check_stats
|
||||||
|
|
||||||
|
set index_format="%2C %Z %D %-15.15L %s"
|
||||||
|
set date_format="%F %R"
|
||||||
|
|
||||||
|
set sort = 'reverse-date'
|
||||||
|
set sleep_time = 0 # Pause 0 seconds for informational messages
|
||||||
|
set markers = no # Disables the `+` displayed at line wraps
|
||||||
|
set mark_old = no # Unread mail stay unread until read
|
||||||
|
set wait_key = no # mutt won't ask "press key to continue"
|
||||||
|
set fast_reply # skip to compose when replying
|
||||||
|
set forward_format = "Fwd: %s" # format of subject when forwarding
|
||||||
|
set reverse_name # reply as whomever it was to
|
||||||
|
set include=ask-no # don't include message in replies
|
||||||
|
auto_view text/html # automatically show html (mailcap uses lynx)
|
||||||
|
auto_view application/pgp-encrypted
|
||||||
|
alternative_order text/plain text/enriched text/html
|
||||||
|
|
||||||
|
set abort_noattach abort_noattach_regex="\<(attach|attached|attachments?|anbei|Anhang|angehängt)\>"
|
||||||
|
set attach_save_dir=/tmp
|
||||||
|
set fast_reply
|
||||||
|
|
||||||
|
set narrow_tree # narrow threads for more depth
|
||||||
|
|
||||||
|
bind index,pager B sidebar-toggle-visible # Use 'B' to switch the Sidebar on and off
|
||||||
|
bind index,pager \Ck sidebar-prev
|
||||||
|
bind index,pager \Cj sidebar-next
|
||||||
|
bind index,pager \Co sidebar-open
|
||||||
|
bind index,pager \Cp sidebar-prev-new
|
||||||
|
bind index,pager \Cn sidebar-next-new
|
||||||
|
|
||||||
|
macro index * <limit>~F\r
|
||||||
|
macro index + <limit>all\r
|
||||||
|
|
||||||
|
set query_command = "khard email --parsable %s"
|
||||||
|
bind editor <Tab> complete-query
|
||||||
|
bind editor ^T complete
|
||||||
|
|
||||||
|
set mail_check = 90
|
||||||
|
set timeout = 15
|
||||||
|
# set imap_check_subscribed
|
||||||
|
set use_from
|
||||||
|
|
||||||
|
|
||||||
|
set header_cache="~/.cache/mutt" message_cachedir="~/.cache/mutt"
|
||||||
|
|
||||||
|
source ${pkgs.writeText "accounts.neomuttrc" ''
|
||||||
|
set realname = "Kierán Meinhardt"
|
||||||
|
account-hook . 'unset imap_user imap_pass smtp_user smtp_pass'
|
||||||
|
# set accordingly: postponed trash record
|
||||||
|
${lib.concatStringsSep "\n\n" (lib.mapAttrsToList (name: account: let imapRoot = "imaps://${account.user}@${account.imap}"; in ''
|
||||||
|
account-hook ${account.user}@${account.imap} 'set imap_user="${account.user}" imap_pass="${account.password}"'
|
||||||
|
account-hook ${account.user}@${account.smtp} 'set smtp_user="${account.user}" smtp_pass="${account.password}"'
|
||||||
|
folder-hook ${account.user}@${account.imap} 'set smtp_url="${account.smtpSettings "${account.user}@${account.smtp}"}" from="${account.address}" record="${imapRoot}/${account.folders.sent}" postponed="${imapRoot}/${account.folders.drafts}" trash="${imapRoot}/${account.folders.trash}"'
|
||||||
|
named-mailboxes "${name}←" "${imapRoot}" "${name}→" "${imapRoot}/${account.folders.sent}"
|
||||||
|
'') accounts)}
|
||||||
|
''}
|
||||||
|
|
||||||
|
set spoolfile="${mainMailbox}"
|
||||||
|
|
||||||
|
source ${pkgs.writeText "colors.neomuttrc" ''
|
||||||
|
# Default index colors:
|
||||||
|
color index_number blue default
|
||||||
|
color index red default '.*'
|
||||||
|
color index_flags lightcyan default '.*'
|
||||||
|
color index_author yellow default '.*'
|
||||||
|
color index_subject lightblack default '.*'
|
||||||
|
|
||||||
|
# New mail is boldened:
|
||||||
|
color index_author lightyellow black "~N"
|
||||||
|
color index_subject lightwhite black "~N"
|
||||||
|
|
||||||
|
# Flagged mail is highlighted:
|
||||||
|
color index_flags lightmagenta default '~F'
|
||||||
|
|
||||||
|
# Other colors and aesthetic settings:
|
||||||
|
mono bold bold
|
||||||
|
mono underline underline
|
||||||
|
mono error bold
|
||||||
|
mono indicator reverse
|
||||||
|
# color sidebar_flagged red black
|
||||||
|
mono sidebar_new bold
|
||||||
|
color error red default
|
||||||
|
color message cyan default
|
||||||
|
color search brightmagenta default
|
||||||
|
color hdrdefault lightblack default
|
||||||
|
color quoted green default
|
||||||
|
color quoted1 blue default
|
||||||
|
color quoted2 cyan default
|
||||||
|
color quoted3 yellow default
|
||||||
|
color quoted4 red default
|
||||||
|
color quoted5 brightred default
|
||||||
|
color signature lightblack default
|
||||||
|
color tree color235 default
|
||||||
|
|
||||||
|
# Regex highlighting:
|
||||||
|
color header red default "^(Date)"
|
||||||
|
color header yellow default "^(From)"
|
||||||
|
color header white default "^(B?CC)"
|
||||||
|
color header brightwhite default "^(Subject)"
|
||||||
|
color body cyan default "[\-\.+_a-zA-Z0-9]+@[\-\.a-zA-Z0-9]+" # Email addresses
|
||||||
|
color body brightblue default "(https?|ftp)://[\-\.,/%~_:?&=\#a-zA-Z0-9]+" # URL
|
||||||
|
color body yellow default "^(\t| )*(-|\\*) \.*" # List items as yellow
|
||||||
|
color body red default "(BAD signature)|^gpg: BAD signature from.*"
|
||||||
|
color body brightgreen default "(Good signature)|^gpg: Good signature .*"
|
||||||
|
color body brightyellow default "^gpg: "
|
||||||
|
mono body bold "^gpg: Good signature"
|
||||||
|
mono body bold "^gpg: BAD signature from.*"
|
||||||
|
color body red default "([a-z][a-z0-9+-]*://(((([a-z0-9_.!~*'();:&=+$,-]|%[0-9a-f][0-9a-f])*@)?((([a-z0-9]([a-z0-9-]*[a-z0-9])?)\\.)*([a-z]([a-z0-9-]*[a-z0-9])?)\\.?|[0-9]+\\.[0-9]+\\.[0-9]+\\.[0-9]+)(:[0-9]+)?)|([a-z0-9_.!~*'()$,;:@&=+-]|%[0-9a-f][0-9a-f])+)(/([a-z0-9_.!~*'():@&=+$,-]|%[0-9a-f][0-9a-f])*(;([a-z0-9_.!~*'():@&=+$,-]|%[0-9a-f][0-9a-f])*)*(/([a-z0-9_.!~*'():@&=+$,-]|%[0-9a-f][0-9a-f])*(;([a-z0-9_.!~*'():@&=+$,-]|%[0-9a-f][0-9a-f])*)*)*)?(\\?([a-z0-9_.!~*'();/?:@&=+$,-]|%[0-9a-f][0-9a-f])*)?(#([a-z0-9_.!~*'();/?:@&=+$,-]|%[0-9a-f][0-9a-f])*)?|(www|ftp)\\.(([a-z0-9]([a-z0-9-]*[a-z0-9])?)\\.)*([a-z]([a-z0-9-]*[a-z0-9])?)\\.?(:[0-9]+)?(/([-a-z0-9_.!~*'():@&=+$,]|%[0-9a-f][0-9a-f])*(;([-a-z0-9_.!~*'():@&=+$,]|%[0-9a-f][0-9a-f])*)*(/([-a-z0-9_.!~*'():@&=+$,]|%[0-9a-f][0-9a-f])*(;([-a-z0-9_.!~*'():@&=+$,]|%[0-9a-f][0-9a-f])*)*)*)?(\\?([-a-z0-9_.!~*'();/?:@&=+$,]|%[0-9a-f][0-9a-f])*)?(#([-a-z0-9_.!~*'();/?:@&=+$,]|%[0-9a-f][0-9a-f])*)?)[^].,:;!)? \t\r\n<>\"]"
|
||||||
|
''}
|
||||||
|
'';
|
||||||
|
}
|
||||||
@@ -1,109 +1,77 @@
|
|||||||
{ pkgs, ... }:
|
{ pkgs, ... }: {
|
||||||
{
|
|
||||||
environment.variables.EDITOR = pkgs.lib.mkForce "nvim";
|
environment.variables.EDITOR = pkgs.lib.mkForce "nvim";
|
||||||
environment.shellAliases.vi = "nvim";
|
environment.shellAliases.vi = "nvim";
|
||||||
environment.shellAliases.vim = "nvim";
|
environment.shellAliases.vim = "nvim";
|
||||||
environment.shellAliases.view = "nvim -R";
|
environment.shellAliases.view = "nvim -R";
|
||||||
|
|
||||||
|
nixpkgs.config.packageOverrides = pkgs: {
|
||||||
|
vimPlugins = pkgs.vimPlugins // {
|
||||||
|
cheat-sh-vim = pkgs.callPackage <niveum/packages/vimPlugins/cheat-sh.nix> { };
|
||||||
|
vim-fetch = pkgs.callPackage <niveum/packages/vimPlugins/vim-fetch.nix> { };
|
||||||
|
vim-colors-paramount = pkgs.callPackage <niveum/packages/vimPlugins/vim-colors-paramount.nix> { };
|
||||||
|
vim-256noir = pkgs.callPackage <niveum/packages/vimPlugins/vim-256noir.nix> { };
|
||||||
|
icalendar-vim = pkgs.callPackage <niveum/packages/vimPlugins/icalendar-vim.nix> { };
|
||||||
|
jq-vim = pkgs.callPackage <niveum/packages/vimPlugins/jq-vim.nix> { };
|
||||||
|
vim-fsharp = pkgs.callPackage <niveum/packages/vimPlugins/vim-fsharp.nix> { };
|
||||||
|
vim-reason-plus = pkgs.callPackage <niveum/packages/vimPlugins/vim-reason-plus.nix> { };
|
||||||
|
vim-mail = pkgs.callPackage <niveum/packages/vimPlugins/vim-mail.nix> { };
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
environment.systemPackages = [
|
environment.systemPackages = [
|
||||||
|
(pkgs.writers.writeDashBin "vim" ''neovim "$@"'')
|
||||||
(pkgs.neovim.override {
|
(pkgs.neovim.override {
|
||||||
configure = {
|
configure = {
|
||||||
customRC = builtins.readFile <dot/vimrc>;
|
customRC = builtins.readFile <niveum/lib/vim/init.vim>;
|
||||||
packages.nvim = with pkgs.vimPlugins; {
|
packages.nvim = with pkgs.vimPlugins; {
|
||||||
start = with pkgs.vimPlugins; [
|
start = [
|
||||||
|
# cheat-sh-vim
|
||||||
|
# deoplete-nvim
|
||||||
|
# vim-abolish
|
||||||
ale
|
ale
|
||||||
deoplete-nvim
|
|
||||||
fzf-vim
|
fzf-vim
|
||||||
fzfWrapper
|
fzfWrapper
|
||||||
|
goyo
|
||||||
supertab
|
supertab
|
||||||
|
undotree
|
||||||
tabular
|
tabular
|
||||||
vim-abolish
|
vimwiki
|
||||||
|
vim-256noir
|
||||||
|
vim-colors-paramount
|
||||||
vim-commentary
|
vim-commentary
|
||||||
|
vim-css-color
|
||||||
vim-eunuch
|
vim-eunuch
|
||||||
|
vim-fetch
|
||||||
vim-fugitive
|
vim-fugitive
|
||||||
vim-gitgutter
|
vim-gitgutter
|
||||||
vim-pandoc vim-pandoc-after vim-pandoc-syntax
|
vim-pandoc
|
||||||
|
vim-pandoc-syntax # vim-pandoc-after
|
||||||
vim-repeat
|
vim-repeat
|
||||||
vim-sensible
|
vim-sensible
|
||||||
vim-startify
|
# vim-startify
|
||||||
vim-surround
|
vim-surround
|
||||||
(pkgs.vimUtils.buildVimPluginFrom2Nix rec {
|
vim-mail
|
||||||
name = "vim-fetch";
|
|
||||||
src = pkgs.fetchFromGitHub {
|
|
||||||
owner = "wsdjeg";
|
|
||||||
repo = "vim-fetch";
|
|
||||||
rev = "76c08586e15e42055c9c21321d9fca0677442ecc";
|
|
||||||
sha256 = "0avcqjcqvxgj00r477ps54rjrwvmk5ygqm3qrzghbj9m1gpyp2kz";
|
|
||||||
};
|
|
||||||
})
|
|
||||||
(pkgs.vimUtils.buildVimPluginFrom2Nix rec {
|
|
||||||
name = "vim-colors-paramount";
|
|
||||||
src = pkgs.fetchFromGitHub {
|
|
||||||
owner = "owickstrom";
|
|
||||||
repo = "vim-colors-paramount";
|
|
||||||
rev = "a5601d36fb6932e8d1a6f8b37b179a99b1456798";
|
|
||||||
sha256 = "0rjn9vjb0xrxbiqyfclda2ridcbl3nfn4svs32mvmv8als6crncg";
|
|
||||||
};
|
|
||||||
})
|
|
||||||
(pkgs.vimUtils.buildVimPluginFrom2Nix {
|
|
||||||
name = "vim-256noir";
|
|
||||||
src = pkgs.fetchFromGitHub {
|
|
||||||
owner = "andreasvc";
|
|
||||||
repo = "vim-256noir";
|
|
||||||
rev = "e8668a18a4a90272c1cae87e655f8bddc5ac3665";
|
|
||||||
sha256 = "1kpn379f5dgbsgb73g6d1nlmz9vz0j3ihi500mcdx4yg56fvkr0x";
|
|
||||||
};
|
|
||||||
})
|
|
||||||
];
|
];
|
||||||
opt = [
|
opt = [
|
||||||
csv
|
csv
|
||||||
dhall-vim
|
dhall-vim
|
||||||
elm-vim
|
elm-vim
|
||||||
|
emmet-vim
|
||||||
haskell-vim
|
haskell-vim
|
||||||
|
icalendar-vim
|
||||||
idris-vim
|
idris-vim
|
||||||
|
nim-vim
|
||||||
|
jq-vim
|
||||||
|
purescript-vim
|
||||||
rust-vim
|
rust-vim
|
||||||
typescript-vim
|
typescript-vim
|
||||||
|
vim-fsharp
|
||||||
vim-javascript
|
vim-javascript
|
||||||
|
vim-ledger
|
||||||
vim-nix
|
vim-nix
|
||||||
|
vim-reason-plus
|
||||||
vim-toml
|
vim-toml
|
||||||
vimtex
|
vimtex
|
||||||
vim-ledger
|
|
||||||
(pkgs.vimUtils.buildVimPluginFrom2Nix {
|
|
||||||
name = "todo.txt-vim";
|
|
||||||
src = pkgs.fetchFromGitHub {
|
|
||||||
owner = "freitass";
|
|
||||||
repo = "todo.txt-vim";
|
|
||||||
rev = "6845221d45bd62e604c2024bc511a56e79d1118b";
|
|
||||||
sha256 = "08m9q5f2pz6gjp0vkmm7glfsrbnldxi1j59dm5d7any6y96xxd6v";
|
|
||||||
};
|
|
||||||
})
|
|
||||||
(pkgs.vimUtils.buildVimPluginFrom2Nix {
|
|
||||||
name = "jq.vim";
|
|
||||||
src = pkgs.fetchFromGitHub {
|
|
||||||
owner = "vito-c";
|
|
||||||
repo = "jq.vim";
|
|
||||||
rev = "5baf8ed192cf267d30b84e3243d9aab3d4912e60";
|
|
||||||
sha256 = "1ykaxlli7b9wmhr8lpdalqxh7l4940jwhwm9pwlraga425h4r6z4";
|
|
||||||
};
|
|
||||||
})
|
|
||||||
(pkgs.vimUtils.buildVimPluginFrom2Nix {
|
|
||||||
name = "vim-fsharp";
|
|
||||||
src = pkgs.fetchFromGitHub {
|
|
||||||
owner = "fsharp";
|
|
||||||
repo = "vim-fsharp";
|
|
||||||
rev = "627db7d701747e8fd7924b6505c61e16a369fb72";
|
|
||||||
sha256 = "00hhgn2p54faysx1ddccyhl9jnvddgxsczhv0np3mgzza6ls4838";
|
|
||||||
};
|
|
||||||
})
|
|
||||||
(pkgs.vimUtils.buildVimPluginFrom2Nix {
|
|
||||||
name = "emmet-vim";
|
|
||||||
src = pkgs.fetchFromGitHub {
|
|
||||||
owner = "mattn";
|
|
||||||
repo = "emmet-vim";
|
|
||||||
rev = "d698f1658770ca5fa58c87e80421c8d65bbe9065";
|
|
||||||
sha256 = "0vl4267hh8g1vkvc3awlqyypgz4m1r43d47sldl80yamiafiviaj";
|
|
||||||
};
|
|
||||||
})
|
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|||||||
104
configs/networkmanager.nix
Normal file
@@ -0,0 +1,104 @@
|
|||||||
|
{ lib, pkgs, ... }:
|
||||||
|
let
|
||||||
|
autowifi = pkgs.writers.writePython3Bin "autowifi" { flakeIgnore = [ "E501" ]; } <stockholm/lass/5pkgs/autowifi/autowifi.py>;
|
||||||
|
profile = name: custom: lib.recursiveUpdate {
|
||||||
|
connection.id = name;
|
||||||
|
connection.type = "wifi";
|
||||||
|
connection.interface-name = "wlp3s0";
|
||||||
|
connection.permissions = "";
|
||||||
|
wifi.mac-address-blacklist = "";
|
||||||
|
wifi.ssid = name;
|
||||||
|
wifi.mode = "infrastructure";
|
||||||
|
ipv4.dns-search = "";
|
||||||
|
ipv4.method = "auto";
|
||||||
|
ipv6.addr-gen-mode = "stable-privacy";
|
||||||
|
ipv6.dns-search = "";
|
||||||
|
ipv6.method = "auto";
|
||||||
|
proxy = {};
|
||||||
|
} custom;
|
||||||
|
eduroamProfile = {
|
||||||
|
connection.uuid = "eae9fee6-a7d2-4120-a609-440b457d6fcf";
|
||||||
|
wifi-security = {
|
||||||
|
group = "ccmp;tkip;";
|
||||||
|
key-mgmt = "wpa-eap";
|
||||||
|
pairwise = "ccmp;";
|
||||||
|
proto = "rsn;";
|
||||||
|
};
|
||||||
|
"802-1x" = {
|
||||||
|
altsubject-matches = "DNS:srv1-radius.cms.hu-berlin.de;DNS:srv2-radius.cms.hu-berlin.de;";
|
||||||
|
anonymous-identity = "anonymous@wlan.hu-berlin.de";
|
||||||
|
ca-cert = pkgs.fetchurl {
|
||||||
|
url = "https://www.cms.hu-berlin.de/de/dl/netze/wlan/config/eduroam/t-telesec_globalroot_class_2.pem";
|
||||||
|
sha256 = "0if8aqd06sid7a0vw009zpa087wxcgdd2x6z2zs4pis5kvyqj2dk";
|
||||||
|
};
|
||||||
|
eap = "ttls;";
|
||||||
|
identity = lib.strings.fileContents <secrets/eduroam/identity>;
|
||||||
|
password = lib.strings.fileContents <secrets/eduroam/password>;
|
||||||
|
phase2-auth = "pap";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
in
|
||||||
|
{
|
||||||
|
imports = [ <niveum/modules/networkmanager-declarative.nix> ];
|
||||||
|
|
||||||
|
networking.networkmanager = {
|
||||||
|
enable = true;
|
||||||
|
wifi.macAddress = "random";
|
||||||
|
ethernet.macAddress = "random";
|
||||||
|
unmanaged = [ "docker*" ];
|
||||||
|
profiles = lib.mapAttrs profile {
|
||||||
|
Aether = {
|
||||||
|
connection.uuid = "7138bb0f-1aeb-4905-890e-a6628427aa21";
|
||||||
|
ipv6.addr-gen-mode = "stable";
|
||||||
|
wifi.cloned-mac-address = "stable";
|
||||||
|
wifi-security = {
|
||||||
|
psk = lib.strings.fileContents <secrets/wifi/Aether.psk>;
|
||||||
|
auth-alg = "open";
|
||||||
|
key-mgmt = "wpa-psk";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
FactoryCommunityGuest = {
|
||||||
|
connection.uuid = "fb1f2e52-651e-48b5-a72c-1accddf31afb";
|
||||||
|
connection.timestamp = "1631885129";
|
||||||
|
wifi.seen-bssids = "54:EC:2F:19:30:DC;54:EC:2F:19:5C:9C;54:EC:2F:58:E4:3C;";
|
||||||
|
wifi-security = {
|
||||||
|
psk = "Factory4ever";
|
||||||
|
auth-alg = "open";
|
||||||
|
key-mgmt = "wpa-psk";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
o2-WLAN66 = {
|
||||||
|
connection.uuid = "c563aec3-f344-4ffb-8d1c-60a6cdac8fe0";
|
||||||
|
wifi-security = {
|
||||||
|
psk = "PK3468KV488T934U";
|
||||||
|
auth-alg = "open";
|
||||||
|
key-mgmt = "wpa-psk";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
"WIFI@DB".connection.uuid = "4eff4e94-8850-4e9f-a338-1787d0d90479";
|
||||||
|
eduroam = eduroamProfile;
|
||||||
|
eduroam_5GHz = eduroamProfile;
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
users.users.me.extraGroups = [ "networkmanager" ];
|
||||||
|
|
||||||
|
systemd.services.autowifi = {
|
||||||
|
enable = false;
|
||||||
|
description = "Automatic wifi connector";
|
||||||
|
wantedBy = [ "multi-user.target" ];
|
||||||
|
path = [ pkgs.networkmanager ];
|
||||||
|
serviceConfig = {
|
||||||
|
Type = "simple";
|
||||||
|
Restart = "always";
|
||||||
|
RestartSec = "10s";
|
||||||
|
ExecStart = "${autowifi}/bin/autowifi";
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
networking.networkmanager.dispatcherScripts = [
|
||||||
|
{ source = "${pkgs.nur.repos.makefu.prison-break}/bin/prison-break"; }
|
||||||
|
];
|
||||||
|
|
||||||
|
environment.systemPackages = [ pkgs.speedtest-cli ];
|
||||||
|
}
|
||||||
81
configs/newsboat.nix
Normal file
@@ -0,0 +1,81 @@
|
|||||||
|
{ pkgs, config, ... }:
|
||||||
|
let
|
||||||
|
ytdl-format = "'bestvideo[height<=?720][fps<=?30][vcodec!=?vp9]+bestaudio/best'";
|
||||||
|
|
||||||
|
youtube-download = "${pkgs.ts}/bin/ts ${pkgs.youtube-dl}/bin/youtube-dl -f ${ytdl-format} --add-metadata";
|
||||||
|
|
||||||
|
newsboat-home =
|
||||||
|
"${config.users.users.me.home}/cloud/Seafile/Documents/newsboat";
|
||||||
|
linkhandler-bin = "${pkgs.scripts.linkhandler}/bin/linkhandler";
|
||||||
|
|
||||||
|
newsboat-config = pkgs.writeText "config" ''
|
||||||
|
auto-reload no
|
||||||
|
prepopulate-query-feeds yes
|
||||||
|
|
||||||
|
# dont keep a search history
|
||||||
|
history-limit 0
|
||||||
|
|
||||||
|
datetime-format %F
|
||||||
|
|
||||||
|
text-width 85
|
||||||
|
|
||||||
|
external-url-viewer "${pkgs.urlscan}/bin/urlscan -dc -r '${linkhandler-bin} {}'"
|
||||||
|
browser ${linkhandler-bin}
|
||||||
|
macro , open-in-browser
|
||||||
|
macro c set browser "${pkgs.xsel}/bin/xsel -b <<<" ; open-in-browser ; set browser ${linkhandler-bin}
|
||||||
|
macro v set browser "${pkgs.utillinux}/bin/setsid -f ${pkgs.mpv}/bin/mpv" ; open-in-browser ; set browser ${linkhandler-bin}
|
||||||
|
macro y set browser "${youtube-download}" ; open-in-browser ; set browser ${linkhandler-bin}
|
||||||
|
|
||||||
|
bind-key j down
|
||||||
|
bind-key k up
|
||||||
|
bind-key j next articlelist
|
||||||
|
bind-key k prev articlelist
|
||||||
|
bind-key J next-feed articlelist
|
||||||
|
bind-key K prev-feed articlelist
|
||||||
|
bind-key G end
|
||||||
|
bind-key g home
|
||||||
|
bind-key d pagedown
|
||||||
|
bind-key u pageup
|
||||||
|
bind-key l open
|
||||||
|
bind-key h quit
|
||||||
|
bind-key a toggle-article-read
|
||||||
|
bind-key n next-unread
|
||||||
|
bind-key N prev-unread
|
||||||
|
bind-key D pb-download
|
||||||
|
bind-key U show-urls
|
||||||
|
bind-key x pb-delete
|
||||||
|
|
||||||
|
save-path ${newsboat-home}/saved/
|
||||||
|
|
||||||
|
highlight all "---.*---" yellow default
|
||||||
|
highlight feedlist ".*(0/0))" black default
|
||||||
|
highlight article "^Title:.*" yellow default bold
|
||||||
|
highlight article "^Author:.*" yellow default
|
||||||
|
highlight article "^Flags:.*" red default
|
||||||
|
highlight article "\\[[0-9][0-9]*\\]" color66 default bold
|
||||||
|
highlight article "\\[image [0-9][0-9]*\\]" color109 default bold
|
||||||
|
highlight article "\\[embedded flash: [0-9][0-9]*\\]" color66 default bold
|
||||||
|
|
||||||
|
color background white default
|
||||||
|
color listnormal white default
|
||||||
|
color listnormal_unread white default bold
|
||||||
|
color listfocus blue default
|
||||||
|
color listfocus_unread blue default bold
|
||||||
|
color info red default bold
|
||||||
|
color article white default
|
||||||
|
'';
|
||||||
|
in {
|
||||||
|
nixpkgs.config.packageOverrides = pkgs: {
|
||||||
|
newsboat = pkgs.writers.writeDashBin "newsboat" ''
|
||||||
|
${pkgs.newsboat}/bin/newsboat -C ${newsboat-config} -c ${newsboat-home}/cache.db -u ${newsboat-home}/urls "$@"
|
||||||
|
'';
|
||||||
|
};
|
||||||
|
|
||||||
|
environment.systemPackages = [
|
||||||
|
pkgs.newsboat
|
||||||
|
(pkgs.writers.writeDashBin "mpv-watch-later" ''
|
||||||
|
${pkgs.sqlite}/bin/sqlite3 ${newsboat-home}/cache.db "SELECT url FROM rss_item WHERE flags='e' AND deleted=0 ORDER BY pubDate DESC" \
|
||||||
|
| ${pkgs.findutils}/bin/xargs ${pkgs.mpv}/bin/mpv
|
||||||
|
'')
|
||||||
|
];
|
||||||
|
}
|
||||||
55
configs/nextcloud.nix
Normal file
@@ -0,0 +1,55 @@
|
|||||||
|
{ pkgs, lib, ... }:
|
||||||
|
let
|
||||||
|
inherit (import <niveum/lib>) localAddresses;
|
||||||
|
in
|
||||||
|
{
|
||||||
|
services.nextcloud = {
|
||||||
|
enable = true;
|
||||||
|
package = pkgs.nextcloud22;
|
||||||
|
|
||||||
|
https = true;
|
||||||
|
|
||||||
|
autoUpdateApps = {
|
||||||
|
enable = true;
|
||||||
|
startAt = "05:00:00";
|
||||||
|
};
|
||||||
|
|
||||||
|
hostName = "cloud.xn--kiern-0qa.de";
|
||||||
|
|
||||||
|
config = {
|
||||||
|
overwriteProtocol = "https";
|
||||||
|
|
||||||
|
dbtype = "pgsql";
|
||||||
|
dbuser = "nextcloud";
|
||||||
|
dbhost = "/run/postgresql"; # nextcloud will add /.s.PGSQL.5432 by itself
|
||||||
|
dbname = "nextcloud";
|
||||||
|
dbpass = lib.strings.fileContents <system-secrets/nextcloud/database>;
|
||||||
|
adminpass = lib.strings.fileContents <system-secrets/nextcloud/admin>;
|
||||||
|
adminuser = "admin";
|
||||||
|
# extraTrustedDomains = [ "toum.r" ];
|
||||||
|
};
|
||||||
|
};
|
||||||
|
|
||||||
|
services.postgresql = {
|
||||||
|
enable = true;
|
||||||
|
ensureDatabases = [ "nextcloud" ];
|
||||||
|
ensureUsers = [
|
||||||
|
{
|
||||||
|
name = "nextcloud";
|
||||||
|
ensurePermissions."DATABASE nextcloud" = "ALL PRIVILEGES";
|
||||||
|
}
|
||||||
|
];
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
services.nginx.virtualHosts."cloud.xn--kiern-0qa.de" = {
|
||||||
|
enableACME = true;
|
||||||
|
forceSSL = true;
|
||||||
|
};
|
||||||
|
|
||||||
|
# Ensure that postgres is running before running the setup
|
||||||
|
systemd.services."nextcloud-setup" = {
|
||||||
|
requires = ["postgresql.service"];
|
||||||
|
after = ["postgresql.service"];
|
||||||
|
};
|
||||||
|
}
|
||||||
10
configs/nix.nix
Normal file
@@ -0,0 +1,10 @@
|
|||||||
|
{ pkgs, ... }:
|
||||||
|
{
|
||||||
|
# enable `nix flake`
|
||||||
|
nix = {
|
||||||
|
package = pkgs.nix;
|
||||||
|
# extraOptions = ''
|
||||||
|
# experimental-features = nix-command
|
||||||
|
# '';
|
||||||
|
};
|
||||||
|
}
|
||||||