Compare commits
227 Commits
d4d63db6d2
...
main
| Author | SHA1 | Date | |
|---|---|---|---|
| c1ab929c4e | |||
| 087da792de | |||
| 89d91a98de | |||
| 2e0110ad06 | |||
| e875bc8907 | |||
| 9c6c172a27 | |||
| b77f746c39 | |||
| aafb9e5b6f | |||
| 5f090fee23 | |||
| 1f30f51625 | |||
| de51bbadaa | |||
| 3f5a598f0b | |||
| d43e89900b | |||
| 24872e5e71 | |||
| 74f3632834 | |||
| 58c066387a | |||
| bb17f24446 | |||
| 7a10a92621 | |||
| c73a6fff61 | |||
| 7ff1da9886 | |||
| 092c3ec9ac | |||
| d8167b3bc1 | |||
| 033a9e582c | |||
| 6c4ac92a7c | |||
| ea837aba45 | |||
| 0d6c532340 | |||
| b795a74417 | |||
| 8f5123319f | |||
| e2e9875653 | |||
| 557aca3aa9 | |||
| ef95597355 | |||
| b034edfda1 | |||
| effa623876 | |||
| 8dc4384350 | |||
| 8d71ea5657 | |||
| cde630dc74 | |||
| dfe853ec96 | |||
| 84ee16c98a | |||
| 9a55c22c23 | |||
| 485b787d09 | |||
| 59631b5d75 | |||
| 3d901b78eb | |||
| 7d7838e43c | |||
| 7bd64b8391 | |||
| 4e3f4b416f | |||
| d7fa9e2cc7 | |||
| d14ed789f5 | |||
| 4cb380812b | |||
| 0ffee96f6c | |||
| 09ca273f3e | |||
| 7b6dc8c2a8 | |||
| 0439f5083e | |||
| cadadbee02 | |||
| d8c3525423 | |||
| 5ab83572b3 | |||
|
|
349c74888d | ||
| 827f98791a | |||
| dc8108a8e4 | |||
|
|
4ad1613d45 | ||
|
|
56367f0e9c | ||
|
|
22701fb35a | ||
|
|
d24f3fc198 | ||
|
|
d5e663c6d8 | ||
|
|
65750629d3 | ||
| 87752f4f96 | |||
| 92abcf170b | |||
| 5383bde053 | |||
| ace21e49ed | |||
| 4b7040d16a | |||
| 8faddd4adb | |||
| 7e54e621a9 | |||
| 2441487e14 | |||
| 1d162b9aaf | |||
| e0b495d33c | |||
| 2c786f806a | |||
| 1a379a9e48 | |||
| 1805cbf46b | |||
| fe36dca74a | |||
| a828a37f43 | |||
| c644d7d51b | |||
| e17724c61a | |||
| a825f325d0 | |||
| 6e4c4c83bc | |||
| a4215f7a37 | |||
| 4fa6138661 | |||
| 64b34c50fa | |||
| 9140259a7a | |||
| a74aa2c6b6 | |||
| 5747fabd66 | |||
| 8f2bad1a74 | |||
| 081c2a5f9a | |||
| f048b3b885 | |||
| ecf6a19a92 | |||
| 3304fba25b | |||
| 63b953a8b2 | |||
| 101304f7eb | |||
| f6515dfc93 | |||
| 64eb651168 | |||
| 91e82c5687 | |||
| e14c8721d1 | |||
| 7997992095 | |||
| 0cfc9f8f91 | |||
| 23395ea3c2 | |||
| 0c05ceb40d | |||
| 66a424d2c4 | |||
| e0dfd08f24 | |||
| 5c70acaecd | |||
| 58031f3896 | |||
| 9f898180bf | |||
| b8038a30c8 | |||
| e83c380ce6 | |||
| 6390e72806 | |||
| 31d8eab939 | |||
| 3fc89e6c2b | |||
| d5df512c97 | |||
| a9b1745cf4 | |||
| 6e6d0eb102 | |||
| 7ba2d4fbda | |||
| 4a62f59534 | |||
| 8f33088cdb | |||
| fc1c4d1d98 | |||
| b71294c885 | |||
| 285abe4db7 | |||
| 8bef999ed5 | |||
| c312193c48 | |||
| ba5a5859b0 | |||
| cd445975ba | |||
| b2342b0d3c | |||
| 2af9877107 | |||
| 96343e1e29 | |||
| 5a35dcf7c1 | |||
| 0abd9978d8 | |||
| 3abc41a934 | |||
| 4934c3e57e | |||
| d1ca548da0 | |||
| 8f887e8da9 | |||
| a2ceaf2e2e | |||
| 7e79913d5e | |||
| 471f2e298e | |||
| 7000183e98 | |||
| bec7b9cc4d | |||
| be0b31c429 | |||
| 5fed071e2f | |||
| 7dbd900843 | |||
| 6d2e57d22a | |||
| 9254276fd5 | |||
| 4a7004d58a | |||
| a1d6a2388e | |||
| b6e7f2a0fe | |||
| 3be8cd6b80 | |||
| 54e40148e6 | |||
| d3335faec1 | |||
| 5195fe4445 | |||
| ac756d25fa | |||
| c79158d1ce | |||
| 67365bb3dd | |||
| 6e7d2ef0bb | |||
| 7898f567a5 | |||
| 58dd448d24 | |||
| 091defb305 | |||
| 00520ecd5f | |||
| 676bb8d32d | |||
| 93372839e4 | |||
| 55e78faacc | |||
| 6c6d6f24af | |||
| 176263a69c | |||
| bb1560f6bb | |||
| a64f759c85 | |||
| 4f3af0a21a | |||
| c490063598 | |||
| 77185ad8f3 | |||
| 7fbe36671b | |||
| 26259480b2 | |||
| 5064b95a3c | |||
| 0dd747dcf6 | |||
| a9d6431701 | |||
| 898c7d473b | |||
| f698d9c140 | |||
| 3744f294bc | |||
| f359432175 | |||
| 2955949475 | |||
| b075ed6888 | |||
| 29b0281c72 | |||
| f6629ce275 | |||
| 823cb71491 | |||
| 47eaf75bfb | |||
| b9fbcb5864 | |||
| 683f19d596 | |||
| e9f36c71ce | |||
| cd235b33c4 | |||
| f32f66b09c | |||
| 0e50376c19 | |||
| a940afae47 | |||
| 6e4c94100d | |||
| 9dcc57fffc | |||
| 4b65bf0e51 | |||
| 35204373da | |||
| 71c24f64bf | |||
| f7c093d1a9 | |||
| bc6d11d619 | |||
| bd80d04a63 | |||
| ccd3fd3c4d | |||
| e412730f28 | |||
| 960edd01a9 | |||
| c0c31dd8c5 | |||
| bf22680dd2 | |||
| a824faab2e | |||
| 6df9093a6b | |||
| 4e7e2a7e70 | |||
| 668392976f | |||
| 30bc9d7875 | |||
| 29c6c7c94c | |||
| 828c27b7b7 | |||
|
|
5aa9d049c5 | ||
| 2f3a77c68b | |||
|
|
06b11be630 | ||
|
|
2dc4294190 | ||
| 741c033e01 | |||
| 46fd395753 | |||
| c19e1229cf | |||
| 46916c62f2 | |||
| 27681b1804 | |||
| fe681b9b33 | |||
| d026028e06 | |||
| 4efb77e18d | |||
| 7dc9ff566c | |||
| b5d025be2d |
308
flake.lock
generated
308
flake.lock
generated
@@ -1,38 +1,51 @@
|
||||
{
|
||||
"nodes": {
|
||||
"emacs-overlay": {
|
||||
"deploy-rs": {
|
||||
"inputs": {
|
||||
"flake-utils": "flake-utils",
|
||||
"nixpkgs": [
|
||||
"me-emacs",
|
||||
"nixpkgs"
|
||||
],
|
||||
"nixpkgs-stable": "nixpkgs-stable"
|
||||
"flake-compat": "flake-compat",
|
||||
"nixpkgs": "nixpkgs",
|
||||
"utils": "utils"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1692037570,
|
||||
"narHash": "sha256-bvj/wfLLFTc8cWAwhN8tgShiy8ekPWt1+gWlEH7W4zY=",
|
||||
"owner": "nix-community",
|
||||
"repo": "emacs-overlay",
|
||||
"rev": "7a4b5bbc06182e2f704630cd77a614ab0d9c2f2e",
|
||||
"lastModified": 1762286984,
|
||||
"narHash": "sha256-9I2H9x5We6Pl+DBYHjR1s3UT8wgwcpAH03kn9CqtdQc=",
|
||||
"owner": "serokell",
|
||||
"repo": "deploy-rs",
|
||||
"rev": "9c870f63e28ec1e83305f7f6cb73c941e699f74f",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nix-community",
|
||||
"repo": "emacs-overlay",
|
||||
"owner": "serokell",
|
||||
"repo": "deploy-rs",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"flake-compat": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1733328505,
|
||||
"narHash": "sha256-NeCCThCEP3eCl2l/+27kNNK7QrwZB1IJCrXfrbv5oqU=",
|
||||
"owner": "edolstra",
|
||||
"repo": "flake-compat",
|
||||
"rev": "ff81ac966bb2cae68946d5ed5fc4994f96d0ffec",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "edolstra",
|
||||
"repo": "flake-compat",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"flake-utils": {
|
||||
"inputs": {
|
||||
"systems": "systems"
|
||||
"systems": "systems_2"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1689068808,
|
||||
"narHash": "sha256-6ixXo3wt24N/melDWjq70UuHQLxGV8jZvooRanIHXw0=",
|
||||
"lastModified": 1731533236,
|
||||
"narHash": "sha256-l0KFg5HjrsfsO/JpG+r7fRrqm12kzFHyUHqHCVpMMbI=",
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"rev": "919d646de7be200f3bf08cb76ae1f09402b6f9b4",
|
||||
"rev": "11707dc2f618dd54ca8739b309ec4fc024de578b",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@@ -43,14 +56,14 @@
|
||||
},
|
||||
"flake-utils_2": {
|
||||
"inputs": {
|
||||
"systems": "systems_2"
|
||||
"systems": "systems_3"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1689068808,
|
||||
"narHash": "sha256-6ixXo3wt24N/melDWjq70UuHQLxGV8jZvooRanIHXw0=",
|
||||
"lastModified": 1731533236,
|
||||
"narHash": "sha256-l0KFg5HjrsfsO/JpG+r7fRrqm12kzFHyUHqHCVpMMbI=",
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"rev": "919d646de7be200f3bf08cb76ae1f09402b6f9b4",
|
||||
"rev": "11707dc2f618dd54ca8739b309ec4fc024de578b",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@@ -59,6 +72,39 @@
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"flake-utils_3": {
|
||||
"inputs": {
|
||||
"systems": "systems_4"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1731533236,
|
||||
"narHash": "sha256-l0KFg5HjrsfsO/JpG+r7fRrqm12kzFHyUHqHCVpMMbI=",
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"rev": "11707dc2f618dd54ca8739b309ec4fc024de578b",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"flakey-profile": {
|
||||
"locked": {
|
||||
"lastModified": 1712898590,
|
||||
"narHash": "sha256-FhGIEU93VHAChKEXx905TSiPZKga69bWl1VB37FK//I=",
|
||||
"owner": "lf-",
|
||||
"repo": "flakey-profile",
|
||||
"rev": "243c903fd8eadc0f63d205665a92d4df91d42d9d",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "lf-",
|
||||
"repo": "flakey-profile",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"home-manager": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
@@ -66,11 +112,11 @@
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1705104164,
|
||||
"narHash": "sha256-pllCu3Hcm1wP/B0SUxgUXvHeEd4w8s2aVrEQRdIL1yo=",
|
||||
"lastModified": 1762458864,
|
||||
"narHash": "sha256-O8NI0pOf1GxPaBRhyspWZmtXLo0tzEEvOfMxNh3/8Jo=",
|
||||
"owner": "nix-community",
|
||||
"repo": "home-manager",
|
||||
"rev": "0912d26b30332ae6a90e1b321ff88e80492127dd",
|
||||
"rev": "f35d0cb75f0669ac8de18d774b336d3d3560bcde",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@@ -79,20 +125,54 @@
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"lix": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1737234286,
|
||||
"narHash": "sha256-CCKIAE84dzkrnlxJCKFyffAxP3yfsOAbdvydUGqq24g=",
|
||||
"rev": "2837da71ec1588c1187d2e554719b15904a46c8b",
|
||||
"type": "tarball",
|
||||
"url": "https://git.lix.systems/api/v1/repos/lix-project/lix/archive/2837da71ec1588c1187d2e554719b15904a46c8b.tar.gz?rev=2837da71ec1588c1187d2e554719b15904a46c8b"
|
||||
},
|
||||
"original": {
|
||||
"type": "tarball",
|
||||
"url": "https://git.lix.systems/lix-project/lix/archive/2.92.0.tar.gz"
|
||||
}
|
||||
},
|
||||
"lix-module": {
|
||||
"inputs": {
|
||||
"flake-utils": "flake-utils",
|
||||
"flakey-profile": "flakey-profile",
|
||||
"lix": "lix",
|
||||
"nixpkgs": [
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1737237494,
|
||||
"narHash": "sha256-YMLrcBpf0TR5r/eaqm8lxzFPap2TxCor0ZGcK3a7+b8=",
|
||||
"rev": "b90bf629bbd835e61f1317b99e12f8c831017006",
|
||||
"type": "tarball",
|
||||
"url": "https://git.lix.systems/api/v1/repos/lix-project/nixos-module/archive/b90bf629bbd835e61f1317b99e12f8c831017006.tar.gz?rev=b90bf629bbd835e61f1317b99e12f8c831017006"
|
||||
},
|
||||
"original": {
|
||||
"type": "tarball",
|
||||
"url": "https://git.lix.systems/lix-project/nixos-module/archive/2.92.0.tar.gz"
|
||||
}
|
||||
},
|
||||
"me-emacs": {
|
||||
"inputs": {
|
||||
"emacs-overlay": "emacs-overlay",
|
||||
"flake-utils": "flake-utils_2",
|
||||
"nixpkgs": [
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1706555256,
|
||||
"narHash": "sha256-nBLS68TsIbwd04oQRISqk/xaehZYWzGNDmdBOWpKWXw=",
|
||||
"lastModified": 1757014957,
|
||||
"narHash": "sha256-iPw1uXPUb4mPSZ/Uneop+1veSN5fEYCrsJwq71zLADs=",
|
||||
"ref": "refs/heads/master",
|
||||
"rev": "d3452d3f0a30162a8acdf11f452ac0ef3a3f5670",
|
||||
"revCount": 46,
|
||||
"rev": "71bb31643363b4a42948505d41f4e1c83a21c868",
|
||||
"revCount": 88,
|
||||
"type": "git",
|
||||
"url": "https://git.syzygial.cc/Syzygial/EmacsConfig.git"
|
||||
},
|
||||
@@ -101,6 +181,28 @@
|
||||
"url": "https://git.syzygial.cc/Syzygial/EmacsConfig.git"
|
||||
}
|
||||
},
|
||||
"microvm": {
|
||||
"inputs": {
|
||||
"flake-utils": "flake-utils_3",
|
||||
"nixpkgs": [
|
||||
"nixpkgs"
|
||||
],
|
||||
"spectrum": "spectrum"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1762200934,
|
||||
"narHash": "sha256-Bv4ZKRPsIc6W7qF1I2fevxFETqRNuG3XOsiRIfJ7YlQ=",
|
||||
"owner": "astro",
|
||||
"repo": "microvm.nix",
|
||||
"rev": "1d05a3c26dbb9d4b1cd644e10713a70d8740cb6a",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "astro",
|
||||
"repo": "microvm.nix",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nix-darwin": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
@@ -108,11 +210,11 @@
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1704277720,
|
||||
"narHash": "sha256-meAKNgmh3goankLGWqqpw73pm9IvXjEENJloF0coskE=",
|
||||
"lastModified": 1762304480,
|
||||
"narHash": "sha256-ikVIPB/ea/BAODk6aksgkup9k2jQdrwr4+ZRXtBgmSs=",
|
||||
"owner": "LnL7",
|
||||
"repo": "nix-darwin",
|
||||
"rev": "0dd382b70c351f528561f71a0a7df82c9d2be9a4",
|
||||
"rev": "b8c7ac030211f18bd1f41eae0b815571853db7a2",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@@ -124,11 +226,27 @@
|
||||
},
|
||||
"nixpkgs": {
|
||||
"locked": {
|
||||
"lastModified": 1704722960,
|
||||
"narHash": "sha256-mKGJ3sPsT6//s+Knglai5YflJUF2DGj7Ai6Ynopz0kI=",
|
||||
"lastModified": 1743014863,
|
||||
"narHash": "sha256-jAIUqsiN2r3hCuHji80U7NNEafpIMBXiwKlSrjWMlpg=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "317484b1ead87b9c1b8ac5261a8d2dd748a0492d",
|
||||
"rev": "bd3bac8bfb542dbde7ffffb6987a1a1f9d41699f",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "NixOS",
|
||||
"ref": "nixpkgs-unstable",
|
||||
"repo": "nixpkgs",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs_2": {
|
||||
"locked": {
|
||||
"lastModified": 1762111121,
|
||||
"narHash": "sha256-4vhDuZ7OZaZmKKrnDpxLZZpGIJvAeMtK6FKLJYUtAdw=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "b3d51a0365f6695e7dd5cdf3e180604530ed33b4",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@@ -138,45 +256,13 @@
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs-stable": {
|
||||
"nixpkgs_3": {
|
||||
"locked": {
|
||||
"lastModified": 1691950488,
|
||||
"narHash": "sha256-iUNEeudc4dGjx+HsHccnGiuZUVE/nhjXuQ1DVCsHIUY=",
|
||||
"lastModified": 1760596604,
|
||||
"narHash": "sha256-J/i5K6AAz/y5dBePHQOuzC7MbhyTOKsd/GLezSbEFiM=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "720e61ed8de116eec48d6baea1d54469b536b985",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "NixOS",
|
||||
"ref": "nixos-23.05",
|
||||
"repo": "nixpkgs",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs-stable_2": {
|
||||
"locked": {
|
||||
"lastModified": 1704290814,
|
||||
"narHash": "sha256-LWvKHp7kGxk/GEtlrGYV68qIvPHkU9iToomNFGagixU=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "70bdadeb94ffc8806c0570eb5c2695ad29f0e421",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "NixOS",
|
||||
"ref": "release-23.05",
|
||||
"repo": "nixpkgs",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs_2": {
|
||||
"locked": {
|
||||
"lastModified": 1704161960,
|
||||
"narHash": "sha256-QGua89Pmq+FBAro8NriTuoO/wNaUtugt29/qqA8zeeM=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "63143ac2c9186be6d9da6035fa22620018c85932",
|
||||
"rev": "3cbe716e2346710d6e1f7c559363d14e11c32a43",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@@ -188,24 +274,26 @@
|
||||
},
|
||||
"root": {
|
||||
"inputs": {
|
||||
"deploy-rs": "deploy-rs",
|
||||
"home-manager": "home-manager",
|
||||
"lix-module": "lix-module",
|
||||
"me-emacs": "me-emacs",
|
||||
"microvm": "microvm",
|
||||
"nix-darwin": "nix-darwin",
|
||||
"nixpkgs": "nixpkgs",
|
||||
"nixpkgs": "nixpkgs_2",
|
||||
"sops-nix": "sops-nix"
|
||||
}
|
||||
},
|
||||
"sops-nix": {
|
||||
"inputs": {
|
||||
"nixpkgs": "nixpkgs_2",
|
||||
"nixpkgs-stable": "nixpkgs-stable_2"
|
||||
"nixpkgs": "nixpkgs_3"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1704908274,
|
||||
"narHash": "sha256-74W9Yyomv3COGRmKi8zvyA5tL2KLiVkBeaYmYLjXyOw=",
|
||||
"lastModified": 1760998189,
|
||||
"narHash": "sha256-ee2e1/AeGL5X8oy/HXsZQvZnae6XfEVdstGopKucYLY=",
|
||||
"owner": "Mic92",
|
||||
"repo": "sops-nix",
|
||||
"rev": "c0b3a5af90fae3ba95645bbf85d2b64880addd76",
|
||||
"rev": "5a7d18b5c55642df5c432aadb757140edfeb70b3",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
@@ -214,6 +302,22 @@
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"spectrum": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1759482047,
|
||||
"narHash": "sha256-H1wiXRQHxxPyMMlP39ce3ROKCwI5/tUn36P8x6dFiiQ=",
|
||||
"ref": "refs/heads/main",
|
||||
"rev": "c5d5786d3dc938af0b279c542d1e43bce381b4b9",
|
||||
"revCount": 996,
|
||||
"type": "git",
|
||||
"url": "https://spectrum-os.org/git/spectrum"
|
||||
},
|
||||
"original": {
|
||||
"type": "git",
|
||||
"url": "https://spectrum-os.org/git/spectrum"
|
||||
}
|
||||
},
|
||||
"systems": {
|
||||
"locked": {
|
||||
"lastModified": 1681028828,
|
||||
@@ -243,6 +347,54 @@
|
||||
"repo": "default",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"systems_3": {
|
||||
"locked": {
|
||||
"lastModified": 1681028828,
|
||||
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
|
||||
"owner": "nix-systems",
|
||||
"repo": "default",
|
||||
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nix-systems",
|
||||
"repo": "default",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"systems_4": {
|
||||
"locked": {
|
||||
"lastModified": 1681028828,
|
||||
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
|
||||
"owner": "nix-systems",
|
||||
"repo": "default",
|
||||
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nix-systems",
|
||||
"repo": "default",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"utils": {
|
||||
"inputs": {
|
||||
"systems": "systems"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1731533236,
|
||||
"narHash": "sha256-l0KFg5HjrsfsO/JpG+r7fRrqm12kzFHyUHqHCVpMMbI=",
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"rev": "11707dc2f618dd54ca8739b309ec4fc024de578b",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"type": "github"
|
||||
}
|
||||
}
|
||||
},
|
||||
"root": "root",
|
||||
|
||||
165
flake.nix
165
flake.nix
@@ -8,73 +8,118 @@
|
||||
nix-darwin.inputs.nixpkgs.follows = "nixpkgs";
|
||||
home-manager.url = "github:nix-community/home-manager";
|
||||
home-manager.inputs.nixpkgs.follows = "nixpkgs";
|
||||
lix-module = {
|
||||
url = "https://git.lix.systems/lix-project/nixos-module/archive/2.92.0.tar.gz";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
microvm.url = "github:astro/microvm.nix";
|
||||
microvm.inputs.nixpkgs.follows = "nixpkgs";
|
||||
deploy-rs.url = "github:serokell/deploy-rs";
|
||||
};
|
||||
|
||||
outputs = { self, nixpkgs, sops-nix, me-emacs, nix-darwin, home-manager }@attrs: let
|
||||
hydraGitea = (final: prev: {
|
||||
hydra_unstable = prev.hydra_unstable.overrideAttrs
|
||||
(old: {
|
||||
doCheck = false;
|
||||
patches = [
|
||||
(final.fetchpatch {
|
||||
name = "hydra-gitea-push-patch";
|
||||
url = "https://patch-diff.githubusercontent.com/raw/NixOS/hydra/pull/1227.patch";
|
||||
sha256 = "A4dN/4zLMKLYaD38lu87lzAWH/3EUM7G5njx7Q4W47w=";
|
||||
})
|
||||
];
|
||||
});
|
||||
});
|
||||
nvidiaContainer = import ./nvidiacontainer-overlay.nix nixpkgs;
|
||||
outputs = { self, nixpkgs, sops-nix, me-emacs, nix-darwin, home-manager, lix-module, microvm, deploy-rs }@inputs: let
|
||||
overlays = import ./overlays/default.nix inputs;
|
||||
modules = import ./modules/default.nix inputs;
|
||||
|
||||
# Configuration for `nixpkgs`
|
||||
nixpkgsConfig = {
|
||||
config = { allowUnfree = true; };
|
||||
};
|
||||
me-emacs-overlay = (final: prev: {
|
||||
me-emacs = me-emacs.packages."x86_64-linux".emacs;
|
||||
# Will in future be macports based
|
||||
mac-emacs = me-emacs.packages."aarch64-darwin".emacs;
|
||||
overlays' = l: ({ config, pkgs, ... }: {
|
||||
nixpkgs.overlays = l;
|
||||
});
|
||||
in {
|
||||
nixosConfigurations.nixos = nixpkgs.lib.nixosSystem {
|
||||
|
||||
pkgs_linux-x86_64 = nixpkgs.legacyPackages."x86-linux";
|
||||
pkgs_linux-aarch64 = nixpkgs.legacyPackages."aarch64-linux";
|
||||
|
||||
sysConfig = config: {
|
||||
system = "x86_64-linux";
|
||||
specialArgs = attrs;
|
||||
modules =
|
||||
[
|
||||
({ config, pkgs, ... }: {
|
||||
nixpkgs.overlays = [ hydraGitea nvidiaContainer ];
|
||||
})
|
||||
./machines/hippocampus/configuration.nix
|
||||
sops-nix.nixosModules.sops
|
||||
];
|
||||
};
|
||||
nixosConfigurations.universedesktop = nixpkgs.lib.nixosSystem {
|
||||
system = "x86_64-linux";
|
||||
specialArgs = attrs;
|
||||
modules =
|
||||
[
|
||||
({ config, pkgs, ... }: {
|
||||
nixpkgs.overlays = [ me-emacs-overlay ];
|
||||
})
|
||||
./machines/universedesktop/configuration.nix
|
||||
sops-nix.nixosModules.sops
|
||||
];
|
||||
};
|
||||
darwinConfigurations."Universe-MacBook-Air" = nix-darwin.lib.darwinSystem {
|
||||
specialArgs = { inherit inputs; };
|
||||
} // config;
|
||||
|
||||
nixosSystem' = config: nixpkgs.lib.nixosSystem (sysConfig ({
|
||||
|
||||
} // config));
|
||||
|
||||
darwinSystem' = config: nix-darwin.lib.darwinSystem (sysConfig ({
|
||||
system = "aarch64-darwin";
|
||||
specialArgs = {
|
||||
inputs = attrs;
|
||||
} // config));
|
||||
|
||||
homeConf' = config: home-manager.lib.homeManagerConfiguration config;
|
||||
in {
|
||||
nixosConfigurations = {
|
||||
nixos = nixosSystem' {
|
||||
modules =[
|
||||
./machines/hippocampus/configuration.nix
|
||||
(overlays' [
|
||||
overlays.nvidiaContainer
|
||||
])
|
||||
modules.sops
|
||||
({ pkgs, ...}: {
|
||||
nix.package = pkgs.lix;
|
||||
})
|
||||
];
|
||||
};
|
||||
modules = [
|
||||
./machines/universeair/configuration.nix
|
||||
({ config, pkgs, ... }: {
|
||||
nixpkgs.overlays = [ me-emacs-overlay ];
|
||||
})
|
||||
home-manager.darwinModules.home-manager
|
||||
{
|
||||
nixpkgs = nixpkgsConfig;
|
||||
}
|
||||
];
|
||||
universedesktop = nixosSystem' {
|
||||
modules = [
|
||||
./machines/universedesktop/configuration.nix
|
||||
(overlays' [
|
||||
overlays.emacs
|
||||
])
|
||||
modules.sops
|
||||
# Broken w/ this nixpkgs input
|
||||
# lix-module.nixosModules.default
|
||||
];
|
||||
};
|
||||
pericyte = nixosSystem' {
|
||||
modules = [
|
||||
./machines/pericyte/configuration.nix
|
||||
modules.sops
|
||||
# lix-module.nixosModules.default
|
||||
# microvm.nixosModules.host
|
||||
];
|
||||
};
|
||||
};
|
||||
darwinConfigurations = {
|
||||
UniverseAir = darwinSystem' {
|
||||
modules = [
|
||||
./machines/universeair/configuration.nix
|
||||
(overlays' [
|
||||
overlays.emacs
|
||||
])
|
||||
modules.home-manager-darwin
|
||||
# lix-module.nixosModules.default
|
||||
];
|
||||
};
|
||||
};
|
||||
homeConfigurations = {
|
||||
universelaptop = homeConf' {
|
||||
pkgs = pkgs_linux-aarch64;
|
||||
|
||||
extraSpecialArgs = {
|
||||
pkgs-x86_64 = pkgs_linux-x86_64;
|
||||
inputs = inputs;
|
||||
};
|
||||
|
||||
modules = [
|
||||
./machines/asahi/home.nix
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
deploy = {
|
||||
nodes = {
|
||||
pericyte = {
|
||||
hostname = "opcp";
|
||||
sshUser = "root";
|
||||
profiles.system = {
|
||||
user = "root";
|
||||
path = deploy-rs.lib.x86_64-linux.activate.nixos self.nixosConfigurations.pericyte;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
# This is highly advised, and will prevent many possible mistakes
|
||||
# checks = builtins.mapAttrs (system: deployLib: deployLib.deployChecks self.deploy) deploy-rs.lib;
|
||||
|
||||
hydraJobs = {
|
||||
# inherit (me-emacs) packages;
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
62
machines/asahi/home.nix
Normal file
62
machines/asahi/home.nix
Normal file
@@ -0,0 +1,62 @@
|
||||
{ config, pkgs, ... }:
|
||||
|
||||
{
|
||||
# Home Manager needs a bit of information about you and the paths it should
|
||||
# manage.
|
||||
home.username = "universelaptop";
|
||||
home.homeDirectory = "/home/universelaptop";
|
||||
|
||||
# This value determines the Home Manager release that your configuration is
|
||||
# compatible with. This helps avoid breakage when a new Home Manager release
|
||||
# introduces backwards incompatible changes.
|
||||
#
|
||||
# You should not change this value, even if you update Home Manager. If you do
|
||||
# want to update the value, then make sure to first check the Home Manager
|
||||
# release notes.
|
||||
home.stateVersion = "23.11"; # Please read the comment before changing.
|
||||
|
||||
# The home.packages option allows you to install Nix packages into your
|
||||
# environment.
|
||||
home.packages = [
|
||||
me-emacs
|
||||
armcord
|
||||
# TODO: Make home-manager module for loading x86_64 apps and automatically
|
||||
# wrapping them in box64-asahi (page size change, like in Fedora repo)
|
||||
# as well as, with override option, to enable support for box86/wine
|
||||
];
|
||||
|
||||
services.nextcloud-client.enable;
|
||||
|
||||
# Home Manager is pretty good at managing dotfiles. The primary way to manage
|
||||
# plain files is through 'home.file'.
|
||||
home.file = {
|
||||
# # Building this configuration will create a copy of 'dotfiles/screenrc' in
|
||||
# # the Nix store. Activating the configuration will then make '~/.screenrc' a
|
||||
# # symlink to the Nix store copy.
|
||||
# ".screenrc".source = dotfiles/screenrc;
|
||||
|
||||
# # You can also set the file content immediately.
|
||||
# ".gradle/gradle.properties".text = ''
|
||||
# org.gradle.console=verbose
|
||||
# org.gradle.daemon.idletimeout=3600000
|
||||
# '';
|
||||
};
|
||||
|
||||
# Home Manager can also manage your environment variables through
|
||||
# 'home.sessionVariables'. If you don't want to manage your shell through Home
|
||||
# Manager then you have to manually source 'hm-session-vars.sh' located at
|
||||
# either
|
||||
#
|
||||
# ~/.nix-profile/etc/profile.d/hm-session-vars.sh
|
||||
#
|
||||
# or
|
||||
#
|
||||
# /etc/profiles/per-user/universelaptop/etc/profile.d/hm-session-vars.sh
|
||||
#
|
||||
home.sessionVariables = {
|
||||
EDITOR = "emacs";
|
||||
};
|
||||
|
||||
# Let Home Manager install and manage itself.
|
||||
programs.home-manager.enable = true;
|
||||
}
|
||||
@@ -42,9 +42,9 @@ in {
|
||||
environmentFile = config.sops.secrets."restic/backblaze".path;
|
||||
|
||||
pruneOpts = [
|
||||
"--keep-daily 2"
|
||||
"--keep-weekly 4"
|
||||
"--keep-yearly 8"
|
||||
"--keep-daily 1"
|
||||
"--keep-weekly 2"
|
||||
"--keep-yearly 4"
|
||||
];
|
||||
};
|
||||
}
|
||||
|
||||
@@ -1,6 +1,24 @@
|
||||
{ ... }: {
|
||||
{ pkgs, config, ... }: {
|
||||
services.gitea.dump = {
|
||||
enable = true;
|
||||
interval = "2:45";
|
||||
};
|
||||
systemd.timers."gitea-clear-dump" = {
|
||||
wantedBy = [ "timers.target" ];
|
||||
timerConfig = {
|
||||
OnCalendar = "daily";
|
||||
Persistent = true;
|
||||
Unit = "gitea-clear-dump.service";
|
||||
};
|
||||
};
|
||||
|
||||
systemd.services."gitea-clear-dump" = {
|
||||
script = ''
|
||||
${pkgs.findutils}/bin/find /var/lib/gitea/dump -type f -ctime +5 -exec rm -f {} \;
|
||||
'';
|
||||
serviceConfig = {
|
||||
Type = "oneshot";
|
||||
User = config.services.gitea.user;
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
@@ -9,6 +9,9 @@
|
||||
[ # Include the results of the hardware scan.
|
||||
./hardware-configuration.nix
|
||||
|
||||
# Allow RISC-V Native Emulation (Binfmt QEMU)
|
||||
./riscv.nix
|
||||
|
||||
# Backup!
|
||||
./backup.nix
|
||||
|
||||
@@ -43,6 +46,9 @@
|
||||
options = "--delete-older-than 30d";
|
||||
};
|
||||
nix.settings.auto-optimise-store = true;
|
||||
nix.settings.trusted-users = [
|
||||
"server"
|
||||
];
|
||||
|
||||
# Bootloader.
|
||||
boot.loader.systemd-boot.enable = true;
|
||||
@@ -68,21 +74,21 @@
|
||||
# Enable the X11 windowing system.
|
||||
services.xserver.enable = true;
|
||||
|
||||
# Enable the Pantheon Desktop Environment.
|
||||
services.xserver.displayManager.sddm.enable = true;
|
||||
services.xserver.desktopManager.plasma5.enable = true;
|
||||
# services.xserver.displayManager.sddm.enable = true;
|
||||
# services.xserver.desktopManager.plasma5.enable = true;
|
||||
|
||||
# Configure keymap in X11
|
||||
services.xserver = {
|
||||
layout = "us";
|
||||
xkbVariant = "";
|
||||
xkb = {
|
||||
layout = "us";
|
||||
variant = "";
|
||||
};
|
||||
};
|
||||
|
||||
# Enable CUPS to print documents.
|
||||
services.printing.enable = true;
|
||||
|
||||
# Enable sound with pipewire.
|
||||
sound.enable = true;
|
||||
hardware.pulseaudio.enable = false;
|
||||
security.rtkit.enable = true;
|
||||
services.pipewire = {
|
||||
@@ -111,8 +117,8 @@
|
||||
};
|
||||
|
||||
# Enable automatic login for the user.
|
||||
services.xserver.displayManager.autoLogin.enable = true;
|
||||
services.xserver.displayManager.autoLogin.user = "server";
|
||||
# services.xserver.displayManager.autoLogin.enable = true;
|
||||
# services.xserver.displayManager.autoLogin.user = "server";
|
||||
|
||||
# List packages installed in system profile. To search, run:
|
||||
# $ nix search wget
|
||||
|
||||
@@ -68,7 +68,7 @@ let
|
||||
partOf = ["headscale.service"];
|
||||
|
||||
script = ''
|
||||
${cfg.package}/bin/headscale users create ${name}
|
||||
${pkgs.bash}/bin/bash -c '${cfg.package}/bin/headscale users create ${name} || true'
|
||||
'';
|
||||
|
||||
serviceConfig = {
|
||||
@@ -91,7 +91,7 @@ let
|
||||
partOf = ["headscale.service"];
|
||||
|
||||
script = ''
|
||||
${cfg.package}/bin/headscale preauthkeys -u ${name} create \
|
||||
${cfg.package}/bin/headscale preauthkeys -u $(${cfg.package}/bin/headscale users -o json-line list | ${pkgs.jq}/bin/jq '.[] | select(.name=="${name}").id') create \
|
||||
${lib.optionalString options.preAuthEphemeral "--ephemeral"} \
|
||||
${lib.optionalString options.preAuthReusable "--reusable"} \
|
||||
--expiration ${options.preAuthExpiration} \
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
nixpkgs.config.nvidia.acceptLicense = true;
|
||||
|
||||
services.xserver.videoDrivers = [ "nvidia" ];
|
||||
hardware.opengl.enable = true;
|
||||
hardware.graphics.enable = true;
|
||||
|
||||
# Optionally, you may need to select the appropriate driver version for your specific GPU.
|
||||
hardware.nvidia.package = config.boot.kernelPackages.nvidiaPackages.legacy_470;
|
||||
|
||||
5
machines/hippocampus/oci/Wireguard.ContainerFile
Normal file
5
machines/hippocampus/oci/Wireguard.ContainerFile
Normal file
@@ -0,0 +1,5 @@
|
||||
FROM alpine:3.16
|
||||
RUN apk add --no-cache bash wireguard-tools jq curl git ncurses
|
||||
RUN git clone https://github.com/pia-foss/manual-connections /manual-connections
|
||||
WORKDIR /manual-connections
|
||||
CMD bash -c "/manual-connections/run_setup.sh && watch -n 60 curl ip.me"
|
||||
@@ -18,10 +18,12 @@
|
||||
in {
|
||||
containers = {
|
||||
wireguard = {
|
||||
image = "thrnz/docker-wireguard-pia";
|
||||
# Derived from the pia-wg.tar.gz
|
||||
# which was built from the containerfile
|
||||
image = "localhost/pia-wg:latest";
|
||||
volumes = [
|
||||
# "${configDir}/wireguard:/config"
|
||||
"${configDir}/wireguard_pia:/pia"
|
||||
# "${configDir}/wireguard_pia:/pia"
|
||||
];
|
||||
ports = getPorts [
|
||||
"deluge"
|
||||
@@ -34,13 +36,23 @@
|
||||
];
|
||||
environment = {
|
||||
TZ = "America/Toronto";
|
||||
LOC = "ca";
|
||||
LOC = "ca";
|
||||
PIA_DNS = "false"; # - true/false
|
||||
PIA_PF = "false"; # - true/false
|
||||
PIA_CONNECT = "true"; # - true/false; connect to VPN after configuration has been created. Set to false to only create configuration file. Only effective for wireguard protocol. Default true.
|
||||
MAX_LATENCY = "0.2"; # - numeric value, in seconds
|
||||
AUTOCONNECT = "true"; # - true/false; this will test for and select the server with the lowest latency, it will override PREFERRED_REGION
|
||||
# PREFERRED_REGION = ""; # - the region ID for a PIA server
|
||||
DIP_TOKEN = "n";
|
||||
VPN_PROTOCOL = "wireguard"; # - wireguard or openvpn; openvpn will default to openvpn_udp_standard, but can also specify openvpn_tcp/udp_standad/strong
|
||||
DISABLE_IPV6 = "no"; # - yes/no
|
||||
};
|
||||
extraOptions = [
|
||||
"--cap-add=ALL"
|
||||
"--pull=newer"
|
||||
"--dns=1.1.1.1"
|
||||
"--privileged" "--dns=1.1.1.1"
|
||||
"--env-file=${config.sops.secrets.jellyfin-pia.path}"
|
||||
"--cap-add=NET_ADMIN,NET_RAW,SYS_MODULE"
|
||||
"--cap-drop=MKNOD,AUDIT_WRITE"
|
||||
"--sysctl=net.ipv4.ip_forward=1"
|
||||
"--sysctl=net.ipv4.conf.all.src_valid_mark=1"
|
||||
"--sysctl=net.ipv6.conf.lo.disable_ipv6=1"
|
||||
"--sysctl=net.ipv6.conf.all.disable_ipv6=1"
|
||||
|
||||
BIN
machines/hippocampus/oci/pia-wg.tar.gz
Normal file
BIN
machines/hippocampus/oci/pia-wg.tar.gz
Normal file
Binary file not shown.
6
machines/hippocampus/riscv.nix
Normal file
6
machines/hippocampus/riscv.nix
Normal file
@@ -0,0 +1,6 @@
|
||||
{ config, pkgs, lib, ... }: {
|
||||
boot.binfmt.emulatedSystems = [
|
||||
"riscv64-linux"
|
||||
];
|
||||
boot.binfmt.preferStaticEmulators = true;
|
||||
}
|
||||
@@ -1,7 +1,12 @@
|
||||
nextcloud:
|
||||
adminPass: ENC[AES256_GCM,data:D2SAD/Somvw8abIm0KX4fWRfuQ==,iv:Y7K14yZZFcu97KVBd0219hwnGY4LEX2DNxxulSegr/8=,tag:aRJAlz1xvQxWodcE2bZLdQ==,type:str]
|
||||
s3secret: ENC[AES256_GCM,data:lIVuiZMh376MSuu13UPCu49Q64bVbk+WM/CUEIGzV0Q=,iv:J2vHalppWEupWK07zXsMoiH6avmpsgg0Cqcc7EkZVV4=,tag:pxKwiaH5SZa8Vh71gLGQWw==,type:str]
|
||||
jellyfin-pia: ENC[AES256_GCM,data:rbqpmm2EtxcMeJfjlGaJOwPCn4UAZaKsH8Zeztk7A6QiSw==,iv:8A6NHVHgKIL6iwLKgRrT6T3k0pgDI5lL5rDMN5/Egrw=,tag:P6Kh9cOnrB23Z7S72xBK7g==,type:str]
|
||||
jellyfin-pia: ENC[AES256_GCM,data:hOgUAr47FMd2QgzgXBeqv41Paqy6zn6tyWVDbF1JtqcTog/zZC4=,iv:opnxrycFszAhuMARcP48gKF6eL1ERNgWS68wO+s4CIM=,tag:fqimxKdTAh55ANKD3bp46w==,type:str]
|
||||
ddclient: ENC[AES256_GCM,data:a31MKnoEZXrj/s8z3+MP9jhQ5/sBjljZphXBJsWj5GU=,iv:YHKCartadDQa59aUf9Fw/KgdgMgsqsVLDAIh/KeqehQ=,tag:hUaUqjcX75xw6eC9axtQmw==,type:str]
|
||||
anki: ENC[AES256_GCM,data:hUBKr/s1DDorlmbHDUvHtVSumw==,iv:Ekjt6dsncinHhM+dV/mxOjErBQpgKtPOVbmwGRy9XOE=,tag:zvfV9z3QROgsk4eznmxqDw==,type:str]
|
||||
tandoor-secret: ENC[AES256_GCM,data:/clEIU38M7lJ6+JbFSKWb5kKSUvxdGYPq2Hl9TjgijZtYIYFOleJQ9PiT+d/osmY/r0=,iv:Nulu93V+s9RBmEDRs2LXJXy7l0O/AeU0CwwtTNLGw2c=,tag:brRyVaWeUGLx1nt0MtcIEw==,type:str]
|
||||
tandoor-pass: ENC[AES256_GCM,data:Sjz2FuFm3bmqo9z2xckuIHq4qumQ2o/FA09DP7NQtngi,iv:M8BL8enwzGh4cp2hAtee99dC0VDxBvshNBiUp4QCVPQ=,tag:wMifwdLEMw4+M1EO5iywzw==,type:str]
|
||||
webdav: ENC[AES256_GCM,data:VLwkAn1Ly36c6E1Qkurz8+mfWiwh3SNOe37R0xKkQqpnUhsnTGDB1fWuf3J6jfhag3dMLemBj5JhQD/IYoP4QKk=,iv:TSpePZuzzv6I3NURNIFL8j6YivTEEJnvorRV/9Nanac=,tag:l2I6RsDsLNdw58L3GjL1Lg==,type:str]
|
||||
vaultenv: ENC[AES256_GCM,data:oTMhUU23v0SFImzDNjfqo3wn26ghqHGfArQl+K9E3u3YI9qmwdN/Z0dpLvT7TI01cdEIwM8ToKAd2HueymTHMT0wXMNAWMFVNm5lUot6U9kV+Pwfq3W+c8MygqXL/QVeFCzUsEa4ZvAE647+2JIkcI95H8mIWfenL0wA5O+OLiEz1fFykMbGBvWm7GM5oFWU9RXo0d5BAIaqd7D5oL3tgi2EnrtnVMJ8USgYA+d3TNCEatHO8ARwtCRhC8FK+86RowBlwiylIySuJiMScvzstB8TWVps4wo7xK0lZ8PUicFI2q+N+Q7B3x1hUW0Z2f4pmxAwb8qRxXZtA7B99bBjAwSwh1A301LYMAKJqELNiNOZ9xjl5r12fAOqP3ujJ84eacNVmsKFpA5HxIfUQBlkoHYRXfkd+Z8wz9fhzr53PvWHblr4eS+jCpJzSP98uyou4FYfMXoYOT9kzNNHGsWAoxLxQusehIaHyicG6uVE53wEQw/r9xeJeg==,iv:anKhX3TVyEeatnB/qjlce3g7cifrX8QlBJ/9UzWUa8k=,tag:BDccovkJBW8q0URMLBxbcQ==,type:str]
|
||||
minioRoot: ENC[AES256_GCM,data:z6+VkyRjWRSh8pu5gO58RRyGXT+Lvl+AVr37A5nXh6aj+q6SevNL7wLf9Joao4xmjXexKVavOhs/9OSBJpmbq0R+MRI=,iv:vrow7hvrTacnMi7sFnsuXwMOHrvr6c8YUTYFUry4E4U=,tag:fWfiEvkuSiXHIFqWnLiMiQ==,type:str]
|
||||
restic:
|
||||
@@ -9,10 +14,6 @@ restic:
|
||||
passwd: ENC[AES256_GCM,data:vUsAP5+iZo7U55xnUP7Cnk1OxnrO+paHKmT2cuc=,iv:GF7fybEQZIxHPm1Z6Sj5dn/zOR5dRVgikH8LILsTMIs=,tag:Mh61boRPsfHeiSfXmrEx5Q==,type:str]
|
||||
backblaze: ENC[AES256_GCM,data:IfWzuIYUrCGYpP68CPFi2vLqq9NVmiVyCE+Z8yi+cnaQwgwNL40lJEPL/U3d0lgsmrsV4GheNJ0oQ9tnrrJeBgZgwMl/CwXMctuUHo+cvVot/cNRd1vCdjRr7WUnw8737uxyW45OaaYbkZRa3NWEGDll1iFDWB2w4n5DTsomyO03tFZB5gckwQYmpjYmK4DcIWyTaEiDrznmkyM+sxoWv9pcTHZIIN7TCHHkzmlMzXXqJnoRfCpdVm/QF9jbrAYs,iv:tOa1FFyggm0ScoRdFk6tACOnQVcZMYaDqeJyX5SMKXc=,tag:EY5jQhZnLP6IzqY9garoEQ==,type:str]
|
||||
sops:
|
||||
kms: []
|
||||
gcp_kms: []
|
||||
azure_kv: []
|
||||
hc_vault: []
|
||||
age:
|
||||
- recipient: age1crymppz88etsdjpckmtdhr397x5xg5wv8jt6tcj23gt2snq73pzs04fuve
|
||||
enc: |
|
||||
@@ -23,8 +24,7 @@ sops:
|
||||
RVUzMlFya3Z0amdTUTJ5YjFRck5kZzQKoWZzExqzPRpQPL4CdqBalc1/dYtjBH6J
|
||||
LGR0oImfOWlIJwcaJLv/fc470UvXHHwIji9v/pbV7xMkgMjlJthaYg==
|
||||
-----END AGE ENCRYPTED FILE-----
|
||||
lastmodified: "2023-12-06T18:23:17Z"
|
||||
mac: ENC[AES256_GCM,data:WRuoG1B+DrhgL/KLUTmwiSOB58T52Ga6nA5K3LFOy4gu/hBCg85kndsVozJzY434PSY5w6Vposow4UvYQE/8xh8Y8lMlKZHZAMXxmnFvVdpL2bWe04qwBnAVXKj0Fru8sTNGPnRzDE6XETLdkRQyl//u5mFGDIDJeh1dV/VHUc0=,iv:W/VFGKabYdrNVY/GfNYMxTvdk/HO0Gh147t+xREU4+g=,tag:uLhXrb9V7wRx9EnaU7NWkQ==,type:str]
|
||||
pgp: []
|
||||
lastmodified: "2025-07-19T19:15:37Z"
|
||||
mac: ENC[AES256_GCM,data:RPGKe5f+5GUnGK3zybRrTnd8N4TprLWBEWLI2HI68Acf1MlJ1AMOWOhpi5xa0Hkxpah8D/d0CEH2ymaO5EBSUamPdYThI4g/4cxNBXboKnALSf91ZUty86/1+14TbI6vFCZ5ghjB4THxszGf47ajIDa/TjHx0yHFWDi7rpApmcw=,iv:ep/NlJfkIkQe5RJ4U2YfZ7/0S4vWqxjg+xrLLnJwfwI=,tag:c01jey2juzoPKux7n/0rug==,type:str]
|
||||
unencrypted_suffix: _unencrypted
|
||||
version: 3.8.1
|
||||
version: 3.10.2
|
||||
|
||||
@@ -13,15 +13,15 @@
|
||||
# ./private/grafana.nix
|
||||
|
||||
# Home Monitoring and Control
|
||||
./private/homeassistant.nix
|
||||
# ./private/homeassistant.nix
|
||||
|
||||
# Minio S3 Object Storage
|
||||
./private/miniio.nix
|
||||
|
||||
# OctoPrint
|
||||
./private/octoprint.nix
|
||||
# ./private/octoprint.nix
|
||||
|
||||
# Samba Share
|
||||
./private/samba.nix
|
||||
# ./private/samba.nix
|
||||
];
|
||||
}
|
||||
|
||||
@@ -6,9 +6,6 @@
|
||||
# Entrace to Control Pane of Private Network
|
||||
./public/headscale.nix
|
||||
|
||||
# Location tracking of my Dad in Saskatchewan
|
||||
./public/hauk.nix
|
||||
|
||||
# Self Hosted Git Server
|
||||
./public/gitea.nix
|
||||
|
||||
@@ -28,7 +25,7 @@
|
||||
./public/nextcloud.nix
|
||||
|
||||
# Rabb.it at home
|
||||
./public/watchthingz.nix
|
||||
# ./public/watchthingz.nix
|
||||
|
||||
# Pterodactyl Game Server
|
||||
./public/pterodactyl.nix
|
||||
@@ -38,5 +35,20 @@
|
||||
|
||||
# Anki Sync Server
|
||||
./public/anki.nix
|
||||
|
||||
# Public HASS Access
|
||||
./public/hass.nix
|
||||
|
||||
# Webdav (for things like org-mobile)
|
||||
./public/webdav.nix
|
||||
|
||||
# Recipe Manager
|
||||
./public/tandoor.nix
|
||||
|
||||
# Random Usage, specific port
|
||||
./public/random.nix
|
||||
|
||||
# Perfect Pitch Project
|
||||
./public/perfect_pitch.nix
|
||||
];
|
||||
}
|
||||
|
||||
@@ -4,15 +4,19 @@
|
||||
sops.secrets.anki = { };
|
||||
services.anki-sync-server = {
|
||||
enable = true;
|
||||
users.david = {
|
||||
username = "David";
|
||||
passwordFile = config.sops.secrets.anki.path;
|
||||
};
|
||||
port = 7333;
|
||||
address = "0.0.0.0";
|
||||
users = [
|
||||
{
|
||||
username = "David";
|
||||
passwordFile = config.sops.secrets.anki.path;
|
||||
}
|
||||
];
|
||||
};
|
||||
services.caddy.virtualHosts = {
|
||||
"anki.syzygial.cc" = {
|
||||
extraConfig = ''
|
||||
reverse_proxy 127.0.0.1:${config.services.anki-sync-server.port}
|
||||
reverse_proxy 127.0.0.1:${toString config.services.anki-sync-server.port}
|
||||
'';
|
||||
};
|
||||
};
|
||||
|
||||
@@ -35,7 +35,7 @@ in {
|
||||
|
||||
services.postgresql = {
|
||||
enable = true;
|
||||
port = 5432;
|
||||
settings.port = 5432;
|
||||
ensureDatabases = [
|
||||
"gitea"
|
||||
];
|
||||
|
||||
11
machines/hippocampus/servers/public/hass.nix
Normal file
11
machines/hippocampus/servers/public/hass.nix
Normal file
@@ -0,0 +1,11 @@
|
||||
{ config, pkgs, ... }:
|
||||
|
||||
{
|
||||
services.caddy.virtualHosts = {
|
||||
"home.syzygial.cc" = {
|
||||
extraConfig = ''
|
||||
reverse_proxy http://u.syzygial.cc:8123
|
||||
'';
|
||||
};
|
||||
};
|
||||
}
|
||||
@@ -1,14 +0,0 @@
|
||||
{pkgs, config, ...}:
|
||||
|
||||
{
|
||||
imports = [
|
||||
../../oci/hauk.nix
|
||||
];
|
||||
services.caddy.virtualHosts = {
|
||||
"crompton.cc" = {
|
||||
extraConfig = ''
|
||||
reverse_proxy 127.0.0.1:7888
|
||||
'';
|
||||
};
|
||||
};
|
||||
}
|
||||
@@ -23,9 +23,12 @@
|
||||
];
|
||||
|
||||
# Give a name to each device
|
||||
dns_config = {
|
||||
dns = {
|
||||
base_domain = "tailnet";
|
||||
magic_dns = true;
|
||||
nameservers.global = [
|
||||
"1.1.1.1"
|
||||
];
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
@@ -1,17 +1,7 @@
|
||||
{config, pkgs, ...}: let
|
||||
deploy-container = pkgs.writeScriptBin "deploy-nixos-container" ''
|
||||
pushd $2
|
||||
nixos-container update $1 --flake $2#$3
|
||||
git reset --hard HEAD
|
||||
git clean -fdx
|
||||
git reflog expire --expire=now --all
|
||||
git repack -ad # Remove dangling objects from packfiles
|
||||
git prune # Remove dangling loose objects
|
||||
popd
|
||||
'';
|
||||
in {
|
||||
imports = [
|
||||
./nix-serve.nix
|
||||
# ./nix-serve.nix
|
||||
];
|
||||
services.hydra = {
|
||||
enable = true;
|
||||
@@ -26,6 +16,9 @@ in {
|
||||
</dynamicruncommand>
|
||||
'';
|
||||
};
|
||||
nix.extraOptions = ''
|
||||
allowed-uris = https://github.com/ https://git.savannah.gnu.org/ https://git.syzygial.cc https://gitlab.com https://sr.ht github: gitlab: https://git.lix.systems
|
||||
'';
|
||||
systemd.services.hydra = {
|
||||
serviceConfig = {
|
||||
RestartSec = "20s";
|
||||
@@ -39,44 +32,15 @@ in {
|
||||
|
||||
];
|
||||
};
|
||||
# Deployment User
|
||||
users.users.hydra-deploy = {
|
||||
isNormalUser = true;
|
||||
home = "/var/lib/hydra/deploy";
|
||||
description = "Hydra Deployment User";
|
||||
extraGroups = [ "hydra" ];
|
||||
packages = [
|
||||
deploy-container
|
||||
];
|
||||
};
|
||||
# TODO: Configure authorizedKeys between
|
||||
# hydra-queue-runner and hydra-deploy
|
||||
security.sudo.extraRules = [
|
||||
{
|
||||
users = ["hydra-deploy"];
|
||||
commands = [
|
||||
{
|
||||
command = "${deploy-container}/bin/deploy-nixos-container *";
|
||||
options = ["NOPASSWD"];
|
||||
}
|
||||
];
|
||||
}
|
||||
];
|
||||
networking.nat = {
|
||||
enable = true;
|
||||
internalInterfaces = [
|
||||
"ve-newalan"
|
||||
"ve-handyhelper"
|
||||
];
|
||||
externalInterface = "enp0s25";
|
||||
enableIPv6 = true;
|
||||
};
|
||||
|
||||
|
||||
nix.buildMachines = [
|
||||
{ hostName = "localhost";
|
||||
system = "x86_64-linux";
|
||||
systems = [
|
||||
"x86_64-linux"
|
||||
"riscv64-linux"
|
||||
];
|
||||
supportedFeatures = ["kvm" "nixos-test" "big-parallel" "benchmark"];
|
||||
maxJobs = 8;
|
||||
maxJobs = 16;
|
||||
}
|
||||
];
|
||||
services.caddy.virtualHosts = {
|
||||
|
||||
@@ -13,29 +13,30 @@ in {
|
||||
|
||||
services.nextcloud = {
|
||||
enable = true;
|
||||
package = pkgs.nextcloud27;
|
||||
package = pkgs.nextcloud32;
|
||||
hostName = "localhost";
|
||||
settings = {
|
||||
trusted_domains = [
|
||||
"cloud.crompton.cc"
|
||||
"nextcloud.syzygial.cc"
|
||||
];
|
||||
|
||||
trusted_proxies = [
|
||||
"127.0.0.1"
|
||||
];
|
||||
|
||||
overwriteprotocol = "https";
|
||||
};
|
||||
|
||||
config = {
|
||||
adminuser = "CromptonAdmin";
|
||||
adminpassFile = config.sops.secrets."nextcloud/adminPass".path;
|
||||
|
||||
extraTrustedDomains = [
|
||||
"cloud.crompton.cc"
|
||||
"nextcloud.syzygial.cc"
|
||||
];
|
||||
|
||||
trustedProxies = [
|
||||
"cloud.crompton.cc"
|
||||
"nextcloud.syzygial.cc"
|
||||
];
|
||||
|
||||
dbtype = "pgsql";
|
||||
dbname = "nextcloud";
|
||||
dbuser = "nextcloud";
|
||||
|
||||
dbhost = "/run/postgresql";
|
||||
overwriteProtocol = "https";
|
||||
|
||||
objectstore.s3 = {
|
||||
enable = true;
|
||||
@@ -74,7 +75,7 @@ in {
|
||||
shell = pkgs.bashInteractive;
|
||||
packages = with pkgs; [
|
||||
# generate video thumbnails with preview generator
|
||||
ffmpeg_5-headless
|
||||
ffmpeg_7-headless
|
||||
# required for recognize app
|
||||
nodejs_20 # runtime and installation requirement
|
||||
nodejs_20.pkgs.node-pre-gyp # installation requirement
|
||||
@@ -97,7 +98,7 @@ in {
|
||||
|
||||
services.postgresql = {
|
||||
enable = true;
|
||||
port = 5432;
|
||||
settings.port = 5432;
|
||||
ensureDatabases = [
|
||||
"nextcloud"
|
||||
];
|
||||
|
||||
@@ -36,7 +36,7 @@
|
||||
|
||||
services.postgresql = {
|
||||
enable = true;
|
||||
port = 5432;
|
||||
settings.port = 5432;
|
||||
ensureDatabases = [
|
||||
"onlyoffice"
|
||||
];
|
||||
|
||||
52
machines/hippocampus/servers/public/perfect_pitch.nix
Normal file
52
machines/hippocampus/servers/public/perfect_pitch.nix
Normal file
@@ -0,0 +1,52 @@
|
||||
{config, pkgs, ...}:
|
||||
|
||||
{
|
||||
systemd.targets.machines.enable = true;
|
||||
systemd.services."perfectpitch-container" = {
|
||||
enable = true;
|
||||
wantedBy = ["machines.target"];
|
||||
environment = {
|
||||
# SYSTEMD_NSPAWN_USE_CGNS = "0";
|
||||
};
|
||||
script = ''
|
||||
exec ${config.systemd.package}/bin/systemd-nspawn --hostname perfectpitch \
|
||||
--resolv-conf=off --system-call-filter="add_key keyctl bpf" --bind /dev/fuse \
|
||||
-nbD /var/lib/machines/perfectpitch --machine perfectpitch
|
||||
'';
|
||||
postStart = ''
|
||||
${pkgs.iproute2}/bin/ip link set ve-perfectpitch up || true
|
||||
${pkgs.iproute2}/bin/ip addr add 10.2.0.0 dev ve-perfectpitch || true
|
||||
${pkgs.iproute2}/bin/ip route add 10.2.0.1 dev ve-perfectpitch || true
|
||||
'';
|
||||
serviceConfig = {
|
||||
Type = "notify";
|
||||
Slice = "machine.slice";
|
||||
Delegate = true;
|
||||
DeviceAllow = "/dev/fuse rwm";
|
||||
};
|
||||
};
|
||||
networking.nat = {
|
||||
enable = true;
|
||||
# Check for hostBridge use vb instead of ve
|
||||
internalInterfaces = ["ve-perfectpitch"];
|
||||
externalInterface = "enp0s25";
|
||||
enableIPv6 = true;
|
||||
forwardPorts = [
|
||||
{ sourcePort = 8022;
|
||||
destination = "10.2.0.1:22";
|
||||
proto = "tcp";
|
||||
}
|
||||
{ sourcePort = 8022;
|
||||
destination = "10.2.0.1:22";
|
||||
proto = "udp";
|
||||
}
|
||||
];
|
||||
};
|
||||
services.caddy.virtualHosts = {
|
||||
"pitch.crompton.cc" = {
|
||||
extraConfig = ''
|
||||
reverse_proxy 10.2.0.1:8080
|
||||
'';
|
||||
};
|
||||
};
|
||||
}
|
||||
@@ -32,11 +32,11 @@
|
||||
externalInterface = "enp0s25";
|
||||
enableIPv6 = true;
|
||||
forwardPorts = [
|
||||
{ sourcePort = "25565:28000";
|
||||
{ sourcePort = "25565:26000";
|
||||
destination = "10.1.0.1:25565-25600";
|
||||
proto = "tcp";
|
||||
}
|
||||
{ sourcePort = "25565:28000";
|
||||
{ sourcePort = "25565:26000";
|
||||
destination = "10.1.0.1:25565-25600";
|
||||
proto = "udp";
|
||||
}
|
||||
@@ -52,11 +52,17 @@
|
||||
};
|
||||
services.caddy.virtualHosts = {
|
||||
"games.syzygial.cc:443" = {
|
||||
serverAliases = [
|
||||
"games.crompton.cc:443"
|
||||
];
|
||||
extraConfig = ''
|
||||
reverse_proxy 10.1.0.1:80
|
||||
'';
|
||||
};
|
||||
"games.syzygial.cc:9000" = {
|
||||
serverAliases = [
|
||||
"games.crompton.cc:9000"
|
||||
];
|
||||
extraConfig = ''
|
||||
reverse_proxy 10.1.0.1:9000
|
||||
'';
|
||||
|
||||
9
machines/hippocampus/servers/public/random.nix
Normal file
9
machines/hippocampus/servers/public/random.nix
Normal file
@@ -0,0 +1,9 @@
|
||||
{ config, pkgs, lib, ... }: {
|
||||
services.caddy.virtualHosts = {
|
||||
"pitch.syzygial.cc" = {
|
||||
extraConfig = ''
|
||||
reverse_proxy 127.0.0.1:7123
|
||||
'';
|
||||
};
|
||||
};
|
||||
}
|
||||
@@ -10,5 +10,12 @@
|
||||
}
|
||||
'';
|
||||
};
|
||||
"crompton.cc" = {
|
||||
extraConfig = ''
|
||||
file_server {
|
||||
root /srv/www/crompton
|
||||
}
|
||||
'';
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
50
machines/hippocampus/servers/public/tandoor.nix
Normal file
50
machines/hippocampus/servers/public/tandoor.nix
Normal file
@@ -0,0 +1,50 @@
|
||||
{ config, pkgs, lib, ... }: let
|
||||
tandoor_user = "tandoor";
|
||||
in {
|
||||
sops.secrets.tandoor-secret = {};
|
||||
sops.secrets.tandoor-pass = {};
|
||||
services.tandoor-recipes = {
|
||||
enable = true;
|
||||
port = 7666;
|
||||
extraConfig = {
|
||||
SECRET_KEY = config.sops.secrets.tandoor-secret.path;
|
||||
DB_ENGINE = "django.db.backends.postgresql";
|
||||
POSTGRES_HOST = "127.0.0.1";
|
||||
POSTGRES_PORT = config.services.postgresql.port;
|
||||
POSTGRES_USER = tandoor_user;
|
||||
POSTGRES_DB = tandoor_user;
|
||||
ENABLE_SIGNUP = "1";
|
||||
};
|
||||
};
|
||||
|
||||
systemd.services.tandoor-recipes = {
|
||||
# https://github.com/TandoorRecipes/recipes/issues/3617
|
||||
environment.GUNICORN_MEDIA = "1"; #lib.mkForce null;
|
||||
serviceConfig = {
|
||||
EnvironmentFile = config.sops.secrets.tandoor-pass.path;
|
||||
};
|
||||
};
|
||||
|
||||
services.postgresql = {
|
||||
enable = true;
|
||||
settings.port = 5432;
|
||||
ensureDatabases = [
|
||||
tandoor_user
|
||||
];
|
||||
ensureUsers = [{
|
||||
name = tandoor_user;
|
||||
ensureDBOwnership = true;
|
||||
ensureClauses = {
|
||||
createdb = true;
|
||||
};
|
||||
}];
|
||||
};
|
||||
|
||||
services.caddy.virtualHosts = {
|
||||
"tandoor.syzygial.cc" = {
|
||||
extraConfig = ''
|
||||
reverse_proxy 127.0.0.1:${toString config.services.tandoor-recipes.port}
|
||||
'';
|
||||
};
|
||||
};
|
||||
}
|
||||
@@ -16,7 +16,7 @@
|
||||
};
|
||||
services.postgresql = {
|
||||
enable = true;
|
||||
port = 5432;
|
||||
settings.port = 5432;
|
||||
ensureDatabases = [
|
||||
"vaultwarden"
|
||||
];
|
||||
|
||||
31
machines/hippocampus/servers/public/webdav.nix
Normal file
31
machines/hippocampus/servers/public/webdav.nix
Normal file
@@ -0,0 +1,31 @@
|
||||
{ config, pkgs, lib, ... }: {
|
||||
users.users.webdav = {
|
||||
shell = pkgs.bashInteractive;
|
||||
};
|
||||
sops.secrets.webdav = {
|
||||
owner = config.services.webdav.user;
|
||||
};
|
||||
services.webdav = {
|
||||
enable = true;
|
||||
settings = {
|
||||
address = "0.0.0.0";
|
||||
port = 7350;
|
||||
scope = "/srv/webdav";
|
||||
modify = true;
|
||||
auth = true;
|
||||
users = [{
|
||||
username = "{env}ORG_MOBILE_USER";
|
||||
password = "{env}ORG_MOBILE_PASS";
|
||||
}];
|
||||
};
|
||||
environmentFile = config.sops.secrets.webdav.path;
|
||||
};
|
||||
|
||||
services.caddy.virtualHosts = {
|
||||
"webdav.syzygial.cc" = {
|
||||
extraConfig = ''
|
||||
reverse_proxy 127.0.0.1:${toString config.services.webdav.settings.port}
|
||||
'';
|
||||
};
|
||||
};
|
||||
}
|
||||
@@ -1,5 +1,6 @@
|
||||
{
|
||||
imports = [
|
||||
./services/tailscale.nix
|
||||
./services/dyndns.nix
|
||||
];
|
||||
}
|
||||
|
||||
14
machines/hippocampus/services/dyndns.nix
Normal file
14
machines/hippocampus/services/dyndns.nix
Normal file
@@ -0,0 +1,14 @@
|
||||
{ config, pkgs, lib, ... }: {
|
||||
sops.secrets.ddclient = {};
|
||||
services.ddclient = {
|
||||
enable = true;
|
||||
usev4 = "webv4, web=dynamicdns.park-your-domain.com/getip";
|
||||
protocol = "namecheap";
|
||||
server = "dynamicdns.park-your-domain.com";
|
||||
username = "crompton.cc";
|
||||
passwordFile = config.sops.secrets.ddclient.path;
|
||||
domains = [
|
||||
"@"
|
||||
];
|
||||
};
|
||||
}
|
||||
29
machines/pericyte/configuration.nix
Normal file
29
machines/pericyte/configuration.nix
Normal file
@@ -0,0 +1,29 @@
|
||||
{ pkgs, inputs, ... }: {
|
||||
imports = [
|
||||
./hardware-configuration.nix
|
||||
"${inputs.nixpkgs}/nixos/modules/profiles/headless.nix"
|
||||
"${inputs.nixpkgs}/nixos/modules/profiles/minimal.nix"
|
||||
|
||||
./podman.nix
|
||||
./container-registry.nix
|
||||
# ./microvm-configuration.nix
|
||||
# ./k3s.nix
|
||||
];
|
||||
|
||||
nix.settings.experimental-features = [ "nix-command" "flakes" ];
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
git
|
||||
btop
|
||||
tmux
|
||||
oci-cli
|
||||
];
|
||||
|
||||
boot.tmp.cleanOnBoot = true;
|
||||
# zramSwap.enable = true;
|
||||
networking.hostName = "pericyte";
|
||||
networking.domain = "";
|
||||
services.openssh.enable = true;
|
||||
users.users.root.openssh.authorizedKeys.keys = [''ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQDOaNNSV/wurGA8D7bT+WX4UlHdKqd9SFfVXvSalvHag5qYDPUIsGGkqSNj1dcong9qxrC8y7G7ybWhwRKTKXInXrq6EO4JkVkCSbVqrq8gIv66upsKltvmf0esiOdrpRgHoiup8JKaX93aUT27rykReT39mFwkJZDoD4ViNiK7QmbgDC/9pyGDSJykreSnBoxtczox8Zi+pwN8XMI4nRVdV9hppXMpj38/O3Qaq+oXdHJ2MVNy9D+TqxYofstFbzpJpEb2xA4QYnq/VVJFk8VaZlg3qxelwBJ1GNZO8TMkLA+6b07D3aISyEIQAONviNktPwRPiw903hsDyeKDunDx ssh-key-2025-03-31'' ];
|
||||
system.stateVersion = "25.05";
|
||||
}
|
||||
6
machines/pericyte/container-registry.nix
Normal file
6
machines/pericyte/container-registry.nix
Normal file
@@ -0,0 +1,6 @@
|
||||
{ pkgs, ... }: {
|
||||
services.dockerRegistry = {
|
||||
enable = true;
|
||||
package = pkgs.distribution;
|
||||
};
|
||||
}
|
||||
18
machines/pericyte/hardware-configuration.nix
Normal file
18
machines/pericyte/hardware-configuration.nix
Normal file
@@ -0,0 +1,18 @@
|
||||
{ modulesPath, ... }:
|
||||
{
|
||||
imports = [ (modulesPath + "/profiles/qemu-guest.nix") ];
|
||||
boot.loader.grub = {
|
||||
efiSupport = true;
|
||||
efiInstallAsRemovable = true;
|
||||
device = "nodev";
|
||||
};
|
||||
fileSystems."/boot" = { device = "/dev/disk/by-uuid/FCE4-1F46"; fsType = "vfat"; };
|
||||
fileSystems."/" = { device = "/dev/sda1"; fsType = "ext4"; };
|
||||
swapDevices = [
|
||||
{
|
||||
device = "/swapfile";
|
||||
}
|
||||
];
|
||||
boot.initrd.availableKernelModules = [ "ata_piix" "uhci_hcd" "xen_blkfront" "vmw_pvscsi" ];
|
||||
boot.initrd.kernelModules = [ "nvme" ];
|
||||
}
|
||||
22
machines/pericyte/k3s.nix
Normal file
22
machines/pericyte/k3s.nix
Normal file
@@ -0,0 +1,22 @@
|
||||
{ pkgs, ... }: {
|
||||
networking.firewall = {
|
||||
allowedTCPPorts = [
|
||||
6443 # k3s: required so that pods can reach the API server (running on port 6443 by default)
|
||||
# 2379 # k3s, etcd clients: required if using a "High Availability Embedded etcd" configuration
|
||||
# 2380 # k3s, etcd peers: required if using a "High Availability Embedded etcd" configuration
|
||||
];
|
||||
allowedUDPPorts = [
|
||||
# 8472 # k3s, flannel: required if using multi-node for inter-node networking
|
||||
];
|
||||
};
|
||||
services.k3s = {
|
||||
enable = true;
|
||||
role = "server";
|
||||
extraFlags = toString [
|
||||
# "--debug" # Optionally add additional args to k3s
|
||||
];
|
||||
};
|
||||
environment.systemPackages = with pkgs; [
|
||||
rancher
|
||||
];
|
||||
}
|
||||
6
machines/pericyte/microvm-configuration.nix
Normal file
6
machines/pericyte/microvm-configuration.nix
Normal file
@@ -0,0 +1,6 @@
|
||||
{ pkgs, ... }: {
|
||||
microvm.autostart = [
|
||||
"vm-starbot"
|
||||
"vm-starbot-dev"
|
||||
];
|
||||
}
|
||||
21
machines/pericyte/podman.nix
Normal file
21
machines/pericyte/podman.nix
Normal file
@@ -0,0 +1,21 @@
|
||||
{ pkgs, ... }: {
|
||||
# Enable common container config files in /etc/containers
|
||||
virtualisation.containers.enable = true;
|
||||
virtualisation = {
|
||||
podman = {
|
||||
enable = true;
|
||||
|
||||
# Required for containers under podman-compose to be able to talk to each other.
|
||||
defaultNetwork.settings.dns_enabled = true;
|
||||
};
|
||||
};
|
||||
|
||||
# Useful other development tools
|
||||
environment.systemPackages = with pkgs; [
|
||||
dive # look into docker image layers
|
||||
skopeo # Inspect images
|
||||
podlet # create quadlets (systemd units)
|
||||
podman-tui # status of containers in the terminal
|
||||
podman-compose # start group of containers for dev
|
||||
];
|
||||
}
|
||||
32
machines/pericyte/test.nix
Normal file
32
machines/pericyte/test.nix
Normal file
@@ -0,0 +1,32 @@
|
||||
{ pkgs, ... }: {
|
||||
users.groups.peertube = { };
|
||||
users.users.peertube = {
|
||||
isSystemUser = true;
|
||||
group = "peertube";
|
||||
home = "/var/lib/peertube";
|
||||
createHome = true;
|
||||
uid = 2342;
|
||||
subUidRanges = [
|
||||
{
|
||||
count = 65536;
|
||||
startUid = 2147483646;
|
||||
}
|
||||
];
|
||||
subGidRanges = [
|
||||
{
|
||||
count = 65536;
|
||||
startGid = 2147483647;
|
||||
}
|
||||
];
|
||||
};
|
||||
virtualisation.oci-containers = {
|
||||
backend = "podman";
|
||||
# containers.peertube = {
|
||||
# image = "chocobozzz/peertube:latest";
|
||||
# ports = [ ];
|
||||
# podman = {
|
||||
# user = "peertube";
|
||||
# };
|
||||
# };
|
||||
};
|
||||
}
|
||||
@@ -11,7 +11,7 @@
|
||||
rm -rf "$nix_apps"
|
||||
mkdir -p "$nix_apps"
|
||||
find ${config.system.build.applications}/Applications -maxdepth 1 -type l -exec readlink '{}' + |
|
||||
while read src; do
|
||||
while read -r src; do
|
||||
# Spotlight does not recognize symlinks, it will ignore directory we link to the applications folder.
|
||||
# It does understand MacOS aliases though, a unique filesystem feature. Sadly they cannot be created
|
||||
# from bash (as far as I know), so we use the oh-so-great Apple Script instead.
|
||||
|
||||
@@ -3,7 +3,7 @@ in
|
||||
{
|
||||
imports = [
|
||||
# Install Apps Detactable by Spotlight
|
||||
./app-fix.nix
|
||||
# ./app-fix.nix
|
||||
# Tiling Window Manager
|
||||
./yabai.nix
|
||||
# Shortcuts babe, not Automator
|
||||
@@ -11,10 +11,12 @@ in
|
||||
];
|
||||
nix.registry.nixpkgs.flake = inputs.nixpkgs;
|
||||
nixpkgs.config.allowUnfree = true;
|
||||
# Auto upgrade nix package and the daemon service.
|
||||
services.nix-daemon.enable = true;
|
||||
nix.package = pkgs.nixUnstable;
|
||||
# nix.package = pkgs.nixUnstable;
|
||||
nix.settings.auto-optimise-store = false;
|
||||
nix.settings.trusted-users = [
|
||||
"root"
|
||||
"universelaptop"
|
||||
];
|
||||
|
||||
users.users.universelaptop = {
|
||||
name = "universelaptop";
|
||||
@@ -40,28 +42,126 @@ in
|
||||
};
|
||||
};
|
||||
home.stateVersion = "22.05";
|
||||
# TODO: https://nohzafk.github.io/posts/2023-12-18-nix-emacs-treesit-grammars/
|
||||
# home.file = {
|
||||
# # tree-sitter subdirectory of the directory specified by user-emacs-directory
|
||||
# ".config/emacs/.local/cache/tree-sitter".source =
|
||||
# "${emacs29.treesitGrammars}/lib";
|
||||
# };
|
||||
};
|
||||
};
|
||||
|
||||
environment.variables = {
|
||||
EDITOR = "emacs";
|
||||
fonts.packages = with pkgs; [
|
||||
julia-mono
|
||||
bqn386
|
||||
];
|
||||
|
||||
services.emacs = {
|
||||
# Emacsclient behaving weirdly
|
||||
# enable = true;
|
||||
package = pkgs.me-emacs;
|
||||
};
|
||||
|
||||
environment.variables = {
|
||||
EDITOR = "emacs -nw";
|
||||
VISUAL = "emacs";
|
||||
};
|
||||
|
||||
nixpkgs.overlays = [
|
||||
(final: prev: {
|
||||
skia-aseprite = prev.skia-aseprite.overrideAttrs (old: {
|
||||
postPatch = (old.postPatch or "") + ''
|
||||
sed -i -e 's/"-march=armv7-a",//g' gn/skia/BUILD.gn
|
||||
'';
|
||||
buildInputs = old.buildInputs ++ [
|
||||
final.xcbuild
|
||||
final.darwin.apple_sdk.frameworks.ApplicationServices
|
||||
];
|
||||
meta.maintainers = with pkgs.lib.maintainers; [
|
||||
davidcromp
|
||||
];
|
||||
});
|
||||
aseprite = prev.aseprite.overrideAttrs (old: {
|
||||
cmakeFlags = [
|
||||
"-DENABLE_DESKTOP_INTEGRATION=OFF"
|
||||
"-DENABLE_UPDATER=OFF"
|
||||
"-DUSE_SHARED_CMARK=ON"
|
||||
"-DUSE_SHARED_CURL=ON"
|
||||
"-DUSE_SHARED_FMT=ON"
|
||||
"-DUSE_SHARED_FREETYPE=ON"
|
||||
"-DUSE_SHARED_GIFLIB=ON"
|
||||
"-DUSE_SHARED_HARFBUZZ=ON"
|
||||
"-DUSE_SHARED_JPEGLIB=ON"
|
||||
"-DUSE_SHARED_LIBPNG=ON"
|
||||
"-DPNG_ARM_NEON:STRING=on"
|
||||
"-DUSE_SHARED_LIBWEBP=ON"
|
||||
"-DUSE_SHARED_PIXMAN=ON"
|
||||
"-DUSE_SHARED_TINYXML=ON"
|
||||
"-DUSE_SHARED_WEBP=ON"
|
||||
"-DUSE_SHARED_ZLIB=ON"
|
||||
# Disable libarchive programs.
|
||||
"-DENABLE_CAT=OFF"
|
||||
"-DENABLE_CPIO=OFF"
|
||||
"-DENABLE_TAR=OFF"
|
||||
# UI backend.
|
||||
"-DLAF_OS_BACKEND=skia"
|
||||
"-DLAF_WITH_EXAMPLES=OFF"
|
||||
"-DSKIA_DIR=${final.skia-aseprite}"
|
||||
"-DSKIA_LIBRARY_DIR=${final.skia-aseprite}/lib"
|
||||
"-DSKIA_LIBRARYR=${final.skia-aseprite}/lib/libskia.a"
|
||||
];
|
||||
buildInputs = with pkgs; [
|
||||
cmark
|
||||
curl
|
||||
fmt
|
||||
fontconfig
|
||||
freetype
|
||||
giflib
|
||||
glib
|
||||
harfbuzzFull
|
||||
libjpeg
|
||||
libpng
|
||||
libwebp
|
||||
pcre2
|
||||
pixman
|
||||
skia-aseprite
|
||||
tinyxml-2
|
||||
zlib
|
||||
|
||||
# MacOS:
|
||||
] ++ (with darwin.apple_sdk.frameworks; [
|
||||
Cocoa
|
||||
QuickLook
|
||||
Quartz
|
||||
]);
|
||||
|
||||
hardeningDisable = [
|
||||
"format" # Darwin Specific
|
||||
];
|
||||
meta.broken = false;
|
||||
});
|
||||
})
|
||||
];
|
||||
|
||||
environment.systemPackages = (with pkgs; [
|
||||
mac-emacs
|
||||
me-emacs
|
||||
svgbob
|
||||
(aspellWithDicts (p: with p;[
|
||||
en
|
||||
en-computers
|
||||
en-science
|
||||
]))
|
||||
pandoc
|
||||
texlive.combined.scheme-full
|
||||
texliveFull
|
||||
wget
|
||||
|
||||
#xquartz
|
||||
kitty
|
||||
|
||||
btop
|
||||
|
||||
remmina
|
||||
|
||||
cbqn-replxx
|
||||
|
||||
# Graphical Apps:
|
||||
@@ -69,7 +169,12 @@ in
|
||||
tailscale
|
||||
discord
|
||||
slack
|
||||
gimp
|
||||
# aseprite
|
||||
# TODO: Consider using Yabai??
|
||||
|
||||
# Games
|
||||
prismlauncher
|
||||
]);
|
||||
|
||||
homebrew = {
|
||||
@@ -85,12 +190,26 @@ in
|
||||
"nextcloud"
|
||||
"tidal"
|
||||
"bitwarden"
|
||||
"zoom-for-it-admins"
|
||||
"libreoffice"
|
||||
"tailscale"
|
||||
"godot"
|
||||
"pixelorama"
|
||||
"blender"
|
||||
"inkscape"
|
||||
];
|
||||
# Apps to install outside of nix for when wanting to test/run
|
||||
# things that... aren't used by other people who use nix, like
|
||||
# python apps (which is why poetry is there)
|
||||
brews = [
|
||||
"poetry"
|
||||
"pdm"
|
||||
"python@3.11"
|
||||
"python@3.10"
|
||||
"pygments"
|
||||
# sudo ln -sfn /opt/homebrew/opt/openjdk/libexec/openjdk.jdk \
|
||||
# /Library/Java/JavaVirtualMachines/openjdk.jdk
|
||||
"openjdk"
|
||||
];
|
||||
};
|
||||
|
||||
@@ -101,4 +220,5 @@ in
|
||||
# Used for backwards compatibility, please read the changelog before changing.
|
||||
# $ darwin-rebuild changelog
|
||||
system.stateVersion = 4;
|
||||
system.primaryUser = "universelaptop";
|
||||
}
|
||||
|
||||
18
machines/universeair/libresprite_TODO_PR.nix
Normal file
18
machines/universeair/libresprite_TODO_PR.nix
Normal file
@@ -0,0 +1,18 @@
|
||||
(libresprite.overrideAttrs (old: {
|
||||
src = pkgs.fetchFromGitHub {
|
||||
owner = "LibreSprite";
|
||||
repo = "LibreSprite";
|
||||
rev = "c99d3666b17ff731824e3eccc79cf3ec48564ad5";
|
||||
fetchSubmodules = true;
|
||||
sha256 = "sha256-mdMdHQvl6Mt0oisZ4c/Wk6dvklq3Iyz05brbFxSIaj0=";
|
||||
};
|
||||
patches = [];
|
||||
buildInputs = old.buildInputs ++ (with pkgs; [
|
||||
libarchive
|
||||
tinyxml-2
|
||||
]);
|
||||
postPatch = ''
|
||||
sed -i -e 's/if(''${CMAKE_SYSTEM_NAME} MATCHES "Darwin")/if(FALSE)/' CMakeLists.txt
|
||||
'';
|
||||
meta.broken = false;
|
||||
}))
|
||||
@@ -2,8 +2,8 @@
|
||||
services.skhd = {
|
||||
enable = true;
|
||||
skhdConfig = ''
|
||||
cmd + shift - e : open ${pkgs.mac-emacs}/Applications/Emacs.app
|
||||
cmd + shift + ctrl - e : open ${pkgs.kitty}/Applications/Kitty.app
|
||||
cmd + shift - e : open '${(pkgs.me-emacs.override {withNativeCompilation = false;})}/Applications/Emacs.app'
|
||||
cmd + shift + ctrl - e : kitty -d ~ -1
|
||||
'';
|
||||
};
|
||||
}
|
||||
|
||||
@@ -8,7 +8,9 @@
|
||||
yabai
|
||||
];
|
||||
services.yabai = {
|
||||
enable = true;
|
||||
# Needs heavy configuration
|
||||
enable = false;
|
||||
enableScriptingAddition = true;
|
||||
config = {
|
||||
layout = "bsp";
|
||||
focus_follows_mouse = "autofocus";
|
||||
@@ -25,19 +27,7 @@
|
||||
yabai -m rule --add app='System Settings' manage=off
|
||||
yabai -m rule --add app='Boot Camp Assistant' manage=off
|
||||
yabai -m rule --add app='System Information' manage=off
|
||||
yabai -m rule --add title='^Figure' manage=off
|
||||
'';
|
||||
};
|
||||
|
||||
# https://github.com/IvarWithoutBones/dotfiles/blob/main/modules/darwin/yabai/default.nix
|
||||
# The scripting addition needs root access to load, which we want to do automatically when logging in.
|
||||
# Disable the password requirement for it so that a service can do so without user interaction.
|
||||
environment.etc."sudoers.d/yabai-load-sa".text = ''
|
||||
universelaptop ALL = (root) NOPASSWD: sha256:${builtins.hashFile "sha256" "${pkgs.yabai}/bin/yabai"} ${pkgs.yabai}/bin/yabai
|
||||
'';
|
||||
|
||||
launchd.user.agents.yabai-load-sa = {
|
||||
path = [ pkgs.yabai config.environment.systemPath ];
|
||||
command = "/usr/bin/sudo ${pkgs.yabai}/bin/yabai --load-sa";
|
||||
serviceConfig.RunAtLoad = true;
|
||||
};
|
||||
}
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
{ config, pkgs, lib, ... }: {
|
||||
nixpkgs.overlays = [
|
||||
(self: super: {
|
||||
ccacheWrapper = super.ccacheWrapper.override {
|
||||
extraConfig = ''
|
||||
nixpkgs.overlays = [
|
||||
(self: super: {
|
||||
ccacheWrapper = super.ccacheWrapper.override {
|
||||
extraConfig = ''
|
||||
export CCACHE_COMPRESS=1
|
||||
export CCACHE_DIR="${config.programs.ccache.cacheDir}"
|
||||
export CCACHE_UMASK=007
|
||||
@@ -23,8 +23,22 @@ nixpkgs.overlays = [
|
||||
exit 1
|
||||
fi
|
||||
'';
|
||||
};
|
||||
})
|
||||
];
|
||||
nix.settings.extra-sandbox-paths = [ config.programs.ccache.cacheDir ];
|
||||
};
|
||||
})
|
||||
];
|
||||
nix.settings.extra-sandbox-paths = [ config.programs.ccache.cacheDir ];
|
||||
nix.settings = {
|
||||
substituters = [
|
||||
"https://cuda-maintainers.cachix.org"
|
||||
];
|
||||
trusted-substituters = [
|
||||
"https://cuda-maintainers.cachix.org"
|
||||
];
|
||||
trusted-public-keys = [
|
||||
"cuda-maintainers.cachix.org-1:0dq3bujKpuEPMCX6U4WylrUDZ9JyUG0VpVZa7CNfq5E="
|
||||
];
|
||||
trusted-users = [
|
||||
"universe"
|
||||
];
|
||||
};
|
||||
}
|
||||
|
||||
@@ -2,9 +2,9 @@
|
||||
# your system. Help is available in the configuration.nix(5) man page
|
||||
# and in the NixOS manual (accessible by running ‘nixos-help’).
|
||||
|
||||
{ lib, config, pkgs, nixpkgs, ... }: {
|
||||
{ lib, config, pkgs, inputs, ... }: {
|
||||
nix.settings.auto-optimise-store = true;
|
||||
nix.registry.nixpkgs.flake = nixpkgs;
|
||||
nix.registry.nixpkgs.flake = inputs.nixpkgs;
|
||||
|
||||
# Allow user-mode qemu for running riscv64 binaries
|
||||
# boot.binfmt.emulatedSystems = [ "riscv64-linux" ];
|
||||
@@ -13,6 +13,10 @@
|
||||
[ # Include the results of the hardware scan.
|
||||
./hardware-configuration.nix
|
||||
|
||||
# Desktop/Graphical Things defined:
|
||||
./desktop/default.nix
|
||||
./fonts.nix
|
||||
|
||||
# Secrets specified via:
|
||||
./secrets.nix
|
||||
|
||||
@@ -30,6 +34,9 @@
|
||||
|
||||
# ccache, y'know for blenders and whatnots
|
||||
./ccache.nix
|
||||
|
||||
# So we can run riscv 'natively'
|
||||
./riscv.nix
|
||||
];
|
||||
|
||||
fileSystems."/home/universe/tmp" = {
|
||||
@@ -50,14 +57,15 @@
|
||||
networking.useDHCP = false;
|
||||
networking.interfaces.wlp6s0.useDHCP = true;
|
||||
# Fixes DNS issue with tailscale: https://github.com/tailscale/tailscale/issues/4254
|
||||
services.resolved.enable = true;
|
||||
#services.resolved.enable = true;
|
||||
networking.resolvconf.enable = true;
|
||||
|
||||
sops.secrets.wireless = { };
|
||||
networking.wireless.environmentFile = config.sops.secrets.wireless.path;
|
||||
networking.wireless.secretsFile = config.sops.secrets.wireless.path;
|
||||
|
||||
networking.wireless.enable = true;
|
||||
networking.wireless.networks = {
|
||||
"@SSID_HOME@".psk = "@PSK_HOME@";
|
||||
"BELL422".pskRaw = "ext:PSK_HOME";
|
||||
};
|
||||
|
||||
hardware.bluetooth.enable = true;
|
||||
@@ -82,75 +90,12 @@
|
||||
|
||||
users.users.brltty.isSystemUser = true;
|
||||
|
||||
# Enable the X11 windowing system.
|
||||
services.xserver.enable = true;
|
||||
|
||||
# Enable the GNOME Desktop Environment.
|
||||
services.xserver.displayManager.sddm.enable = true;
|
||||
services.xserver.desktopManager.plasma5.enable = true;
|
||||
programs.xwayland.enable = true;
|
||||
|
||||
# Configure keymap in X11
|
||||
services.xserver.layout = "us";
|
||||
# services.xserver.xkbOptions = "grp:switch";
|
||||
# services.xserver.extraLayouts = {
|
||||
# bqn = {
|
||||
# description = "BQN Symbol Modifiers";
|
||||
# languages = ["eng"];
|
||||
# symbolsFile = pkgs.fetchurl {
|
||||
# url = "https://raw.githubusercontent.com/mlochbaum/BQN/master/editors/bqn";
|
||||
# sha256 = "F2fgLlWghcOrMu0BXGiyNHa0qh9YUyQE80GK0BWU2EY=";
|
||||
# };
|
||||
# };
|
||||
# };
|
||||
# # services.xserver.xkbOptions = {
|
||||
# };
|
||||
|
||||
# Enable CUPS to print documents.
|
||||
services.printing.enable = true;
|
||||
|
||||
# Enable sound.
|
||||
#sound.enable = true;
|
||||
#hardware.pulseaudio.enable = true;
|
||||
# rtkit is optional but recommended
|
||||
security.rtkit.enable = true;
|
||||
services.pipewire = {
|
||||
enable = true;
|
||||
alsa.enable = true;
|
||||
alsa.support32Bit = true;
|
||||
pulse.enable = true;
|
||||
# If you want to use JACK applications, uncomment this
|
||||
jack.enable = true;
|
||||
};
|
||||
# services.pipewire = {
|
||||
# config.pipewire = {
|
||||
# "context.properties" = {
|
||||
# #"link.max-buffers" = 64;
|
||||
# "link.max-buffers" = 16; # version < 3 clients can't handle more than this
|
||||
# "log.level" = 2; # https://docs.pipewire.org/page_daemon.html
|
||||
# #"default.clock.rate" = 48000;
|
||||
# #"default.clock.quantum" = 1024;
|
||||
# #"default.clock.min-quantum" = 32;
|
||||
# #"default.clock.max-quantum" = 8192;
|
||||
# };
|
||||
# };
|
||||
# };
|
||||
# environment.etc = {
|
||||
# "wireplumber/bluetooth.lua.d/52-bluez-config.lua".text = ''
|
||||
# bluez_monitor.properties = {
|
||||
# ["bluez5.enable-sbc-xq"] = true,
|
||||
# ["bluez5.enable-msbc"] = true,
|
||||
# ["bluez5.enable-hw-volume"] = true,
|
||||
# ["bluez5.headset-roles"] = "[ hsp_hs hsp_ag hfp_hf hfp_ag ]"
|
||||
# '';
|
||||
# };
|
||||
|
||||
# Enable touchpad support (enabled default in most desktopManager).
|
||||
# services.xserver.libinput.enable = true;
|
||||
users.groups.net = {};
|
||||
users.users.universe = {
|
||||
isNormalUser = true;
|
||||
extraGroups = [ "wheel" "adbusers" "net" "brltty" "brlapi" "dialout" ];
|
||||
extraGroups = [ "wheel" "adbusers" "net" "brltty" "brlapi" "dialout" "input" ];
|
||||
packages = with pkgs; [
|
||||
];
|
||||
};
|
||||
@@ -170,11 +115,7 @@
|
||||
|
||||
nixpkgs.config.allowUnfree = true;
|
||||
services.xserver.videoDrivers = [ "nvidia" ];
|
||||
# Wayland support
|
||||
boot.kernelParams = ["nvidia_drm.modeset=1"];
|
||||
hardware.opengl.enable = true;
|
||||
hardware.opengl.driSupport = true;
|
||||
|
||||
|
||||
services.fwupd.enable = true;
|
||||
|
||||
programs.adb.enable = true;
|
||||
@@ -198,7 +139,7 @@
|
||||
];
|
||||
|
||||
documentation.dev.enable = true;
|
||||
documentation.man.generateCaches = true;
|
||||
documentation.man.generateCaches = false;
|
||||
|
||||
# Some programs need SUID wrappers, can be configured further or are
|
||||
# started in user sessions.
|
||||
|
||||
@@ -0,0 +1,25 @@
|
||||
diff --git a/src/wl_window.c b/src/wl_window.c
|
||||
index 5b491ff..f54b244 100644
|
||||
--- a/src/wl_window.c
|
||||
+++ b/src/wl_window.c
|
||||
@@ -2236,16 +2236,16 @@ void _glfwGetWindowPosWayland(_GLFWwindow* window, int* xpos, int* ypos)
|
||||
// A Wayland client is not aware of its position, so just warn and leave it
|
||||
// as (0, 0)
|
||||
|
||||
- _glfwInputError(GLFW_FEATURE_UNAVAILABLE,
|
||||
- "Wayland: The platform does not provide the window position");
|
||||
+ fprintf(stderr,
|
||||
+ "Wayland: The platform does not provide the window position");
|
||||
}
|
||||
|
||||
void _glfwSetWindowPosWayland(_GLFWwindow* window, int xpos, int ypos)
|
||||
{
|
||||
// A Wayland client can not set its position, so just warn
|
||||
|
||||
- _glfwInputError(GLFW_FEATURE_UNAVAILABLE,
|
||||
- "Wayland: The platform does not support setting the window position");
|
||||
+ fprintf(stderr,
|
||||
+ "Wayland: The platform does not support setting the window position");
|
||||
}
|
||||
|
||||
void _glfwGetWindowSizeWayland(_GLFWwindow* window, int* width, int* height)
|
||||
13
machines/universedesktop/desktop/audio.nix
Normal file
13
machines/universedesktop/desktop/audio.nix
Normal file
@@ -0,0 +1,13 @@
|
||||
{ config, pkgs, lib, ... }: {
|
||||
# Enable sound.
|
||||
# rtkit is optional but recommended
|
||||
security.rtkit.enable = true;
|
||||
services.pipewire = {
|
||||
enable = true;
|
||||
alsa.enable = true;
|
||||
alsa.support32Bit = true;
|
||||
pulse.enable = true;
|
||||
# If you want to use JACK applications, uncomment this
|
||||
# jack.enable = true;
|
||||
};
|
||||
}
|
||||
9
machines/universedesktop/desktop/default.nix
Normal file
9
machines/universedesktop/desktop/default.nix
Normal file
@@ -0,0 +1,9 @@
|
||||
{ config, pkgs, lib, ... }: {
|
||||
imports = [
|
||||
./audio.nix
|
||||
./graphics.nix
|
||||
# ./dwl.nix # Sadly, nVidia seems to be too broken too often on wayland
|
||||
./dwm.nix
|
||||
# ./niri.nix
|
||||
];
|
||||
}
|
||||
5
machines/universedesktop/desktop/displaymanager.nix
Normal file
5
machines/universedesktop/desktop/displaymanager.nix
Normal file
@@ -0,0 +1,5 @@
|
||||
{ ... }: {
|
||||
imports = [
|
||||
./emptty.nix
|
||||
];
|
||||
}
|
||||
116
machines/universedesktop/desktop/dwl.nix
Normal file
116
machines/universedesktop/desktop/dwl.nix
Normal file
@@ -0,0 +1,116 @@
|
||||
{ config, pkgs, lib, ... }: let
|
||||
launch_emacs = pkgs.writeScript "emacsclient-or-start" ''
|
||||
#!${pkgs.bash}/bin/bash
|
||||
emacsclient --create-frame --alternate-editor=""
|
||||
'';
|
||||
in {
|
||||
imports = [
|
||||
./wayland.nix
|
||||
];
|
||||
|
||||
services.displayManager.sessionPackages = [ pkgs.dwl ];
|
||||
#services.gnome.gnome-keyring.enable = lib.mkDefault true;
|
||||
systemd.packages = [ pkgs.dwl ];
|
||||
|
||||
nixpkgs.overlays = [
|
||||
(final: prev: {
|
||||
wlroots_0_19 = prev.wlroots_0_18.overrideAttrs (old: {
|
||||
src = final.fetchFromGitLab {
|
||||
domain = "gitlab.freedesktop.org";
|
||||
owner = "wlroots";
|
||||
repo = "wlroots";
|
||||
rev = "d305934ebe6852785a1f425ee96861f0b7280d76"; # 0.19-prev # 25-01-25
|
||||
hash = "sha256-NnPSC5p/phTFe+nWp9vl8LUbmBO/RXSSUuDZ2boucXY=";
|
||||
};
|
||||
});
|
||||
dwl = (prev.dwl.override { wlroots = final.wlroots_0_19; }).overrideAttrs (old: let
|
||||
dwl-patches = pkgs.fetchgit {
|
||||
url = "https://codeberg.org/dwl/dwl-patches.git";
|
||||
rev = "4a869141fa643d9be792a9aa44a42cf7f7f882ad";
|
||||
hash = "sha256-xlaK9xMrc+KDNecsyByRIxXmPEZ2dmP4FQ0bMojsyws=";
|
||||
};
|
||||
patches = let
|
||||
dwl-patch = p: "${dwl-patches}/patches/${p}/${p}.patch";
|
||||
in [
|
||||
(dwl-patch "ipc")
|
||||
(dwl-patch "restore-monitor")
|
||||
(dwl-patch "regexrules")
|
||||
(dwl-patch "autostart")
|
||||
];
|
||||
in {
|
||||
version = "21-09-2024";
|
||||
|
||||
src = final.fetchFromGitea {
|
||||
domain = "codeberg.org";
|
||||
owner = "dwl";
|
||||
repo = "dwl";
|
||||
rev = "d1c2f434983562bd7d2ace15ab0c05155be603bc";
|
||||
hash = "sha256-SpfjQfzvbpDiihziyKGPoBwvp3evgCQQhhjldAE/MwY=";
|
||||
};
|
||||
|
||||
patches = (old.patches or []) ++ patches;
|
||||
postPatch = (old.postPatch or "") + ''
|
||||
export termcmd=${pkgs.foot}/bin/foot
|
||||
export editcmd=${launch_emacs}
|
||||
export menucmd=${pkgs.fuzzel}/bin/fuzzel
|
||||
export barcmd=${pkgs.waybar}/bin/waybar
|
||||
export playcmd=${pkgs.writeScript "playerctl-play-pause" ''
|
||||
#!${pkgs.bash}/bin/bash
|
||||
${pkgs.playerctl}/bin/playerctl play-pause
|
||||
''}
|
||||
export scrncmd=${pkgs.writeScript "screenshot-region" ''
|
||||
#!${pkgs.bash}/bin/bash
|
||||
${pkgs.slurp}/bin/slurp | ${pkgs.grim}/bin/grim -g - - | ${pkgs.wl-clipboard}/bin/wl-copy
|
||||
''}
|
||||
substituteAll ${./dwl/config.def.h} ./config.def.h
|
||||
'';
|
||||
postInstall = ''
|
||||
chmod ugo+x $out/share/wayland-sessions/dwl.desktop
|
||||
'';
|
||||
passthru.providedSessions = ["dwl"];
|
||||
});
|
||||
})
|
||||
];
|
||||
|
||||
environment.sessionVariables = {
|
||||
# Breaks WebCord
|
||||
# NIXOS_OZONE_WL=1;
|
||||
WLR_NO_HARDWARE_CURSORS=1;
|
||||
SDL_VIDEODRIVER="wayland";
|
||||
QT_QPA_PLATFORM="wayland-egl";
|
||||
QT_WAYLAND_DISABLE_WINDOW_DECORATIONS="1";
|
||||
__JAVA_AWT_WM_NONREPARENTING=1;
|
||||
GTK_THEME="Adwaita-dark";
|
||||
};
|
||||
|
||||
xdg.portal = {
|
||||
enable = lib.mkDefault true;
|
||||
|
||||
configPackages = [ pkgs.dwl ];
|
||||
|
||||
# Recommended by upstream, required for screencast support
|
||||
# https://github.com/YaLTeR/niri/wiki/Important-Software#portals
|
||||
extraPortals = [
|
||||
pkgs.xdg-desktop-portal-gnome
|
||||
pkgs.xdg-desktop-portal-gtk
|
||||
];
|
||||
|
||||
wlr.enable = true;
|
||||
};
|
||||
|
||||
security = {
|
||||
polkit.enable = true;
|
||||
pam.services.swaylock = { };
|
||||
};
|
||||
|
||||
services.graphical-desktop.enable = true;
|
||||
|
||||
services.xserver.desktopManager.runXdgAutostartIfNone = lib.mkDefault true;
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
dwl
|
||||
waybar
|
||||
foot
|
||||
pwvucontrol
|
||||
];
|
||||
}
|
||||
182
machines/universedesktop/desktop/dwl/config.def.h
Normal file
182
machines/universedesktop/desktop/dwl/config.def.h
Normal file
@@ -0,0 +1,182 @@
|
||||
/* Taken from https://github.com/djpohly/dwl/issues/466 */
|
||||
#define COLOR(hex) { ((hex >> 24) & 0xFF) / 255.0f, \
|
||||
((hex >> 16) & 0xFF) / 255.0f, \
|
||||
((hex >> 8) & 0xFF) / 255.0f, \
|
||||
(hex & 0xFF) / 255.0f }
|
||||
/* appearance */
|
||||
static const int sloppyfocus = 1; /* focus follows mouse */
|
||||
static const int bypass_surface_visibility = 0; /* 1 means idle inhibitors will disable idle tracking even if it's surface isn't visible */
|
||||
static const unsigned int borderpx = 3; /* border pixel of windows */
|
||||
static const float rootcolor[] = COLOR(0x222222ff);
|
||||
static const float bordercolor[] = COLOR(0x233e5dff);
|
||||
static const float focuscolor[] = COLOR(0x005577ff);
|
||||
static const float urgentcolor[] = COLOR(0xff0000ff);
|
||||
/* This conforms to the xdg-protocol. Set the alpha to zero to restore the old behavior */
|
||||
static const float fullscreen_bg[] = {0.0f, 0.0f, 0.0f, 1.0f}; /* You can also use glsl colors */
|
||||
|
||||
/* tagging - TAGCOUNT must be no greater than 31 */
|
||||
#define TAGCOUNT (9)
|
||||
|
||||
/* logging */
|
||||
static int log_level = WLR_ERROR;
|
||||
/* Autostart */
|
||||
static const char *const autostart[] = {
|
||||
"@barcmd@", NULL,
|
||||
NULL /* terminate */
|
||||
};
|
||||
|
||||
static const Rule rules[] = {
|
||||
/* app_id title tags mask isfloating monitor */
|
||||
/* examples: */
|
||||
{ "Gimp_EXAMPLE", NULL, 0, 1, -1 }, /* Start on currently visible tags floating, not tiled */
|
||||
{ "firefox_EXAMPLE", NULL, 1 << 8, 0, -1 }, /* Start on ONLY tag "9" */
|
||||
};
|
||||
|
||||
/* layout(s) */
|
||||
static const Layout layouts[] = {
|
||||
/* symbol arrange function */
|
||||
{ "[]=", tile },
|
||||
{ "><>", NULL }, /* no layout function means floating behavior */
|
||||
{ "[M]", monocle },
|
||||
};
|
||||
|
||||
/* monitors */
|
||||
/* NOTE: ALWAYS add a fallback rule, even if you are completely sure it won't be used */
|
||||
static const MonitorRule monrules[] = {
|
||||
/* name mfact nmaster scale layout rotate/reflect x y */
|
||||
{ "DP-3", 0.5f, 1, 1, &layouts[0], WL_OUTPUT_TRANSFORM_NORMAL, 0, 0 },
|
||||
{ "DP-2", 0.5f, 1, 1, &layouts[0], WL_OUTPUT_TRANSFORM_NORMAL, 2560, 0 },
|
||||
{ "HDMI-A-1", 0.5f, 1, 1, &layouts[0], WL_OUTPUT_TRANSFORM_NORMAL, 2560+3440, 0 },
|
||||
/* defaults */
|
||||
{ NULL, 0.55f, 1, 1, &layouts[0], WL_OUTPUT_TRANSFORM_NORMAL, -1, -1 },
|
||||
};
|
||||
|
||||
/* keyboard */
|
||||
static const struct xkb_rule_names xkb_rules = {
|
||||
/* can specify fields: rules, model, layout, variant, options */
|
||||
/* example:
|
||||
.options = "ctrl:nocaps",
|
||||
*/
|
||||
.options = NULL,
|
||||
};
|
||||
|
||||
static const int repeat_rate = 25;
|
||||
static const int repeat_delay = 600;
|
||||
|
||||
/* Trackpad */
|
||||
static const int tap_to_click = 1;
|
||||
static const int tap_and_drag = 1;
|
||||
static const int drag_lock = 1;
|
||||
static const int natural_scrolling = 0;
|
||||
static const int disable_while_typing = 1;
|
||||
static const int left_handed = 0;
|
||||
static const int middle_button_emulation = 0;
|
||||
/* You can choose between:
|
||||
LIBINPUT_CONFIG_SCROLL_NO_SCROLL
|
||||
LIBINPUT_CONFIG_SCROLL_2FG
|
||||
LIBINPUT_CONFIG_SCROLL_EDGE
|
||||
LIBINPUT_CONFIG_SCROLL_ON_BUTTON_DOWN
|
||||
*/
|
||||
static const enum libinput_config_scroll_method scroll_method = LIBINPUT_CONFIG_SCROLL_2FG;
|
||||
|
||||
/* You can choose between:
|
||||
LIBINPUT_CONFIG_CLICK_METHOD_NONE
|
||||
LIBINPUT_CONFIG_CLICK_METHOD_BUTTON_AREAS
|
||||
LIBINPUT_CONFIG_CLICK_METHOD_CLICKFINGER
|
||||
*/
|
||||
static const enum libinput_config_click_method click_method = LIBINPUT_CONFIG_CLICK_METHOD_BUTTON_AREAS;
|
||||
|
||||
/* You can choose between:
|
||||
LIBINPUT_CONFIG_SEND_EVENTS_ENABLED
|
||||
LIBINPUT_CONFIG_SEND_EVENTS_DISABLED
|
||||
LIBINPUT_CONFIG_SEND_EVENTS_DISABLED_ON_EXTERNAL_MOUSE
|
||||
*/
|
||||
static const uint32_t send_events_mode = LIBINPUT_CONFIG_SEND_EVENTS_ENABLED;
|
||||
|
||||
/* You can choose between:
|
||||
LIBINPUT_CONFIG_ACCEL_PROFILE_FLAT
|
||||
LIBINPUT_CONFIG_ACCEL_PROFILE_ADAPTIVE
|
||||
*/
|
||||
static const enum libinput_config_accel_profile accel_profile = LIBINPUT_CONFIG_ACCEL_PROFILE_ADAPTIVE;
|
||||
static const double accel_speed = 0.0;
|
||||
|
||||
/* You can choose between:
|
||||
LIBINPUT_CONFIG_TAP_MAP_LRM -- 1/2/3 finger tap maps to left/right/middle
|
||||
LIBINPUT_CONFIG_TAP_MAP_LMR -- 1/2/3 finger tap maps to left/middle/right
|
||||
*/
|
||||
static const enum libinput_config_tap_button_map button_map = LIBINPUT_CONFIG_TAP_MAP_LRM;
|
||||
|
||||
/* If you want to use the windows key for MODKEY, use WLR_MODIFIER_LOGO */
|
||||
#define MODKEY WLR_MODIFIER_LOGO
|
||||
|
||||
#define TAGKEYS(KEY,SKEY,TAG) \
|
||||
{ MODKEY, KEY, view, {.ui = 1 << TAG} }, \
|
||||
{ MODKEY|WLR_MODIFIER_CTRL, KEY, toggleview, {.ui = 1 << TAG} }, \
|
||||
{ MODKEY|WLR_MODIFIER_SHIFT, SKEY, tag, {.ui = 1 << TAG} }, \
|
||||
{ MODKEY|WLR_MODIFIER_CTRL|WLR_MODIFIER_SHIFT,SKEY,toggletag, {.ui = 1 << TAG} }
|
||||
|
||||
/* helper for spawning shell commands in the pre dwm-5.0 fashion */
|
||||
#define SHCMD(cmd) { .v = (const char*[]){ "/bin/sh", "-c", cmd, NULL } }
|
||||
|
||||
/* commands */
|
||||
static const char *termcmd[] = { "@termcmd@", NULL };
|
||||
static const char *editcmd[] = { "@editcmd@", NULL };
|
||||
static const char *menucmd[] = { "@menucmd@", NULL };
|
||||
static const char *playcmd[] = { "@playcmd@", NULL };
|
||||
static const char *scrncmd[] = { "@scrncmd@", NULL };
|
||||
|
||||
static const Key keys[] = {
|
||||
/* Note that Shift changes certain key codes: c -> C, 2 -> at, etc. */
|
||||
/* modifier key function argument */
|
||||
{ MODKEY, XKB_KEY_r, spawn, {.v = menucmd} },
|
||||
{ MODKEY, XKB_KEY_Return, spawn, {.v = termcmd} },
|
||||
{ MODKEY|WLR_MODIFIER_SHIFT, XKB_KEY_Return, spawn, {.v = editcmd} },
|
||||
{ 0, XKB_KEY_XF86AudioPlay, spawn, {.v = playcmd} },
|
||||
{ MODKEY|WLR_MODIFIER_SHIFT, XKB_KEY_Print, spawn, {.v = scrncmd} },
|
||||
{ MODKEY, XKB_KEY_j, focusstack, {.i = +1} },
|
||||
{ MODKEY, XKB_KEY_k, focusstack, {.i = -1} },
|
||||
{ MODKEY, XKB_KEY_i, incnmaster, {.i = +1} },
|
||||
{ MODKEY, XKB_KEY_d, incnmaster, {.i = -1} },
|
||||
{ MODKEY, XKB_KEY_h, setmfact, {.f = -0.05f} },
|
||||
{ MODKEY, XKB_KEY_l, setmfact, {.f = +0.05f} },
|
||||
{ MODKEY, XKB_KEY_z, zoom, {0} },
|
||||
{ MODKEY, XKB_KEY_Tab, view, {0} },
|
||||
{ MODKEY|WLR_MODIFIER_SHIFT, XKB_KEY_C, killclient, {0} },
|
||||
{ MODKEY, XKB_KEY_t, setlayout, {.v = &layouts[0]} },
|
||||
{ MODKEY, XKB_KEY_f, setlayout, {.v = &layouts[1]} },
|
||||
{ MODKEY, XKB_KEY_m, setlayout, {.v = &layouts[2]} },
|
||||
{ MODKEY, XKB_KEY_space, setlayout, {0} },
|
||||
{ MODKEY|WLR_MODIFIER_SHIFT, XKB_KEY_space, togglefloating, {0} },
|
||||
{ MODKEY|WLR_MODIFIER_SHIFT, XKB_KEY_F, togglefullscreen, {0} },
|
||||
{ MODKEY, XKB_KEY_0, view, {.ui = ~0} },
|
||||
{ MODKEY|WLR_MODIFIER_SHIFT, XKB_KEY_parenright, tag, {.ui = ~0} },
|
||||
{ MODKEY, XKB_KEY_comma, focusmon, {.i = WLR_DIRECTION_LEFT} },
|
||||
{ MODKEY, XKB_KEY_period, focusmon, {.i = WLR_DIRECTION_RIGHT} },
|
||||
{ MODKEY|WLR_MODIFIER_SHIFT, XKB_KEY_less, tagmon, {.i = WLR_DIRECTION_LEFT} },
|
||||
{ MODKEY|WLR_MODIFIER_SHIFT, XKB_KEY_greater, tagmon, {.i = WLR_DIRECTION_RIGHT} },
|
||||
TAGKEYS( XKB_KEY_1, XKB_KEY_exclam, 0),
|
||||
TAGKEYS( XKB_KEY_2, XKB_KEY_at, 1),
|
||||
TAGKEYS( XKB_KEY_3, XKB_KEY_numbersign, 2),
|
||||
TAGKEYS( XKB_KEY_4, XKB_KEY_dollar, 3),
|
||||
TAGKEYS( XKB_KEY_5, XKB_KEY_percent, 4),
|
||||
TAGKEYS( XKB_KEY_6, XKB_KEY_asciicircum, 5),
|
||||
TAGKEYS( XKB_KEY_7, XKB_KEY_ampersand, 6),
|
||||
TAGKEYS( XKB_KEY_8, XKB_KEY_asterisk, 7),
|
||||
TAGKEYS( XKB_KEY_9, XKB_KEY_parenleft, 8),
|
||||
{ MODKEY|WLR_MODIFIER_SHIFT, XKB_KEY_Q, quit, {0} },
|
||||
|
||||
/* Ctrl-Alt-Backspace and Ctrl-Alt-Fx used to be handled by X server */
|
||||
{ WLR_MODIFIER_CTRL|WLR_MODIFIER_ALT,XKB_KEY_Terminate_Server, quit, {0} },
|
||||
/* Ctrl-Alt-Fx is used to switch to another VT, if you don't know what a VT is
|
||||
* do not remove them.
|
||||
*/
|
||||
#define CHVT(n) { WLR_MODIFIER_CTRL|WLR_MODIFIER_ALT,XKB_KEY_XF86Switch_VT_##n, chvt, {.ui = (n)} }
|
||||
CHVT(1), CHVT(2), CHVT(3), CHVT(4), CHVT(5), CHVT(6),
|
||||
CHVT(7), CHVT(8), CHVT(9), CHVT(10), CHVT(11), CHVT(12),
|
||||
};
|
||||
|
||||
static const Button buttons[] = {
|
||||
{ MODKEY, BTN_LEFT, moveresize, {.ui = CurMove} },
|
||||
{ MODKEY, BTN_MIDDLE, togglefloating, {0} },
|
||||
{ MODKEY, BTN_RIGHT, moveresize, {.ui = CurResize} },
|
||||
};
|
||||
474
machines/universedesktop/desktop/dwl/st-config.def.h
Normal file
474
machines/universedesktop/desktop/dwl/st-config.def.h
Normal file
@@ -0,0 +1,474 @@
|
||||
/* See LICENSE file for copyright and license details. */
|
||||
|
||||
/*
|
||||
* appearance
|
||||
*
|
||||
* font: see http://freedesktop.org/software/fontconfig/fontconfig-user.html
|
||||
*/
|
||||
static char *font = "Liberation Mono:pixelsize=24:antialias=true:autohint=true";
|
||||
static int borderpx = 2;
|
||||
|
||||
/*
|
||||
* What program is execed by st depends of these precedence rules:
|
||||
* 1: program passed with -e
|
||||
* 2: scroll and/or utmp
|
||||
* 3: SHELL environment variable
|
||||
* 4: value of shell in /etc/passwd
|
||||
* 5: value of shell in config.h
|
||||
*/
|
||||
static char *shell = "/bin/sh";
|
||||
char *utmp = NULL;
|
||||
/* scroll program: to enable use a string like "scroll" */
|
||||
char *scroll = NULL;
|
||||
char *stty_args = "stty raw pass8 nl -echo -iexten -cstopb 38400";
|
||||
|
||||
/* identification sequence returned in DA and DECID */
|
||||
char *vtiden = "\033[?6c";
|
||||
|
||||
/* Kerning / character bounding-box multipliers */
|
||||
static float cwscale = 1.0;
|
||||
static float chscale = 1.0;
|
||||
|
||||
/*
|
||||
* word delimiter string
|
||||
*
|
||||
* More advanced example: L" `'\"()[]{}"
|
||||
*/
|
||||
wchar_t *worddelimiters = L" ";
|
||||
|
||||
/* selection timeouts (in milliseconds) */
|
||||
static unsigned int doubleclicktimeout = 300;
|
||||
static unsigned int tripleclicktimeout = 600;
|
||||
|
||||
/* alt screens */
|
||||
int allowaltscreen = 1;
|
||||
|
||||
/* allow certain non-interactive (insecure) window operations such as:
|
||||
setting the clipboard text */
|
||||
int allowwindowops = 0;
|
||||
|
||||
/*
|
||||
* draw latency range in ms - from new content/keypress/etc until drawing.
|
||||
* within this range, st draws when content stops arriving (idle). mostly it's
|
||||
* near minlatency, but it waits longer for slow updates to avoid partial draw.
|
||||
* low minlatency will tear/flicker more, as it can "detect" idle too early.
|
||||
*/
|
||||
static double minlatency = 2;
|
||||
static double maxlatency = 33;
|
||||
|
||||
/*
|
||||
* blinking timeout (set to 0 to disable blinking) for the terminal blinking
|
||||
* attribute.
|
||||
*/
|
||||
static unsigned int blinktimeout = 800;
|
||||
|
||||
/*
|
||||
* thickness of underline and bar cursors
|
||||
*/
|
||||
static unsigned int cursorthickness = 2;
|
||||
|
||||
/*
|
||||
* bell volume. It must be a value between -100 and 100. Use 0 for disabling
|
||||
* it
|
||||
*/
|
||||
static int bellvolume = 0;
|
||||
|
||||
/* default TERM value */
|
||||
char *termname = "st-256color";
|
||||
|
||||
/*
|
||||
* spaces per tab
|
||||
*
|
||||
* When you are changing this value, don't forget to adapt the »it« value in
|
||||
* the st.info and appropriately install the st.info in the environment where
|
||||
* you use this st version.
|
||||
*
|
||||
* it#$tabspaces,
|
||||
*
|
||||
* Secondly make sure your kernel is not expanding tabs. When running `stty
|
||||
* -a` »tab0« should appear. You can tell the terminal to not expand tabs by
|
||||
* running following command:
|
||||
*
|
||||
* stty tabs
|
||||
*/
|
||||
unsigned int tabspaces = 8;
|
||||
|
||||
/* Terminal colors (16 first used in escape sequence) */
|
||||
static const char *colorname[] = {
|
||||
/* 8 normal colors */
|
||||
"black",
|
||||
"red3",
|
||||
"green3",
|
||||
"yellow3",
|
||||
"blue2",
|
||||
"magenta3",
|
||||
"cyan3",
|
||||
"gray90",
|
||||
|
||||
/* 8 bright colors */
|
||||
"gray50",
|
||||
"red",
|
||||
"green",
|
||||
"yellow",
|
||||
"#5c5cff",
|
||||
"magenta",
|
||||
"cyan",
|
||||
"white",
|
||||
|
||||
[255] = 0,
|
||||
|
||||
/* more colors can be added after 255 to use with DefaultXX */
|
||||
"#cccccc",
|
||||
"#555555",
|
||||
"gray90", /* default foreground colour */
|
||||
"black", /* default background colour */
|
||||
};
|
||||
|
||||
|
||||
/*
|
||||
* Default colors (colorname index)
|
||||
* foreground, background, cursor, reverse cursor
|
||||
*/
|
||||
unsigned int defaultfg = 258;
|
||||
unsigned int defaultbg = 259;
|
||||
unsigned int defaultcs = 256;
|
||||
static unsigned int defaultrcs = 257;
|
||||
|
||||
/*
|
||||
* Default shape of cursor
|
||||
* 2: Block ("█")
|
||||
* 4: Underline ("_")
|
||||
* 6: Bar ("|")
|
||||
* 7: Snowman ("☃")
|
||||
*/
|
||||
static unsigned int cursorshape = 2;
|
||||
|
||||
/*
|
||||
* Default columns and rows numbers
|
||||
*/
|
||||
|
||||
static unsigned int cols = 80;
|
||||
static unsigned int rows = 24;
|
||||
|
||||
/*
|
||||
* Default colour and shape of the mouse cursor
|
||||
*/
|
||||
static unsigned int mouseshape = XC_xterm;
|
||||
static unsigned int mousefg = 7;
|
||||
static unsigned int mousebg = 0;
|
||||
|
||||
/*
|
||||
* Color used to display font attributes when fontconfig selected a font which
|
||||
* doesn't match the ones requested.
|
||||
*/
|
||||
static unsigned int defaultattr = 11;
|
||||
|
||||
/*
|
||||
* Force mouse select/shortcuts while mask is active (when MODE_MOUSE is set).
|
||||
* Note that if you want to use ShiftMask with selmasks, set this to an other
|
||||
* modifier, set to 0 to not use it.
|
||||
*/
|
||||
static uint forcemousemod = ShiftMask;
|
||||
|
||||
/*
|
||||
* Internal mouse shortcuts.
|
||||
* Beware that overloading Button1 will disable the selection.
|
||||
*/
|
||||
static MouseShortcut mshortcuts[] = {
|
||||
/* mask button function argument release */
|
||||
{ XK_ANY_MOD, Button2, selpaste, {.i = 0}, 1 },
|
||||
{ ShiftMask, Button4, ttysend, {.s = "\033[5;2~"} },
|
||||
{ XK_ANY_MOD, Button4, ttysend, {.s = "\031"} },
|
||||
{ ShiftMask, Button5, ttysend, {.s = "\033[6;2~"} },
|
||||
{ XK_ANY_MOD, Button5, ttysend, {.s = "\005"} },
|
||||
};
|
||||
|
||||
/* Internal keyboard shortcuts. */
|
||||
#define MODKEY Mod1Mask
|
||||
#define TERMMOD (ControlMask|ShiftMask)
|
||||
|
||||
static Shortcut shortcuts[] = {
|
||||
/* mask keysym function argument */
|
||||
{ XK_ANY_MOD, XK_Break, sendbreak, {.i = 0} },
|
||||
{ ControlMask, XK_Print, toggleprinter, {.i = 0} },
|
||||
{ ShiftMask, XK_Print, printscreen, {.i = 0} },
|
||||
{ XK_ANY_MOD, XK_Print, printsel, {.i = 0} },
|
||||
{ TERMMOD|ShiftMask, XK_KP_Subtract, zoom, {.f = -1} },
|
||||
{ TERMMOD|ShiftMask, XK_KP_Equal, zoom, {.f = +1} },
|
||||
{ TERMMOD, XK_Home, zoomreset, {.f = 0} },
|
||||
{ TERMMOD, XK_C, clipcopy, {.i = 0} },
|
||||
{ TERMMOD, XK_V, clippaste, {.i = 0} },
|
||||
{ TERMMOD, XK_Y, selpaste, {.i = 0} },
|
||||
{ ShiftMask, XK_Insert, selpaste, {.i = 0} },
|
||||
{ TERMMOD, XK_Num_Lock, numlock, {.i = 0} },
|
||||
};
|
||||
|
||||
/*
|
||||
* Special keys (change & recompile st.info accordingly)
|
||||
*
|
||||
* Mask value:
|
||||
* * Use XK_ANY_MOD to match the key no matter modifiers state
|
||||
* * Use XK_NO_MOD to match the key alone (no modifiers)
|
||||
* appkey value:
|
||||
* * 0: no value
|
||||
* * > 0: keypad application mode enabled
|
||||
* * = 2: term.numlock = 1
|
||||
* * < 0: keypad application mode disabled
|
||||
* appcursor value:
|
||||
* * 0: no value
|
||||
* * > 0: cursor application mode enabled
|
||||
* * < 0: cursor application mode disabled
|
||||
*
|
||||
* Be careful with the order of the definitions because st searches in
|
||||
* this table sequentially, so any XK_ANY_MOD must be in the last
|
||||
* position for a key.
|
||||
*/
|
||||
|
||||
/*
|
||||
* If you want keys other than the X11 function keys (0xFD00 - 0xFFFF)
|
||||
* to be mapped below, add them to this array.
|
||||
*/
|
||||
static KeySym mappedkeys[] = { -1 };
|
||||
|
||||
/*
|
||||
* State bits to ignore when matching key or button events. By default,
|
||||
* numlock (Mod2Mask) and keyboard layout (XK_SWITCH_MOD) are ignored.
|
||||
*/
|
||||
static uint ignoremod = Mod2Mask|XK_SWITCH_MOD;
|
||||
|
||||
/*
|
||||
* This is the huge key array which defines all compatibility to the Linux
|
||||
* world. Please decide about changes wisely.
|
||||
*/
|
||||
static Key key[] = {
|
||||
/* keysym mask string appkey appcursor */
|
||||
{ XK_KP_Home, ShiftMask, "\033[2J", 0, -1},
|
||||
{ XK_KP_Home, ShiftMask, "\033[1;2H", 0, +1},
|
||||
{ XK_KP_Home, XK_ANY_MOD, "\033[H", 0, -1},
|
||||
{ XK_KP_Home, XK_ANY_MOD, "\033[1~", 0, +1},
|
||||
{ XK_KP_Up, XK_ANY_MOD, "\033Ox", +1, 0},
|
||||
{ XK_KP_Up, XK_ANY_MOD, "\033[A", 0, -1},
|
||||
{ XK_KP_Up, XK_ANY_MOD, "\033OA", 0, +1},
|
||||
{ XK_KP_Down, XK_ANY_MOD, "\033Or", +1, 0},
|
||||
{ XK_KP_Down, XK_ANY_MOD, "\033[B", 0, -1},
|
||||
{ XK_KP_Down, XK_ANY_MOD, "\033OB", 0, +1},
|
||||
{ XK_KP_Left, XK_ANY_MOD, "\033Ot", +1, 0},
|
||||
{ XK_KP_Left, XK_ANY_MOD, "\033[D", 0, -1},
|
||||
{ XK_KP_Left, XK_ANY_MOD, "\033OD", 0, +1},
|
||||
{ XK_KP_Right, XK_ANY_MOD, "\033Ov", +1, 0},
|
||||
{ XK_KP_Right, XK_ANY_MOD, "\033[C", 0, -1},
|
||||
{ XK_KP_Right, XK_ANY_MOD, "\033OC", 0, +1},
|
||||
{ XK_KP_Prior, ShiftMask, "\033[5;2~", 0, 0},
|
||||
{ XK_KP_Prior, XK_ANY_MOD, "\033[5~", 0, 0},
|
||||
{ XK_KP_Begin, XK_ANY_MOD, "\033[E", 0, 0},
|
||||
{ XK_KP_End, ControlMask, "\033[J", -1, 0},
|
||||
{ XK_KP_End, ControlMask, "\033[1;5F", +1, 0},
|
||||
{ XK_KP_End, ShiftMask, "\033[K", -1, 0},
|
||||
{ XK_KP_End, ShiftMask, "\033[1;2F", +1, 0},
|
||||
{ XK_KP_End, XK_ANY_MOD, "\033[4~", 0, 0},
|
||||
{ XK_KP_Next, ShiftMask, "\033[6;2~", 0, 0},
|
||||
{ XK_KP_Next, XK_ANY_MOD, "\033[6~", 0, 0},
|
||||
{ XK_KP_Insert, ShiftMask, "\033[2;2~", +1, 0},
|
||||
{ XK_KP_Insert, ShiftMask, "\033[4l", -1, 0},
|
||||
{ XK_KP_Insert, ControlMask, "\033[L", -1, 0},
|
||||
{ XK_KP_Insert, ControlMask, "\033[2;5~", +1, 0},
|
||||
{ XK_KP_Insert, XK_ANY_MOD, "\033[4h", -1, 0},
|
||||
{ XK_KP_Insert, XK_ANY_MOD, "\033[2~", +1, 0},
|
||||
{ XK_KP_Delete, ControlMask, "\033[M", -1, 0},
|
||||
{ XK_KP_Delete, ControlMask, "\033[3;5~", +1, 0},
|
||||
{ XK_KP_Delete, ShiftMask, "\033[2K", -1, 0},
|
||||
{ XK_KP_Delete, ShiftMask, "\033[3;2~", +1, 0},
|
||||
{ XK_KP_Delete, XK_ANY_MOD, "\033[P", -1, 0},
|
||||
{ XK_KP_Delete, XK_ANY_MOD, "\033[3~", +1, 0},
|
||||
{ XK_KP_Multiply, XK_ANY_MOD, "\033Oj", +2, 0},
|
||||
{ XK_KP_Add, XK_ANY_MOD, "\033Ok", +2, 0},
|
||||
{ XK_KP_Enter, XK_ANY_MOD, "\033OM", +2, 0},
|
||||
{ XK_KP_Enter, XK_ANY_MOD, "\r", -1, 0},
|
||||
{ XK_KP_Subtract, XK_ANY_MOD, "\033Om", +2, 0},
|
||||
{ XK_KP_Decimal, XK_ANY_MOD, "\033On", +2, 0},
|
||||
{ XK_KP_Divide, XK_ANY_MOD, "\033Oo", +2, 0},
|
||||
{ XK_KP_0, XK_ANY_MOD, "\033Op", +2, 0},
|
||||
{ XK_KP_1, XK_ANY_MOD, "\033Oq", +2, 0},
|
||||
{ XK_KP_2, XK_ANY_MOD, "\033Or", +2, 0},
|
||||
{ XK_KP_3, XK_ANY_MOD, "\033Os", +2, 0},
|
||||
{ XK_KP_4, XK_ANY_MOD, "\033Ot", +2, 0},
|
||||
{ XK_KP_5, XK_ANY_MOD, "\033Ou", +2, 0},
|
||||
{ XK_KP_6, XK_ANY_MOD, "\033Ov", +2, 0},
|
||||
{ XK_KP_7, XK_ANY_MOD, "\033Ow", +2, 0},
|
||||
{ XK_KP_8, XK_ANY_MOD, "\033Ox", +2, 0},
|
||||
{ XK_KP_9, XK_ANY_MOD, "\033Oy", +2, 0},
|
||||
{ XK_Up, ShiftMask, "\033[1;2A", 0, 0},
|
||||
{ XK_Up, Mod1Mask, "\033[1;3A", 0, 0},
|
||||
{ XK_Up, ShiftMask|Mod1Mask,"\033[1;4A", 0, 0},
|
||||
{ XK_Up, ControlMask, "\033[1;5A", 0, 0},
|
||||
{ XK_Up, ShiftMask|ControlMask,"\033[1;6A", 0, 0},
|
||||
{ XK_Up, ControlMask|Mod1Mask,"\033[1;7A", 0, 0},
|
||||
{ XK_Up,ShiftMask|ControlMask|Mod1Mask,"\033[1;8A", 0, 0},
|
||||
{ XK_Up, XK_ANY_MOD, "\033[A", 0, -1},
|
||||
{ XK_Up, XK_ANY_MOD, "\033OA", 0, +1},
|
||||
{ XK_Down, ShiftMask, "\033[1;2B", 0, 0},
|
||||
{ XK_Down, Mod1Mask, "\033[1;3B", 0, 0},
|
||||
{ XK_Down, ShiftMask|Mod1Mask,"\033[1;4B", 0, 0},
|
||||
{ XK_Down, ControlMask, "\033[1;5B", 0, 0},
|
||||
{ XK_Down, ShiftMask|ControlMask,"\033[1;6B", 0, 0},
|
||||
{ XK_Down, ControlMask|Mod1Mask,"\033[1;7B", 0, 0},
|
||||
{ XK_Down,ShiftMask|ControlMask|Mod1Mask,"\033[1;8B",0, 0},
|
||||
{ XK_Down, XK_ANY_MOD, "\033[B", 0, -1},
|
||||
{ XK_Down, XK_ANY_MOD, "\033OB", 0, +1},
|
||||
{ XK_Left, ShiftMask, "\033[1;2D", 0, 0},
|
||||
{ XK_Left, Mod1Mask, "\033[1;3D", 0, 0},
|
||||
{ XK_Left, ShiftMask|Mod1Mask,"\033[1;4D", 0, 0},
|
||||
{ XK_Left, ControlMask, "\033[1;5D", 0, 0},
|
||||
{ XK_Left, ShiftMask|ControlMask,"\033[1;6D", 0, 0},
|
||||
{ XK_Left, ControlMask|Mod1Mask,"\033[1;7D", 0, 0},
|
||||
{ XK_Left,ShiftMask|ControlMask|Mod1Mask,"\033[1;8D",0, 0},
|
||||
{ XK_Left, XK_ANY_MOD, "\033[D", 0, -1},
|
||||
{ XK_Left, XK_ANY_MOD, "\033OD", 0, +1},
|
||||
{ XK_Right, ShiftMask, "\033[1;2C", 0, 0},
|
||||
{ XK_Right, Mod1Mask, "\033[1;3C", 0, 0},
|
||||
{ XK_Right, ShiftMask|Mod1Mask,"\033[1;4C", 0, 0},
|
||||
{ XK_Right, ControlMask, "\033[1;5C", 0, 0},
|
||||
{ XK_Right, ShiftMask|ControlMask,"\033[1;6C", 0, 0},
|
||||
{ XK_Right, ControlMask|Mod1Mask,"\033[1;7C", 0, 0},
|
||||
{ XK_Right,ShiftMask|ControlMask|Mod1Mask,"\033[1;8C",0, 0},
|
||||
{ XK_Right, XK_ANY_MOD, "\033[C", 0, -1},
|
||||
{ XK_Right, XK_ANY_MOD, "\033OC", 0, +1},
|
||||
{ XK_ISO_Left_Tab, ShiftMask, "\033[Z", 0, 0},
|
||||
{ XK_Return, Mod1Mask, "\033\r", 0, 0},
|
||||
{ XK_Return, XK_ANY_MOD, "\r", 0, 0},
|
||||
{ XK_Insert, ShiftMask, "\033[4l", -1, 0},
|
||||
{ XK_Insert, ShiftMask, "\033[2;2~", +1, 0},
|
||||
{ XK_Insert, ControlMask, "\033[L", -1, 0},
|
||||
{ XK_Insert, ControlMask, "\033[2;5~", +1, 0},
|
||||
{ XK_Insert, XK_ANY_MOD, "\033[4h", -1, 0},
|
||||
{ XK_Insert, XK_ANY_MOD, "\033[2~", +1, 0},
|
||||
{ XK_Delete, ControlMask, "\033[M", -1, 0},
|
||||
{ XK_Delete, ControlMask, "\033[3;5~", +1, 0},
|
||||
{ XK_Delete, ShiftMask, "\033[2K", -1, 0},
|
||||
{ XK_Delete, ShiftMask, "\033[3;2~", +1, 0},
|
||||
{ XK_Delete, XK_ANY_MOD, "\033[P", -1, 0},
|
||||
{ XK_Delete, XK_ANY_MOD, "\033[3~", +1, 0},
|
||||
{ XK_BackSpace, XK_NO_MOD, "\177", 0, 0},
|
||||
{ XK_BackSpace, Mod1Mask, "\033\177", 0, 0},
|
||||
{ XK_Home, ShiftMask, "\033[2J", 0, -1},
|
||||
{ XK_Home, ShiftMask, "\033[1;2H", 0, +1},
|
||||
{ XK_Home, XK_ANY_MOD, "\033[H", 0, -1},
|
||||
{ XK_Home, XK_ANY_MOD, "\033[1~", 0, +1},
|
||||
{ XK_End, ControlMask, "\033[J", -1, 0},
|
||||
{ XK_End, ControlMask, "\033[1;5F", +1, 0},
|
||||
{ XK_End, ShiftMask, "\033[K", -1, 0},
|
||||
{ XK_End, ShiftMask, "\033[1;2F", +1, 0},
|
||||
{ XK_End, XK_ANY_MOD, "\033[4~", 0, 0},
|
||||
{ XK_Prior, ControlMask, "\033[5;5~", 0, 0},
|
||||
{ XK_Prior, ShiftMask, "\033[5;2~", 0, 0},
|
||||
{ XK_Prior, XK_ANY_MOD, "\033[5~", 0, 0},
|
||||
{ XK_Next, ControlMask, "\033[6;5~", 0, 0},
|
||||
{ XK_Next, ShiftMask, "\033[6;2~", 0, 0},
|
||||
{ XK_Next, XK_ANY_MOD, "\033[6~", 0, 0},
|
||||
{ XK_F1, XK_NO_MOD, "\033OP" , 0, 0},
|
||||
{ XK_F1, /* F13 */ ShiftMask, "\033[1;2P", 0, 0},
|
||||
{ XK_F1, /* F25 */ ControlMask, "\033[1;5P", 0, 0},
|
||||
{ XK_F1, /* F37 */ Mod4Mask, "\033[1;6P", 0, 0},
|
||||
{ XK_F1, /* F49 */ Mod1Mask, "\033[1;3P", 0, 0},
|
||||
{ XK_F1, /* F61 */ Mod3Mask, "\033[1;4P", 0, 0},
|
||||
{ XK_F2, XK_NO_MOD, "\033OQ" , 0, 0},
|
||||
{ XK_F2, /* F14 */ ShiftMask, "\033[1;2Q", 0, 0},
|
||||
{ XK_F2, /* F26 */ ControlMask, "\033[1;5Q", 0, 0},
|
||||
{ XK_F2, /* F38 */ Mod4Mask, "\033[1;6Q", 0, 0},
|
||||
{ XK_F2, /* F50 */ Mod1Mask, "\033[1;3Q", 0, 0},
|
||||
{ XK_F2, /* F62 */ Mod3Mask, "\033[1;4Q", 0, 0},
|
||||
{ XK_F3, XK_NO_MOD, "\033OR" , 0, 0},
|
||||
{ XK_F3, /* F15 */ ShiftMask, "\033[1;2R", 0, 0},
|
||||
{ XK_F3, /* F27 */ ControlMask, "\033[1;5R", 0, 0},
|
||||
{ XK_F3, /* F39 */ Mod4Mask, "\033[1;6R", 0, 0},
|
||||
{ XK_F3, /* F51 */ Mod1Mask, "\033[1;3R", 0, 0},
|
||||
{ XK_F3, /* F63 */ Mod3Mask, "\033[1;4R", 0, 0},
|
||||
{ XK_F4, XK_NO_MOD, "\033OS" , 0, 0},
|
||||
{ XK_F4, /* F16 */ ShiftMask, "\033[1;2S", 0, 0},
|
||||
{ XK_F4, /* F28 */ ControlMask, "\033[1;5S", 0, 0},
|
||||
{ XK_F4, /* F40 */ Mod4Mask, "\033[1;6S", 0, 0},
|
||||
{ XK_F4, /* F52 */ Mod1Mask, "\033[1;3S", 0, 0},
|
||||
{ XK_F5, XK_NO_MOD, "\033[15~", 0, 0},
|
||||
{ XK_F5, /* F17 */ ShiftMask, "\033[15;2~", 0, 0},
|
||||
{ XK_F5, /* F29 */ ControlMask, "\033[15;5~", 0, 0},
|
||||
{ XK_F5, /* F41 */ Mod4Mask, "\033[15;6~", 0, 0},
|
||||
{ XK_F5, /* F53 */ Mod1Mask, "\033[15;3~", 0, 0},
|
||||
{ XK_F6, XK_NO_MOD, "\033[17~", 0, 0},
|
||||
{ XK_F6, /* F18 */ ShiftMask, "\033[17;2~", 0, 0},
|
||||
{ XK_F6, /* F30 */ ControlMask, "\033[17;5~", 0, 0},
|
||||
{ XK_F6, /* F42 */ Mod4Mask, "\033[17;6~", 0, 0},
|
||||
{ XK_F6, /* F54 */ Mod1Mask, "\033[17;3~", 0, 0},
|
||||
{ XK_F7, XK_NO_MOD, "\033[18~", 0, 0},
|
||||
{ XK_F7, /* F19 */ ShiftMask, "\033[18;2~", 0, 0},
|
||||
{ XK_F7, /* F31 */ ControlMask, "\033[18;5~", 0, 0},
|
||||
{ XK_F7, /* F43 */ Mod4Mask, "\033[18;6~", 0, 0},
|
||||
{ XK_F7, /* F55 */ Mod1Mask, "\033[18;3~", 0, 0},
|
||||
{ XK_F8, XK_NO_MOD, "\033[19~", 0, 0},
|
||||
{ XK_F8, /* F20 */ ShiftMask, "\033[19;2~", 0, 0},
|
||||
{ XK_F8, /* F32 */ ControlMask, "\033[19;5~", 0, 0},
|
||||
{ XK_F8, /* F44 */ Mod4Mask, "\033[19;6~", 0, 0},
|
||||
{ XK_F8, /* F56 */ Mod1Mask, "\033[19;3~", 0, 0},
|
||||
{ XK_F9, XK_NO_MOD, "\033[20~", 0, 0},
|
||||
{ XK_F9, /* F21 */ ShiftMask, "\033[20;2~", 0, 0},
|
||||
{ XK_F9, /* F33 */ ControlMask, "\033[20;5~", 0, 0},
|
||||
{ XK_F9, /* F45 */ Mod4Mask, "\033[20;6~", 0, 0},
|
||||
{ XK_F9, /* F57 */ Mod1Mask, "\033[20;3~", 0, 0},
|
||||
{ XK_F10, XK_NO_MOD, "\033[21~", 0, 0},
|
||||
{ XK_F10, /* F22 */ ShiftMask, "\033[21;2~", 0, 0},
|
||||
{ XK_F10, /* F34 */ ControlMask, "\033[21;5~", 0, 0},
|
||||
{ XK_F10, /* F46 */ Mod4Mask, "\033[21;6~", 0, 0},
|
||||
{ XK_F10, /* F58 */ Mod1Mask, "\033[21;3~", 0, 0},
|
||||
{ XK_F11, XK_NO_MOD, "\033[23~", 0, 0},
|
||||
{ XK_F11, /* F23 */ ShiftMask, "\033[23;2~", 0, 0},
|
||||
{ XK_F11, /* F35 */ ControlMask, "\033[23;5~", 0, 0},
|
||||
{ XK_F11, /* F47 */ Mod4Mask, "\033[23;6~", 0, 0},
|
||||
{ XK_F11, /* F59 */ Mod1Mask, "\033[23;3~", 0, 0},
|
||||
{ XK_F12, XK_NO_MOD, "\033[24~", 0, 0},
|
||||
{ XK_F12, /* F24 */ ShiftMask, "\033[24;2~", 0, 0},
|
||||
{ XK_F12, /* F36 */ ControlMask, "\033[24;5~", 0, 0},
|
||||
{ XK_F12, /* F48 */ Mod4Mask, "\033[24;6~", 0, 0},
|
||||
{ XK_F12, /* F60 */ Mod1Mask, "\033[24;3~", 0, 0},
|
||||
{ XK_F13, XK_NO_MOD, "\033[1;2P", 0, 0},
|
||||
{ XK_F14, XK_NO_MOD, "\033[1;2Q", 0, 0},
|
||||
{ XK_F15, XK_NO_MOD, "\033[1;2R", 0, 0},
|
||||
{ XK_F16, XK_NO_MOD, "\033[1;2S", 0, 0},
|
||||
{ XK_F17, XK_NO_MOD, "\033[15;2~", 0, 0},
|
||||
{ XK_F18, XK_NO_MOD, "\033[17;2~", 0, 0},
|
||||
{ XK_F19, XK_NO_MOD, "\033[18;2~", 0, 0},
|
||||
{ XK_F20, XK_NO_MOD, "\033[19;2~", 0, 0},
|
||||
{ XK_F21, XK_NO_MOD, "\033[20;2~", 0, 0},
|
||||
{ XK_F22, XK_NO_MOD, "\033[21;2~", 0, 0},
|
||||
{ XK_F23, XK_NO_MOD, "\033[23;2~", 0, 0},
|
||||
{ XK_F24, XK_NO_MOD, "\033[24;2~", 0, 0},
|
||||
{ XK_F25, XK_NO_MOD, "\033[1;5P", 0, 0},
|
||||
{ XK_F26, XK_NO_MOD, "\033[1;5Q", 0, 0},
|
||||
{ XK_F27, XK_NO_MOD, "\033[1;5R", 0, 0},
|
||||
{ XK_F28, XK_NO_MOD, "\033[1;5S", 0, 0},
|
||||
{ XK_F29, XK_NO_MOD, "\033[15;5~", 0, 0},
|
||||
{ XK_F30, XK_NO_MOD, "\033[17;5~", 0, 0},
|
||||
{ XK_F31, XK_NO_MOD, "\033[18;5~", 0, 0},
|
||||
{ XK_F32, XK_NO_MOD, "\033[19;5~", 0, 0},
|
||||
{ XK_F33, XK_NO_MOD, "\033[20;5~", 0, 0},
|
||||
{ XK_F34, XK_NO_MOD, "\033[21;5~", 0, 0},
|
||||
{ XK_F35, XK_NO_MOD, "\033[23;5~", 0, 0},
|
||||
};
|
||||
|
||||
/*
|
||||
* Selection types' masks.
|
||||
* Use the same masks as usual.
|
||||
* Button1Mask is always unset, to make masks match between ButtonPress.
|
||||
* ButtonRelease and MotionNotify.
|
||||
* If no match is found, regular selection is used.
|
||||
*/
|
||||
static uint selmasks[] = {
|
||||
[SEL_RECTANGULAR] = Mod1Mask,
|
||||
};
|
||||
|
||||
/*
|
||||
* Printable characters in ASCII, used to estimate the advance width
|
||||
* of single wide characters.
|
||||
*/
|
||||
static char ascii_printable[] =
|
||||
" !\"#$%&'()*+,-./0123456789:;<=>?"
|
||||
"@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_"
|
||||
"`abcdefghijklmnopqrstuvwxyz{|}~";
|
||||
64
machines/universedesktop/desktop/dwm.nix
Normal file
64
machines/universedesktop/desktop/dwm.nix
Normal file
@@ -0,0 +1,64 @@
|
||||
{ config, pkgs, lib, ... }: {
|
||||
nixpkgs.overlays = [
|
||||
(final: prev: {
|
||||
st = prev.st.override {
|
||||
conf = builtins.readFile (pkgs.replaceVars ./dwm/st-config.def.h {});
|
||||
};
|
||||
})
|
||||
];
|
||||
services.xserver.windowManager.dwm = {
|
||||
enable = true;
|
||||
package = let
|
||||
launch_emacs = pkgs.writeScript "emacsclient-or-start" ''
|
||||
#!${pkgs.bash}/bin/bash
|
||||
emacsclient --create-frame --alternate-editor=""
|
||||
'';
|
||||
in pkgs.dwm.override {
|
||||
conf = pkgs.replaceVars ./dwm/config.h {
|
||||
dmenucmd="${pkgs.dmenu}/bin/dmenu_run";
|
||||
termcmd="${pkgs.st}/bin/st";
|
||||
editcmd="${launch_emacs}";
|
||||
playcmd=pkgs.writeScript "playerctl-play-pause" ''
|
||||
#!${pkgs.bash}/bin/bash
|
||||
${pkgs.playerctl}/bin/playerctl play-pause
|
||||
'';
|
||||
scrncmd=pkgs.writeScript "screenshot-region" ''
|
||||
#!${pkgs.bash}/bin/bash
|
||||
${pkgs.maim}/bin/maim -o -s | ${pkgs.xclip}/bin/xclip -sel clip -t image/png
|
||||
'';
|
||||
};
|
||||
patches = [
|
||||
./dwm/fullscreen.patch
|
||||
];
|
||||
};
|
||||
};
|
||||
services.xserver.enable = true;
|
||||
# services.xserver.xrandrHeads should work, but alas
|
||||
services.xserver.displayManager.setupCommands = ''
|
||||
${pkgs.xorg.xrandr}/bin/xrandr --output DP-4 --auto --output DP-2 --auto --right-of DP-4 --primary --output HDMI-0 --auto --right-of DP-2;
|
||||
'';
|
||||
services.xserver.displayManager.lightdm = {
|
||||
enable = true;
|
||||
background = "#000000";
|
||||
};
|
||||
services.xserver.config = lib.mkAfter ''
|
||||
Section "InputClass"
|
||||
Identifier "joystick catchall"
|
||||
MatchIsJoystick "on"
|
||||
MatchDevicePath "/dev/input/event*"
|
||||
Driver "joystick"
|
||||
Option "StartKeysEnabled" "False"
|
||||
Option "StartMouseEnabled" "False"
|
||||
EndSection
|
||||
'';
|
||||
environment.sessionVariables = {
|
||||
GTK_THEME="Adwaita-dark";
|
||||
};
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
dmenu
|
||||
xclip
|
||||
pwvucontrol
|
||||
st
|
||||
];
|
||||
}
|
||||
124
machines/universedesktop/desktop/dwm/config.h
Normal file
124
machines/universedesktop/desktop/dwm/config.h
Normal file
@@ -0,0 +1,124 @@
|
||||
#include <X11/XF86keysym.h>
|
||||
/* See LICENSE file for copyright and license details. */
|
||||
|
||||
/* appearance */
|
||||
static const unsigned int borderpx = 1; /* border pixel of windows */
|
||||
static const unsigned int snap = 32; /* snap pixel */
|
||||
static const int showbar = 1; /* 0 means no bar */
|
||||
static const int topbar = 1; /* 0 means bottom bar */
|
||||
static const char *fonts[] = { "monospace:size=10" };
|
||||
static const char dmenufont[] = "monospace:size=10";
|
||||
static const char col_gray1[] = "#222222";
|
||||
static const char col_gray2[] = "#444444";
|
||||
static const char col_gray3[] = "#bbbbbb";
|
||||
static const char col_gray4[] = "#eeeeee";
|
||||
static const char col_cyan[] = "#005577";
|
||||
static const char *colors[][3] = {
|
||||
/* fg bg border */
|
||||
[SchemeNorm] = { col_gray3, col_gray1, col_gray2 },
|
||||
[SchemeSel] = { col_gray4, col_cyan, col_cyan },
|
||||
};
|
||||
|
||||
/* tagging */
|
||||
static const char *tags[] = { "1", "2", "3", "4", "5", "6", "7", "8", "9" };
|
||||
|
||||
static const Rule rules[] = {
|
||||
/* xprop(1):
|
||||
* WM_CLASS(STRING) = instance, class
|
||||
* WM_NAME(STRING) = title
|
||||
*/
|
||||
/* class instance title tags mask isfloating monitor */
|
||||
/* { "Gimp", NULL, NULL, 0, 1, -1 }, */
|
||||
{ "Firefox", NULL, NULL, 1 << 2, 0, -1 },
|
||||
};
|
||||
|
||||
/* layout(s) */
|
||||
static const float mfact = 0.5; /* factor of master area size [0.05..0.95] */
|
||||
static const int nmaster = 1; /* number of clients in master area */
|
||||
static const int resizehints = 0; /* 1 means respect size hints in tiled resizals */
|
||||
static const int lockfullscreen = 1; /* 1 will force focus on the fullscreen window */
|
||||
|
||||
static const Layout layouts[] = {
|
||||
/* symbol arrange function */
|
||||
{ "[]=", tile }, /* first entry is default */
|
||||
{ "><>", NULL }, /* no layout function means floating behavior */
|
||||
{ "[M]", monocle },
|
||||
};
|
||||
|
||||
/* key definitions */
|
||||
#define MODKEY Mod4Mask
|
||||
#define TAGKEYS(KEY,TAG) \
|
||||
{ MODKEY, KEY, view, {.ui = 1 << TAG} }, \
|
||||
{ MODKEY|ControlMask, KEY, toggleview, {.ui = 1 << TAG} }, \
|
||||
{ MODKEY|ShiftMask, KEY, tag, {.ui = 1 << TAG} }, \
|
||||
{ MODKEY|ControlMask|ShiftMask, KEY, toggletag, {.ui = 1 << TAG} },
|
||||
|
||||
/* helper for spawning shell commands in the pre dwm-5.0 fashion */
|
||||
#define SHCMD(cmd) { .v = (const char*[]){ "/bin/sh", "-c", cmd, NULL } }
|
||||
|
||||
/* commands */
|
||||
static char dmenumon[2] = "0"; /* component of dmenucmd, manipulated in spawn() */
|
||||
static const char *dmenucmd[] = { "@dmenucmd@", "-m", dmenumon, "-fn", dmenufont, "-nb", col_gray1, "-nf", col_gray3, "-sb", col_cyan, "-sf", col_gray4, NULL };
|
||||
static const char *termcmd[] = { "@termcmd@", NULL };
|
||||
static const char *editcmd[] = { "@editcmd@", NULL };
|
||||
static const char *playcmd[] = { "@playcmd@", NULL };
|
||||
static const char *scrncmd[] = { "@scrncmd@", NULL };
|
||||
|
||||
static const Key keys[] = {
|
||||
/* modifier key function argument */
|
||||
{ MODKEY, XK_r, spawn, {.v = dmenucmd } },
|
||||
{ MODKEY, XK_Return, spawn, {.v = termcmd } },
|
||||
{ MODKEY|ShiftMask, XK_Return, spawn, {.v = editcmd } },
|
||||
{ MODKEY, XK_b, togglebar, {0} },
|
||||
{ MODKEY, XK_j, focusstack, {.i = +1 } },
|
||||
{ MODKEY, XK_k, focusstack, {.i = -1 } },
|
||||
{ MODKEY, XK_i, incnmaster, {.i = +1 } },
|
||||
{ MODKEY, XK_d, incnmaster, {.i = -1 } },
|
||||
{ MODKEY, XK_h, setmfact, {.f = -0.05} },
|
||||
{ MODKEY, XK_l, setmfact, {.f = +0.05} },
|
||||
{ MODKEY, XK_z, zoom, {0} },
|
||||
{ MODKEY, XK_Tab, view, {0} },
|
||||
{ MODKEY|ShiftMask, XK_c, killclient, {0} },
|
||||
{ MODKEY, XK_t, setlayout, {.v = &layouts[0]} },
|
||||
{ MODKEY, XK_f, setlayout, {.v = &layouts[1]} },
|
||||
{ MODKEY, XK_m, setlayout, {.v = &layouts[2]} },
|
||||
{ MODKEY, XK_space, setlayout, {0} },
|
||||
{ MODKEY|ShiftMask, XK_space, togglefloating, {0} },
|
||||
{ MODKEY|ShiftMask, XK_f, togglefullscreen, {0} },
|
||||
{ MODKEY, XK_0, view, {.ui = ~0 } },
|
||||
{ MODKEY|ShiftMask, XK_0, tag, {.ui = ~0 } },
|
||||
{ MODKEY, XK_comma, focusmon, {.i = -1 } },
|
||||
{ MODKEY, XK_period, focusmon, {.i = +1 } },
|
||||
{ MODKEY|ShiftMask, XK_comma, tagmon, {.i = -1 } },
|
||||
{ MODKEY|ShiftMask, XK_period, tagmon, {.i = +1 } },
|
||||
{ MODKEY|ShiftMask, XK_Print, spawn, {.v = scrncmd } },
|
||||
{ 0, XF86XK_AudioPlay, spawn, {.v = playcmd } },
|
||||
TAGKEYS( XK_1, 0)
|
||||
TAGKEYS( XK_2, 1)
|
||||
TAGKEYS( XK_3, 2)
|
||||
TAGKEYS( XK_4, 3)
|
||||
TAGKEYS( XK_5, 4)
|
||||
TAGKEYS( XK_6, 5)
|
||||
TAGKEYS( XK_7, 6)
|
||||
TAGKEYS( XK_8, 7)
|
||||
TAGKEYS( XK_9, 8)
|
||||
{ MODKEY|ShiftMask, XK_q, quit, {0} },
|
||||
};
|
||||
|
||||
/* button definitions */
|
||||
/* click can be ClkTagBar, ClkLtSymbol, ClkStatusText, ClkWinTitle, ClkClientWin, or ClkRootWin */
|
||||
static const Button buttons[] = {
|
||||
/* click event mask button function argument */
|
||||
{ ClkLtSymbol, 0, Button1, setlayout, {0} },
|
||||
{ ClkLtSymbol, 0, Button3, setlayout, {.v = &layouts[2]} },
|
||||
{ ClkWinTitle, 0, Button2, zoom, {0} },
|
||||
{ ClkStatusText, 0, Button2, spawn, {.v = termcmd } },
|
||||
{ ClkClientWin, MODKEY, Button1, movemouse, {0} },
|
||||
{ ClkClientWin, MODKEY, Button2, togglefloating, {0} },
|
||||
{ ClkClientWin, MODKEY, Button3, resizemouse, {0} },
|
||||
{ ClkTagBar, 0, Button1, view, {0} },
|
||||
{ ClkTagBar, 0, Button3, toggleview, {0} },
|
||||
{ ClkTagBar, MODKEY, Button1, tag, {0} },
|
||||
{ ClkTagBar, MODKEY, Button3, toggletag, {0} },
|
||||
};
|
||||
|
||||
25
machines/universedesktop/desktop/dwm/fullscreen.patch
Normal file
25
machines/universedesktop/desktop/dwm/fullscreen.patch
Normal file
@@ -0,0 +1,25 @@
|
||||
diff --git a/dwm.c b/dwm.c
|
||||
index f1d86b2..17b595a 100644
|
||||
--- a/dwm.c
|
||||
+++ b/dwm.c
|
||||
@@ -211,6 +211,7 @@ static void tagmon(const Arg *arg);
|
||||
static void tile(Monitor *m);
|
||||
static void togglebar(const Arg *arg);
|
||||
static void togglefloating(const Arg *arg);
|
||||
+static void togglefullscreen(const Arg *arg);
|
||||
static void toggletag(const Arg *arg);
|
||||
static void toggleview(const Arg *arg);
|
||||
static void unfocus(Client *c, int setfocus);
|
||||
@@ -1735,6 +1736,12 @@ togglefloating(const Arg *arg)
|
||||
arrange(selmon);
|
||||
}
|
||||
|
||||
+void togglefullscreen(const Arg *arg)
|
||||
+{
|
||||
+ if(selmon->sel)
|
||||
+ setfullscreen(selmon->sel, !selmon->sel->isfullscreen);
|
||||
+}
|
||||
+
|
||||
void
|
||||
toggletag(const Arg *arg)
|
||||
{
|
||||
474
machines/universedesktop/desktop/dwm/st-config.def.h
Normal file
474
machines/universedesktop/desktop/dwm/st-config.def.h
Normal file
@@ -0,0 +1,474 @@
|
||||
/* See LICENSE file for copyright and license details. */
|
||||
|
||||
/*
|
||||
* appearance
|
||||
*
|
||||
* font: see http://freedesktop.org/software/fontconfig/fontconfig-user.html
|
||||
*/
|
||||
static char *font = "Liberation Mono:pixelsize=24:antialias=true:autohint=true";
|
||||
static int borderpx = 2;
|
||||
|
||||
/*
|
||||
* What program is execed by st depends of these precedence rules:
|
||||
* 1: program passed with -e
|
||||
* 2: scroll and/or utmp
|
||||
* 3: SHELL environment variable
|
||||
* 4: value of shell in /etc/passwd
|
||||
* 5: value of shell in config.h
|
||||
*/
|
||||
static char *shell = "/bin/sh";
|
||||
char *utmp = NULL;
|
||||
/* scroll program: to enable use a string like "scroll" */
|
||||
char *scroll = NULL;
|
||||
char *stty_args = "stty raw pass8 nl -echo -iexten -cstopb 38400";
|
||||
|
||||
/* identification sequence returned in DA and DECID */
|
||||
char *vtiden = "\033[?6c";
|
||||
|
||||
/* Kerning / character bounding-box multipliers */
|
||||
static float cwscale = 1.0;
|
||||
static float chscale = 1.0;
|
||||
|
||||
/*
|
||||
* word delimiter string
|
||||
*
|
||||
* More advanced example: L" `'\"()[]{}"
|
||||
*/
|
||||
wchar_t *worddelimiters = L" ";
|
||||
|
||||
/* selection timeouts (in milliseconds) */
|
||||
static unsigned int doubleclicktimeout = 300;
|
||||
static unsigned int tripleclicktimeout = 600;
|
||||
|
||||
/* alt screens */
|
||||
int allowaltscreen = 1;
|
||||
|
||||
/* allow certain non-interactive (insecure) window operations such as:
|
||||
setting the clipboard text */
|
||||
int allowwindowops = 0;
|
||||
|
||||
/*
|
||||
* draw latency range in ms - from new content/keypress/etc until drawing.
|
||||
* within this range, st draws when content stops arriving (idle). mostly it's
|
||||
* near minlatency, but it waits longer for slow updates to avoid partial draw.
|
||||
* low minlatency will tear/flicker more, as it can "detect" idle too early.
|
||||
*/
|
||||
static double minlatency = 2;
|
||||
static double maxlatency = 33;
|
||||
|
||||
/*
|
||||
* blinking timeout (set to 0 to disable blinking) for the terminal blinking
|
||||
* attribute.
|
||||
*/
|
||||
static unsigned int blinktimeout = 800;
|
||||
|
||||
/*
|
||||
* thickness of underline and bar cursors
|
||||
*/
|
||||
static unsigned int cursorthickness = 2;
|
||||
|
||||
/*
|
||||
* bell volume. It must be a value between -100 and 100. Use 0 for disabling
|
||||
* it
|
||||
*/
|
||||
static int bellvolume = 0;
|
||||
|
||||
/* default TERM value */
|
||||
char *termname = "st-256color";
|
||||
|
||||
/*
|
||||
* spaces per tab
|
||||
*
|
||||
* When you are changing this value, don't forget to adapt the »it« value in
|
||||
* the st.info and appropriately install the st.info in the environment where
|
||||
* you use this st version.
|
||||
*
|
||||
* it#$tabspaces,
|
||||
*
|
||||
* Secondly make sure your kernel is not expanding tabs. When running `stty
|
||||
* -a` »tab0« should appear. You can tell the terminal to not expand tabs by
|
||||
* running following command:
|
||||
*
|
||||
* stty tabs
|
||||
*/
|
||||
unsigned int tabspaces = 8;
|
||||
|
||||
/* Terminal colors (16 first used in escape sequence) */
|
||||
static const char *colorname[] = {
|
||||
/* 8 normal colors */
|
||||
"black",
|
||||
"red3",
|
||||
"green3",
|
||||
"yellow3",
|
||||
"blue2",
|
||||
"magenta3",
|
||||
"cyan3",
|
||||
"gray90",
|
||||
|
||||
/* 8 bright colors */
|
||||
"gray50",
|
||||
"red",
|
||||
"green",
|
||||
"yellow",
|
||||
"#5c5cff",
|
||||
"magenta",
|
||||
"cyan",
|
||||
"white",
|
||||
|
||||
[255] = 0,
|
||||
|
||||
/* more colors can be added after 255 to use with DefaultXX */
|
||||
"#cccccc",
|
||||
"#555555",
|
||||
"gray90", /* default foreground colour */
|
||||
"black", /* default background colour */
|
||||
};
|
||||
|
||||
|
||||
/*
|
||||
* Default colors (colorname index)
|
||||
* foreground, background, cursor, reverse cursor
|
||||
*/
|
||||
unsigned int defaultfg = 258;
|
||||
unsigned int defaultbg = 259;
|
||||
unsigned int defaultcs = 256;
|
||||
static unsigned int defaultrcs = 257;
|
||||
|
||||
/*
|
||||
* Default shape of cursor
|
||||
* 2: Block ("█")
|
||||
* 4: Underline ("_")
|
||||
* 6: Bar ("|")
|
||||
* 7: Snowman ("☃")
|
||||
*/
|
||||
static unsigned int cursorshape = 2;
|
||||
|
||||
/*
|
||||
* Default columns and rows numbers
|
||||
*/
|
||||
|
||||
static unsigned int cols = 80;
|
||||
static unsigned int rows = 24;
|
||||
|
||||
/*
|
||||
* Default colour and shape of the mouse cursor
|
||||
*/
|
||||
static unsigned int mouseshape = XC_xterm;
|
||||
static unsigned int mousefg = 7;
|
||||
static unsigned int mousebg = 0;
|
||||
|
||||
/*
|
||||
* Color used to display font attributes when fontconfig selected a font which
|
||||
* doesn't match the ones requested.
|
||||
*/
|
||||
static unsigned int defaultattr = 11;
|
||||
|
||||
/*
|
||||
* Force mouse select/shortcuts while mask is active (when MODE_MOUSE is set).
|
||||
* Note that if you want to use ShiftMask with selmasks, set this to an other
|
||||
* modifier, set to 0 to not use it.
|
||||
*/
|
||||
static uint forcemousemod = ShiftMask;
|
||||
|
||||
/*
|
||||
* Internal mouse shortcuts.
|
||||
* Beware that overloading Button1 will disable the selection.
|
||||
*/
|
||||
static MouseShortcut mshortcuts[] = {
|
||||
/* mask button function argument release */
|
||||
{ XK_ANY_MOD, Button2, selpaste, {.i = 0}, 1 },
|
||||
{ ShiftMask, Button4, ttysend, {.s = "\033[5;2~"} },
|
||||
{ XK_ANY_MOD, Button4, ttysend, {.s = "\031"} },
|
||||
{ ShiftMask, Button5, ttysend, {.s = "\033[6;2~"} },
|
||||
{ XK_ANY_MOD, Button5, ttysend, {.s = "\005"} },
|
||||
};
|
||||
|
||||
/* Internal keyboard shortcuts. */
|
||||
#define MODKEY Mod1Mask
|
||||
#define TERMMOD (ControlMask|ShiftMask)
|
||||
|
||||
static Shortcut shortcuts[] = {
|
||||
/* mask keysym function argument */
|
||||
{ XK_ANY_MOD, XK_Break, sendbreak, {.i = 0} },
|
||||
{ ControlMask, XK_Print, toggleprinter, {.i = 0} },
|
||||
{ ShiftMask, XK_Print, printscreen, {.i = 0} },
|
||||
{ XK_ANY_MOD, XK_Print, printsel, {.i = 0} },
|
||||
{ ControlMask|ShiftMask, XK_KP_Subtract, zoom, {.f = -1} },
|
||||
{ ControlMask|ShiftMask, XK_KP_Equal, zoom, {.f = +1} },
|
||||
{ ControlMask, XK_Home, zoomreset, {.f = 0} },
|
||||
{ ControlMask|ShiftMask, XK_C, clipcopy, {.i = 0} },
|
||||
{ ControlMask|ShiftMask, XK_V, clippaste, {.i = 0} },
|
||||
{ ControlMask, XK_Y, selpaste, {.i = 0} },
|
||||
{ ShiftMask, XK_Insert, selpaste, {.i = 0} },
|
||||
{ TERMMOD, XK_Num_Lock, numlock, {.i = 0} },
|
||||
};
|
||||
|
||||
/*
|
||||
* Special keys (change & recompile st.info accordingly)
|
||||
*
|
||||
* Mask value:
|
||||
* * Use XK_ANY_MOD to match the key no matter modifiers state
|
||||
* * Use XK_NO_MOD to match the key alone (no modifiers)
|
||||
* appkey value:
|
||||
* * 0: no value
|
||||
* * > 0: keypad application mode enabled
|
||||
* * = 2: term.numlock = 1
|
||||
* * < 0: keypad application mode disabled
|
||||
* appcursor value:
|
||||
* * 0: no value
|
||||
* * > 0: cursor application mode enabled
|
||||
* * < 0: cursor application mode disabled
|
||||
*
|
||||
* Be careful with the order of the definitions because st searches in
|
||||
* this table sequentially, so any XK_ANY_MOD must be in the last
|
||||
* position for a key.
|
||||
*/
|
||||
|
||||
/*
|
||||
* If you want keys other than the X11 function keys (0xFD00 - 0xFFFF)
|
||||
* to be mapped below, add them to this array.
|
||||
*/
|
||||
static KeySym mappedkeys[] = { -1 };
|
||||
|
||||
/*
|
||||
* State bits to ignore when matching key or button events. By default,
|
||||
* numlock (Mod2Mask) and keyboard layout (XK_SWITCH_MOD) are ignored.
|
||||
*/
|
||||
static uint ignoremod = Mod2Mask|XK_SWITCH_MOD;
|
||||
|
||||
/*
|
||||
* This is the huge key array which defines all compatibility to the Linux
|
||||
* world. Please decide about changes wisely.
|
||||
*/
|
||||
static Key key[] = {
|
||||
/* keysym mask string appkey appcursor */
|
||||
{ XK_KP_Home, ShiftMask, "\033[2J", 0, -1},
|
||||
{ XK_KP_Home, ShiftMask, "\033[1;2H", 0, +1},
|
||||
{ XK_KP_Home, XK_ANY_MOD, "\033[H", 0, -1},
|
||||
{ XK_KP_Home, XK_ANY_MOD, "\033[1~", 0, +1},
|
||||
{ XK_KP_Up, XK_ANY_MOD, "\033Ox", +1, 0},
|
||||
{ XK_KP_Up, XK_ANY_MOD, "\033[A", 0, -1},
|
||||
{ XK_KP_Up, XK_ANY_MOD, "\033OA", 0, +1},
|
||||
{ XK_KP_Down, XK_ANY_MOD, "\033Or", +1, 0},
|
||||
{ XK_KP_Down, XK_ANY_MOD, "\033[B", 0, -1},
|
||||
{ XK_KP_Down, XK_ANY_MOD, "\033OB", 0, +1},
|
||||
{ XK_KP_Left, XK_ANY_MOD, "\033Ot", +1, 0},
|
||||
{ XK_KP_Left, XK_ANY_MOD, "\033[D", 0, -1},
|
||||
{ XK_KP_Left, XK_ANY_MOD, "\033OD", 0, +1},
|
||||
{ XK_KP_Right, XK_ANY_MOD, "\033Ov", +1, 0},
|
||||
{ XK_KP_Right, XK_ANY_MOD, "\033[C", 0, -1},
|
||||
{ XK_KP_Right, XK_ANY_MOD, "\033OC", 0, +1},
|
||||
{ XK_KP_Prior, ShiftMask, "\033[5;2~", 0, 0},
|
||||
{ XK_KP_Prior, XK_ANY_MOD, "\033[5~", 0, 0},
|
||||
{ XK_KP_Begin, XK_ANY_MOD, "\033[E", 0, 0},
|
||||
{ XK_KP_End, ControlMask, "\033[J", -1, 0},
|
||||
{ XK_KP_End, ControlMask, "\033[1;5F", +1, 0},
|
||||
{ XK_KP_End, ShiftMask, "\033[K", -1, 0},
|
||||
{ XK_KP_End, ShiftMask, "\033[1;2F", +1, 0},
|
||||
{ XK_KP_End, XK_ANY_MOD, "\033[4~", 0, 0},
|
||||
{ XK_KP_Next, ShiftMask, "\033[6;2~", 0, 0},
|
||||
{ XK_KP_Next, XK_ANY_MOD, "\033[6~", 0, 0},
|
||||
{ XK_KP_Insert, ShiftMask, "\033[2;2~", +1, 0},
|
||||
{ XK_KP_Insert, ShiftMask, "\033[4l", -1, 0},
|
||||
{ XK_KP_Insert, ControlMask, "\033[L", -1, 0},
|
||||
{ XK_KP_Insert, ControlMask, "\033[2;5~", +1, 0},
|
||||
{ XK_KP_Insert, XK_ANY_MOD, "\033[4h", -1, 0},
|
||||
{ XK_KP_Insert, XK_ANY_MOD, "\033[2~", +1, 0},
|
||||
{ XK_KP_Delete, ControlMask, "\033[M", -1, 0},
|
||||
{ XK_KP_Delete, ControlMask, "\033[3;5~", +1, 0},
|
||||
{ XK_KP_Delete, ShiftMask, "\033[2K", -1, 0},
|
||||
{ XK_KP_Delete, ShiftMask, "\033[3;2~", +1, 0},
|
||||
{ XK_KP_Delete, XK_ANY_MOD, "\033[P", -1, 0},
|
||||
{ XK_KP_Delete, XK_ANY_MOD, "\033[3~", +1, 0},
|
||||
{ XK_KP_Multiply, XK_ANY_MOD, "\033Oj", +2, 0},
|
||||
{ XK_KP_Add, XK_ANY_MOD, "\033Ok", +2, 0},
|
||||
{ XK_KP_Enter, XK_ANY_MOD, "\033OM", +2, 0},
|
||||
{ XK_KP_Enter, XK_ANY_MOD, "\r", -1, 0},
|
||||
{ XK_KP_Subtract, XK_ANY_MOD, "\033Om", +2, 0},
|
||||
{ XK_KP_Decimal, XK_ANY_MOD, "\033On", +2, 0},
|
||||
{ XK_KP_Divide, XK_ANY_MOD, "\033Oo", +2, 0},
|
||||
{ XK_KP_0, XK_ANY_MOD, "\033Op", +2, 0},
|
||||
{ XK_KP_1, XK_ANY_MOD, "\033Oq", +2, 0},
|
||||
{ XK_KP_2, XK_ANY_MOD, "\033Or", +2, 0},
|
||||
{ XK_KP_3, XK_ANY_MOD, "\033Os", +2, 0},
|
||||
{ XK_KP_4, XK_ANY_MOD, "\033Ot", +2, 0},
|
||||
{ XK_KP_5, XK_ANY_MOD, "\033Ou", +2, 0},
|
||||
{ XK_KP_6, XK_ANY_MOD, "\033Ov", +2, 0},
|
||||
{ XK_KP_7, XK_ANY_MOD, "\033Ow", +2, 0},
|
||||
{ XK_KP_8, XK_ANY_MOD, "\033Ox", +2, 0},
|
||||
{ XK_KP_9, XK_ANY_MOD, "\033Oy", +2, 0},
|
||||
{ XK_Up, ShiftMask, "\033[1;2A", 0, 0},
|
||||
{ XK_Up, Mod1Mask, "\033[1;3A", 0, 0},
|
||||
{ XK_Up, ShiftMask|Mod1Mask,"\033[1;4A", 0, 0},
|
||||
{ XK_Up, ControlMask, "\033[1;5A", 0, 0},
|
||||
{ XK_Up, ShiftMask|ControlMask,"\033[1;6A", 0, 0},
|
||||
{ XK_Up, ControlMask|Mod1Mask,"\033[1;7A", 0, 0},
|
||||
{ XK_Up,ShiftMask|ControlMask|Mod1Mask,"\033[1;8A", 0, 0},
|
||||
{ XK_Up, XK_ANY_MOD, "\033[A", 0, -1},
|
||||
{ XK_Up, XK_ANY_MOD, "\033OA", 0, +1},
|
||||
{ XK_Down, ShiftMask, "\033[1;2B", 0, 0},
|
||||
{ XK_Down, Mod1Mask, "\033[1;3B", 0, 0},
|
||||
{ XK_Down, ShiftMask|Mod1Mask,"\033[1;4B", 0, 0},
|
||||
{ XK_Down, ControlMask, "\033[1;5B", 0, 0},
|
||||
{ XK_Down, ShiftMask|ControlMask,"\033[1;6B", 0, 0},
|
||||
{ XK_Down, ControlMask|Mod1Mask,"\033[1;7B", 0, 0},
|
||||
{ XK_Down,ShiftMask|ControlMask|Mod1Mask,"\033[1;8B",0, 0},
|
||||
{ XK_Down, XK_ANY_MOD, "\033[B", 0, -1},
|
||||
{ XK_Down, XK_ANY_MOD, "\033OB", 0, +1},
|
||||
{ XK_Left, ShiftMask, "\033[1;2D", 0, 0},
|
||||
{ XK_Left, Mod1Mask, "\033[1;3D", 0, 0},
|
||||
{ XK_Left, ShiftMask|Mod1Mask,"\033[1;4D", 0, 0},
|
||||
{ XK_Left, ControlMask, "\033[1;5D", 0, 0},
|
||||
{ XK_Left, ShiftMask|ControlMask,"\033[1;6D", 0, 0},
|
||||
{ XK_Left, ControlMask|Mod1Mask,"\033[1;7D", 0, 0},
|
||||
{ XK_Left,ShiftMask|ControlMask|Mod1Mask,"\033[1;8D",0, 0},
|
||||
{ XK_Left, XK_ANY_MOD, "\033[D", 0, -1},
|
||||
{ XK_Left, XK_ANY_MOD, "\033OD", 0, +1},
|
||||
{ XK_Right, ShiftMask, "\033[1;2C", 0, 0},
|
||||
{ XK_Right, Mod1Mask, "\033[1;3C", 0, 0},
|
||||
{ XK_Right, ShiftMask|Mod1Mask,"\033[1;4C", 0, 0},
|
||||
{ XK_Right, ControlMask, "\033[1;5C", 0, 0},
|
||||
{ XK_Right, ShiftMask|ControlMask,"\033[1;6C", 0, 0},
|
||||
{ XK_Right, ControlMask|Mod1Mask,"\033[1;7C", 0, 0},
|
||||
{ XK_Right,ShiftMask|ControlMask|Mod1Mask,"\033[1;8C",0, 0},
|
||||
{ XK_Right, XK_ANY_MOD, "\033[C", 0, -1},
|
||||
{ XK_Right, XK_ANY_MOD, "\033OC", 0, +1},
|
||||
{ XK_ISO_Left_Tab, ShiftMask, "\033[Z", 0, 0},
|
||||
{ XK_Return, Mod1Mask, "\033\r", 0, 0},
|
||||
{ XK_Return, XK_ANY_MOD, "\r", 0, 0},
|
||||
{ XK_Insert, ShiftMask, "\033[4l", -1, 0},
|
||||
{ XK_Insert, ShiftMask, "\033[2;2~", +1, 0},
|
||||
{ XK_Insert, ControlMask, "\033[L", -1, 0},
|
||||
{ XK_Insert, ControlMask, "\033[2;5~", +1, 0},
|
||||
{ XK_Insert, XK_ANY_MOD, "\033[4h", -1, 0},
|
||||
{ XK_Insert, XK_ANY_MOD, "\033[2~", +1, 0},
|
||||
{ XK_Delete, ControlMask, "\033[M", -1, 0},
|
||||
{ XK_Delete, ControlMask, "\033[3;5~", +1, 0},
|
||||
{ XK_Delete, ShiftMask, "\033[2K", -1, 0},
|
||||
{ XK_Delete, ShiftMask, "\033[3;2~", +1, 0},
|
||||
{ XK_Delete, XK_ANY_MOD, "\033[P", -1, 0},
|
||||
{ XK_Delete, XK_ANY_MOD, "\033[3~", +1, 0},
|
||||
{ XK_BackSpace, XK_NO_MOD, "\177", 0, 0},
|
||||
{ XK_BackSpace, Mod1Mask, "\033\177", 0, 0},
|
||||
{ XK_Home, ShiftMask, "\033[2J", 0, -1},
|
||||
{ XK_Home, ShiftMask, "\033[1;2H", 0, +1},
|
||||
{ XK_Home, XK_ANY_MOD, "\033[H", 0, -1},
|
||||
{ XK_Home, XK_ANY_MOD, "\033[1~", 0, +1},
|
||||
{ XK_End, ControlMask, "\033[J", -1, 0},
|
||||
{ XK_End, ControlMask, "\033[1;5F", +1, 0},
|
||||
{ XK_End, ShiftMask, "\033[K", -1, 0},
|
||||
{ XK_End, ShiftMask, "\033[1;2F", +1, 0},
|
||||
{ XK_End, XK_ANY_MOD, "\033[4~", 0, 0},
|
||||
{ XK_Prior, ControlMask, "\033[5;5~", 0, 0},
|
||||
{ XK_Prior, ShiftMask, "\033[5;2~", 0, 0},
|
||||
{ XK_Prior, XK_ANY_MOD, "\033[5~", 0, 0},
|
||||
{ XK_Next, ControlMask, "\033[6;5~", 0, 0},
|
||||
{ XK_Next, ShiftMask, "\033[6;2~", 0, 0},
|
||||
{ XK_Next, XK_ANY_MOD, "\033[6~", 0, 0},
|
||||
{ XK_F1, XK_NO_MOD, "\033OP" , 0, 0},
|
||||
{ XK_F1, /* F13 */ ShiftMask, "\033[1;2P", 0, 0},
|
||||
{ XK_F1, /* F25 */ ControlMask, "\033[1;5P", 0, 0},
|
||||
{ XK_F1, /* F37 */ Mod4Mask, "\033[1;6P", 0, 0},
|
||||
{ XK_F1, /* F49 */ Mod1Mask, "\033[1;3P", 0, 0},
|
||||
{ XK_F1, /* F61 */ Mod3Mask, "\033[1;4P", 0, 0},
|
||||
{ XK_F2, XK_NO_MOD, "\033OQ" , 0, 0},
|
||||
{ XK_F2, /* F14 */ ShiftMask, "\033[1;2Q", 0, 0},
|
||||
{ XK_F2, /* F26 */ ControlMask, "\033[1;5Q", 0, 0},
|
||||
{ XK_F2, /* F38 */ Mod4Mask, "\033[1;6Q", 0, 0},
|
||||
{ XK_F2, /* F50 */ Mod1Mask, "\033[1;3Q", 0, 0},
|
||||
{ XK_F2, /* F62 */ Mod3Mask, "\033[1;4Q", 0, 0},
|
||||
{ XK_F3, XK_NO_MOD, "\033OR" , 0, 0},
|
||||
{ XK_F3, /* F15 */ ShiftMask, "\033[1;2R", 0, 0},
|
||||
{ XK_F3, /* F27 */ ControlMask, "\033[1;5R", 0, 0},
|
||||
{ XK_F3, /* F39 */ Mod4Mask, "\033[1;6R", 0, 0},
|
||||
{ XK_F3, /* F51 */ Mod1Mask, "\033[1;3R", 0, 0},
|
||||
{ XK_F3, /* F63 */ Mod3Mask, "\033[1;4R", 0, 0},
|
||||
{ XK_F4, XK_NO_MOD, "\033OS" , 0, 0},
|
||||
{ XK_F4, /* F16 */ ShiftMask, "\033[1;2S", 0, 0},
|
||||
{ XK_F4, /* F28 */ ControlMask, "\033[1;5S", 0, 0},
|
||||
{ XK_F4, /* F40 */ Mod4Mask, "\033[1;6S", 0, 0},
|
||||
{ XK_F4, /* F52 */ Mod1Mask, "\033[1;3S", 0, 0},
|
||||
{ XK_F5, XK_NO_MOD, "\033[15~", 0, 0},
|
||||
{ XK_F5, /* F17 */ ShiftMask, "\033[15;2~", 0, 0},
|
||||
{ XK_F5, /* F29 */ ControlMask, "\033[15;5~", 0, 0},
|
||||
{ XK_F5, /* F41 */ Mod4Mask, "\033[15;6~", 0, 0},
|
||||
{ XK_F5, /* F53 */ Mod1Mask, "\033[15;3~", 0, 0},
|
||||
{ XK_F6, XK_NO_MOD, "\033[17~", 0, 0},
|
||||
{ XK_F6, /* F18 */ ShiftMask, "\033[17;2~", 0, 0},
|
||||
{ XK_F6, /* F30 */ ControlMask, "\033[17;5~", 0, 0},
|
||||
{ XK_F6, /* F42 */ Mod4Mask, "\033[17;6~", 0, 0},
|
||||
{ XK_F6, /* F54 */ Mod1Mask, "\033[17;3~", 0, 0},
|
||||
{ XK_F7, XK_NO_MOD, "\033[18~", 0, 0},
|
||||
{ XK_F7, /* F19 */ ShiftMask, "\033[18;2~", 0, 0},
|
||||
{ XK_F7, /* F31 */ ControlMask, "\033[18;5~", 0, 0},
|
||||
{ XK_F7, /* F43 */ Mod4Mask, "\033[18;6~", 0, 0},
|
||||
{ XK_F7, /* F55 */ Mod1Mask, "\033[18;3~", 0, 0},
|
||||
{ XK_F8, XK_NO_MOD, "\033[19~", 0, 0},
|
||||
{ XK_F8, /* F20 */ ShiftMask, "\033[19;2~", 0, 0},
|
||||
{ XK_F8, /* F32 */ ControlMask, "\033[19;5~", 0, 0},
|
||||
{ XK_F8, /* F44 */ Mod4Mask, "\033[19;6~", 0, 0},
|
||||
{ XK_F8, /* F56 */ Mod1Mask, "\033[19;3~", 0, 0},
|
||||
{ XK_F9, XK_NO_MOD, "\033[20~", 0, 0},
|
||||
{ XK_F9, /* F21 */ ShiftMask, "\033[20;2~", 0, 0},
|
||||
{ XK_F9, /* F33 */ ControlMask, "\033[20;5~", 0, 0},
|
||||
{ XK_F9, /* F45 */ Mod4Mask, "\033[20;6~", 0, 0},
|
||||
{ XK_F9, /* F57 */ Mod1Mask, "\033[20;3~", 0, 0},
|
||||
{ XK_F10, XK_NO_MOD, "\033[21~", 0, 0},
|
||||
{ XK_F10, /* F22 */ ShiftMask, "\033[21;2~", 0, 0},
|
||||
{ XK_F10, /* F34 */ ControlMask, "\033[21;5~", 0, 0},
|
||||
{ XK_F10, /* F46 */ Mod4Mask, "\033[21;6~", 0, 0},
|
||||
{ XK_F10, /* F58 */ Mod1Mask, "\033[21;3~", 0, 0},
|
||||
{ XK_F11, XK_NO_MOD, "\033[23~", 0, 0},
|
||||
{ XK_F11, /* F23 */ ShiftMask, "\033[23;2~", 0, 0},
|
||||
{ XK_F11, /* F35 */ ControlMask, "\033[23;5~", 0, 0},
|
||||
{ XK_F11, /* F47 */ Mod4Mask, "\033[23;6~", 0, 0},
|
||||
{ XK_F11, /* F59 */ Mod1Mask, "\033[23;3~", 0, 0},
|
||||
{ XK_F12, XK_NO_MOD, "\033[24~", 0, 0},
|
||||
{ XK_F12, /* F24 */ ShiftMask, "\033[24;2~", 0, 0},
|
||||
{ XK_F12, /* F36 */ ControlMask, "\033[24;5~", 0, 0},
|
||||
{ XK_F12, /* F48 */ Mod4Mask, "\033[24;6~", 0, 0},
|
||||
{ XK_F12, /* F60 */ Mod1Mask, "\033[24;3~", 0, 0},
|
||||
{ XK_F13, XK_NO_MOD, "\033[1;2P", 0, 0},
|
||||
{ XK_F14, XK_NO_MOD, "\033[1;2Q", 0, 0},
|
||||
{ XK_F15, XK_NO_MOD, "\033[1;2R", 0, 0},
|
||||
{ XK_F16, XK_NO_MOD, "\033[1;2S", 0, 0},
|
||||
{ XK_F17, XK_NO_MOD, "\033[15;2~", 0, 0},
|
||||
{ XK_F18, XK_NO_MOD, "\033[17;2~", 0, 0},
|
||||
{ XK_F19, XK_NO_MOD, "\033[18;2~", 0, 0},
|
||||
{ XK_F20, XK_NO_MOD, "\033[19;2~", 0, 0},
|
||||
{ XK_F21, XK_NO_MOD, "\033[20;2~", 0, 0},
|
||||
{ XK_F22, XK_NO_MOD, "\033[21;2~", 0, 0},
|
||||
{ XK_F23, XK_NO_MOD, "\033[23;2~", 0, 0},
|
||||
{ XK_F24, XK_NO_MOD, "\033[24;2~", 0, 0},
|
||||
{ XK_F25, XK_NO_MOD, "\033[1;5P", 0, 0},
|
||||
{ XK_F26, XK_NO_MOD, "\033[1;5Q", 0, 0},
|
||||
{ XK_F27, XK_NO_MOD, "\033[1;5R", 0, 0},
|
||||
{ XK_F28, XK_NO_MOD, "\033[1;5S", 0, 0},
|
||||
{ XK_F29, XK_NO_MOD, "\033[15;5~", 0, 0},
|
||||
{ XK_F30, XK_NO_MOD, "\033[17;5~", 0, 0},
|
||||
{ XK_F31, XK_NO_MOD, "\033[18;5~", 0, 0},
|
||||
{ XK_F32, XK_NO_MOD, "\033[19;5~", 0, 0},
|
||||
{ XK_F33, XK_NO_MOD, "\033[20;5~", 0, 0},
|
||||
{ XK_F34, XK_NO_MOD, "\033[21;5~", 0, 0},
|
||||
{ XK_F35, XK_NO_MOD, "\033[23;5~", 0, 0},
|
||||
};
|
||||
|
||||
/*
|
||||
* Selection types' masks.
|
||||
* Use the same masks as usual.
|
||||
* Button1Mask is always unset, to make masks match between ButtonPress.
|
||||
* ButtonRelease and MotionNotify.
|
||||
* If no match is found, regular selection is used.
|
||||
*/
|
||||
static uint selmasks[] = {
|
||||
[SEL_RECTANGULAR] = Mod1Mask,
|
||||
};
|
||||
|
||||
/*
|
||||
* Printable characters in ASCII, used to estimate the advance width
|
||||
* of single wide characters.
|
||||
*/
|
||||
static char ascii_printable[] =
|
||||
" !\"#$%&'()*+,-./0123456789:;<=>?"
|
||||
"@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_"
|
||||
"`abcdefghijklmnopqrstuvwxyz{|}~";
|
||||
2
machines/universedesktop/desktop/emptty.conf
Normal file
2
machines/universedesktop/desktop/emptty.conf
Normal file
@@ -0,0 +1,2 @@
|
||||
TTY_NUMBER=7
|
||||
|
||||
33
machines/universedesktop/desktop/emptty.nix
Normal file
33
machines/universedesktop/desktop/emptty.nix
Normal file
@@ -0,0 +1,33 @@
|
||||
{ config, pkgs, lib, ... }: let
|
||||
empttyConf = pkgs.writeText "emptty-config" ''
|
||||
TTY_NUMBER=7
|
||||
|
||||
WAYLAND_SESSIONS_PATH="${config.services.displayManager.sessionData.desktops}/share/wayland-sessions"
|
||||
'';
|
||||
in {
|
||||
services.displayManager = {
|
||||
enable = true;
|
||||
execCmd = "${pkgs.emptty}/bin/emptty -d";
|
||||
};
|
||||
systemd.services.display-manager = {
|
||||
enable = true;
|
||||
path = [pkgs.dwl];
|
||||
serviceConfig = {
|
||||
EnvironmentFile = empttyConf;
|
||||
Type="idle";
|
||||
TTYPath="/dev/tty7";
|
||||
TTYReset="yes";
|
||||
SendSIGHUP="yes";
|
||||
KillMode="process";
|
||||
};
|
||||
};
|
||||
|
||||
security.pam.services = {
|
||||
emptty.text = ''
|
||||
auth substack sshd
|
||||
account include sshd
|
||||
password substack sshd
|
||||
session include sshd
|
||||
'';
|
||||
};
|
||||
}
|
||||
5
machines/universedesktop/desktop/gnome.nix
Normal file
5
machines/universedesktop/desktop/gnome.nix
Normal file
@@ -0,0 +1,5 @@
|
||||
{ config, pkgs, lib, ... }: {
|
||||
services.xserver.enable = true;
|
||||
services.xserver.displayManager.gdm.enable = true;
|
||||
services.xserver.desktopManager.gnome.enable = true;
|
||||
}
|
||||
29
machines/universedesktop/desktop/graphics.nix
Normal file
29
machines/universedesktop/desktop/graphics.nix
Normal file
@@ -0,0 +1,29 @@
|
||||
{ config, pkgs, lib, ... }: {
|
||||
hardware = {
|
||||
graphics.enable = true;
|
||||
graphics.enable32Bit = true;
|
||||
|
||||
nvidia = {
|
||||
#modesetting.enable = true;
|
||||
powerManagement.enable = false;
|
||||
powerManagement.finegrained = false;
|
||||
nvidiaSettings = true;
|
||||
open = true;
|
||||
# package = config.boot.kernelPackages.nvidiaPackages.vulkan_beta;
|
||||
#package = let
|
||||
# rcu_patch = pkgs.fetchpatch {
|
||||
# url = "https://github.com/gentoo/gentoo/raw/c64caf53/x11-drivers/nvidia-drivers/files/nvidia-drivers-470.223.02-gpl-pfn_valid.patch";
|
||||
# hash = "sha256-eZiQQp2S/asE7MfGvfe6dA/kdCvek9SYa/FFGp24dVg=";
|
||||
# };
|
||||
#in config.boot.kernelPackages.nvidiaPackages.mkDriver {
|
||||
# version = "535.154.05";
|
||||
# sha256_64bit = "sha256-fpUGXKprgt6SYRDxSCemGXLrEsIA6GOinp+0eGbqqJg=";
|
||||
# sha256_aarch64 = "sha256-G0/GiObf/BZMkzzET8HQjdIcvCSqB1uhsinro2HLK9k=";
|
||||
# openSha256 = "sha256-wvRdHguGLxS0mR06P5Qi++pDJBCF8pJ8hr4T8O6TJIo=";
|
||||
# settingsSha256 = "sha256-9wqoDEWY4I7weWW05F4igj1Gj9wjHsREFMztfEmqm10=";
|
||||
# persistencedSha256 = "sha256-d0Q3Lk80JqkS1B54Mahu2yY/WocOqFFbZVBh+ToGhaE=";
|
||||
# patches = [ rcu_patch ];
|
||||
#};
|
||||
};
|
||||
};
|
||||
}
|
||||
137
machines/universedesktop/desktop/lemurs.toml
Normal file
137
machines/universedesktop/desktop/lemurs.toml
Normal file
@@ -0,0 +1,137 @@
|
||||
# The PAM service that should be used to login
|
||||
pam_service = "sshd"
|
||||
|
||||
focus_behaviour = "password"
|
||||
|
||||
# General settings for background style
|
||||
[background]
|
||||
show_background = true
|
||||
|
||||
[background.style]
|
||||
# Allow to set the default background color for the login shell
|
||||
color = "black"
|
||||
# Settings for the background block's borders
|
||||
show_border = true
|
||||
border_color = "white"
|
||||
|
||||
# Shutdown option
|
||||
[[power_controls.base_entries]]
|
||||
hint = "Shutdown"
|
||||
hint_color = "dark gray"
|
||||
hint_modifiers = ""
|
||||
key = "F1"
|
||||
cmd = "systemctl poweroff -l"
|
||||
|
||||
# Reboot option
|
||||
[[power_controls.base_entries]]
|
||||
hint = "Reboot"
|
||||
hint_color = "dark gray"
|
||||
hint_modifiers = ""
|
||||
key = "F2"
|
||||
cmd = "systemctl reboot -l"
|
||||
|
||||
[environment_switcher]
|
||||
include_tty_shell = true
|
||||
mover_color_focused = "light cyan"
|
||||
mover_modifiers_focused = "bold"
|
||||
left_mover = "<["
|
||||
right_mover = "]>"
|
||||
|
||||
# Neighbours' color and modifiers whilst the selector is unfocused
|
||||
neighbour_color = "dark gray"
|
||||
neighbour_modifiers = ""
|
||||
|
||||
# Neighbours' color and modifiers whilst the selector is focused
|
||||
neighbour_color_focused = "gray"
|
||||
neighbour_modifiers_focused = ""
|
||||
|
||||
# Margin between neighbours and selected
|
||||
neighbour_margin = 1
|
||||
|
||||
# Selected's color and modifiers whilst the selector is unfocused
|
||||
selected_color = "gray"
|
||||
selected_modifiers = "underlined"
|
||||
|
||||
# Selected's color and modifiers whilst the selector is focused
|
||||
selected_color_focused = "white"
|
||||
selected_modifiers_focused = "bold"
|
||||
|
||||
# The length of the name of the desktop environment which is displayed.
|
||||
max_display_length = 8
|
||||
|
||||
# The text used when no desktop environments are available
|
||||
no_envs_text = "No environments..."
|
||||
|
||||
# The color and modifiers of the 'no desktop environments available text'
|
||||
# whilst the selector is unfocused
|
||||
no_envs_color = "white"
|
||||
no_envs_modifiers = ""
|
||||
|
||||
# The color and modifiers of the 'no desktop environments available text'
|
||||
# whilst the selector is focused
|
||||
no_envs_color_focused = "red"
|
||||
no_envs_modifiers_focused = ""
|
||||
|
||||
[username_field]
|
||||
|
||||
# Remember the username for the next time after a successful login attempt.
|
||||
remember = true
|
||||
|
||||
[username_field.style]
|
||||
# Enables showing a title
|
||||
show_title = true
|
||||
# The text used within the title
|
||||
title = "Login"
|
||||
|
||||
# The title's color and modifiers whilst the username field is unfocused
|
||||
title_color = "white"
|
||||
content_color = "white"
|
||||
|
||||
# The title's color and modifiers whilst the username field is focused
|
||||
title_color_focused = "blue"
|
||||
content_color_focused = "blue"
|
||||
|
||||
# Enables showing the borders
|
||||
show_border = true
|
||||
# The borders' color and modifiers whilst the username field is unfocused
|
||||
border_color = "white"
|
||||
# The borders' color and modifiers whilst the username field is focused
|
||||
border_color_focused = "light blue"
|
||||
|
||||
# Constrain the width of the username field
|
||||
use_max_width = true
|
||||
# The contraint of the username field's width
|
||||
max_width = 48
|
||||
|
||||
[password_field]
|
||||
|
||||
# The character used for replacement when typing a password. Leave empty for no
|
||||
# feedback.
|
||||
# Note: Only one character is accepted.
|
||||
content_replacement_character = "▮"
|
||||
|
||||
[password_field.style]
|
||||
# Enables showing a title
|
||||
show_title = true
|
||||
# The text used within the title
|
||||
title = "Password"
|
||||
|
||||
# The title's color and modifiers whilst the password field is unfocused
|
||||
title_color = "white"
|
||||
content_color = "white"
|
||||
|
||||
# The title's color and modifiers whilst the password field is focused
|
||||
title_color_focused = "blue"
|
||||
content_color_focused = "blue"
|
||||
|
||||
# Enables showing the borders
|
||||
show_border = true
|
||||
# The borders' color and modifiers whilst the username field is unfocused
|
||||
border_color = "white"
|
||||
# The borders' color and modifiers whilst the username field is focused
|
||||
border_color_focused = "blue"
|
||||
|
||||
# Constrain the width of the password field
|
||||
use_max_width = true
|
||||
# The contraint of the password field's width
|
||||
max_width = 48
|
||||
106
machines/universedesktop/desktop/niri.nix
Normal file
106
machines/universedesktop/desktop/niri.nix
Normal file
@@ -0,0 +1,106 @@
|
||||
{ config, pkgs, lib, ... }: let
|
||||
launch_emacs = pkgs.writeScript "emacsclient-or-start" ''
|
||||
#!${pkgs.bash}/bin/bash
|
||||
emacsclient --create-frame --alternate-editor=""
|
||||
'';
|
||||
in {
|
||||
imports = [
|
||||
./wayland.nix
|
||||
];
|
||||
|
||||
services.displayManager.sessionPackages = [ pkgs.dwl ];
|
||||
#services.gnome.gnome-keyring.enable = lib.mkDefault true;
|
||||
systemd.packages = [ pkgs.dwl ];
|
||||
|
||||
nixpkgs.overlays = [
|
||||
(final: prev: {
|
||||
wlroots_0_19 = prev.wlroots_0_18.overrideAttrs (old: {
|
||||
src = final.fetchFromGitLab {
|
||||
domain = "gitlab.freedesktop.org";
|
||||
owner = "wlroots";
|
||||
repo = "wlroots";
|
||||
rev = "d305934ebe6852785a1f425ee96861f0b7280d76"; # 0.19-prev # 25-01-25
|
||||
hash = "sha256-NnPSC5p/phTFe+nWp9vl8LUbmBO/RXSSUuDZ2boucXY=";
|
||||
};
|
||||
});
|
||||
dwl = (prev.dwl.override { wlroots = final.wlroots_0_19; }).overrideAttrs (old: let
|
||||
dwl-patches = pkgs.fetchgit {
|
||||
url = "https://codeberg.org/dwl/dwl-patches.git";
|
||||
rev = "4a869141fa643d9be792a9aa44a42cf7f7f882ad";
|
||||
hash = "sha256-xlaK9xMrc+KDNecsyByRIxXmPEZ2dmP4FQ0bMojsyws=";
|
||||
};
|
||||
patches = let
|
||||
dwl-patch = p: "${dwl-patches}/patches/${p}/${p}.patch";
|
||||
in [
|
||||
(dwl-patch "ipc")
|
||||
(dwl-patch "restore-monitor")
|
||||
(dwl-patch "regexrules")
|
||||
(dwl-patch "autostart")
|
||||
];
|
||||
in {
|
||||
version = "21-09-2024";
|
||||
|
||||
src = final.fetchFromGitea {
|
||||
domain = "codeberg.org";
|
||||
owner = "dwl";
|
||||
repo = "dwl";
|
||||
rev = "d1c2f434983562bd7d2ace15ab0c05155be603bc";
|
||||
hash = "sha256-SpfjQfzvbpDiihziyKGPoBwvp3evgCQQhhjldAE/MwY=";
|
||||
};
|
||||
|
||||
patches = (old.patches or []) ++ patches;
|
||||
postPatch = (old.postPatch or "") + ''
|
||||
export termcmd=${pkgs.foot}/bin/foot
|
||||
export editcmd=${launch_emacs}
|
||||
export menucmd=${pkgs.fuzzel}/bin/fuzzel
|
||||
export barcmd=${pkgs.waybar}/bin/waybar
|
||||
export playcmd=${pkgs.writeScript "playerctl-play-pause" ''
|
||||
#!${pkgs.bash}/bin/bash
|
||||
${pkgs.playerctl}/bin/playerctl play-pause
|
||||
''}
|
||||
export scrncmd=${pkgs.writeScript "screenshot-region" ''
|
||||
#!${pkgs.bash}/bin/bash
|
||||
${pkgs.slurp}/bin/slurp | ${pkgs.grim}/bin/grim -g - - | ${pkgs.wl-clipboard}/bin/wl-copy
|
||||
''}
|
||||
substituteAll ${./dwl/config.def.h} ./config.def.h
|
||||
'';
|
||||
postInstall = ''
|
||||
chmod ugo+x $out/share/wayland-sessions/dwl.desktop
|
||||
'';
|
||||
passthru.providedSessions = ["dwl"];
|
||||
});
|
||||
})
|
||||
];
|
||||
|
||||
|
||||
security = {
|
||||
polkit.enable = true;
|
||||
pam.services.swaylock = { };
|
||||
};
|
||||
|
||||
services.graphical-desktop.enable = true;
|
||||
|
||||
services.xserver.desktopManager.runXdgAutostartIfNone = lib.mkDefault true;
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
dwl
|
||||
waybar
|
||||
foot
|
||||
pwvucontrol
|
||||
];
|
||||
}
|
||||
{ config, pkgs, lib, ... }: {
|
||||
programs.niri.enable = true;
|
||||
|
||||
environment.sessionVariables = {
|
||||
# Breaks WebCord
|
||||
# NIXOS_OZONE_WL=1;
|
||||
WLR_NO_HARDWARE_CURSORS=1;
|
||||
SDL_VIDEODRIVER="wayland";
|
||||
QT_QPA_PLATFORM="wayland-egl";
|
||||
QT_WAYLAND_DISABLE_WINDOW_DECORATIONS="1";
|
||||
__JAVA_AWT_WM_NONREPARENTING=1;
|
||||
GTK_THEME="Adwaita-dark";
|
||||
};
|
||||
|
||||
}
|
||||
@@ -0,0 +1,16 @@
|
||||
diff --git a/UI/window-projector.cpp b/UI/window-projector.cpp
|
||||
index e61f23182..a405e9f17 100644
|
||||
--- a/UI/window-projector.cpp
|
||||
+++ b/UI/window-projector.cpp
|
||||
@@ -37,11 +37,6 @@ OBSProjector::OBSProjector(QWidget *widget, obs_source_t *source_, int monitor,
|
||||
// can skip it
|
||||
windowHandle()->setProperty("isOBSProjectorWindow", true);
|
||||
|
||||
-#if defined(__linux__) || defined(__FreeBSD__) || defined(__DragonFly__)
|
||||
- // Prevents resizing of projector windows
|
||||
- setAttribute(Qt::WA_PaintOnScreen, false);
|
||||
-#endif
|
||||
-
|
||||
type = type_;
|
||||
#ifdef __APPLE__
|
||||
setWindowIcon(
|
||||
22
machines/universedesktop/desktop/plasma.nix
Normal file
22
machines/universedesktop/desktop/plasma.nix
Normal file
@@ -0,0 +1,22 @@
|
||||
{ config, pkgs, lib, ... }: {
|
||||
imports = [
|
||||
./wayland.nix
|
||||
./sddm.nix
|
||||
];
|
||||
#services.xserver.displayManager.lightdm.enable = true;
|
||||
|
||||
# nVidia is broken with 6.12 currently
|
||||
# boot.kernelPackages = pkgs.linuxPackages_6_11;
|
||||
|
||||
services.xserver.enable = true;
|
||||
services.desktopManager.plasma6.enable = true;
|
||||
|
||||
environment.plasma6.excludePackages = with pkgs.kdePackages; [
|
||||
];
|
||||
|
||||
qt = {
|
||||
enable = true;
|
||||
platformTheme = "gnome";
|
||||
style = "adwaita-dark";
|
||||
};
|
||||
}
|
||||
5
machines/universedesktop/desktop/sddm.nix
Normal file
5
machines/universedesktop/desktop/sddm.nix
Normal file
@@ -0,0 +1,5 @@
|
||||
{ config, pkgs, lib, ... }: {
|
||||
services.xserver.enable = true;
|
||||
services.displayManager.sddm.enable = true;
|
||||
services.displayManager.sddm.wayland.enable = true;
|
||||
}
|
||||
34
machines/universedesktop/desktop/wayland.nix
Normal file
34
machines/universedesktop/desktop/wayland.nix
Normal file
@@ -0,0 +1,34 @@
|
||||
{ config, pkgs, lib, ... }: {
|
||||
nixpkgs.overlays = [
|
||||
(final: prev: let
|
||||
patches-src = pkgs.fetchFromGitHub {
|
||||
owner = "BoyOrigin";
|
||||
repo = "glfw-wayland";
|
||||
rev = "2024-03-07";
|
||||
hash = "sha256-kvWP34rOD4HSTvnKb33nvVquTGZoqP8/l+8XQ0h3b7Y=";
|
||||
};
|
||||
patch' = p: "${patches-src}/patches/${p}.patch";
|
||||
in {
|
||||
glfw3-minecraft = prev.glfw3-minecraft.overrideAttrs (old: {
|
||||
patches = [ (builtins.head old.patches) ] ++ [
|
||||
(patch' "0001-Key-Modifiers-Fix")
|
||||
(patch' "0002-Fix-duplicate-pointer-scroll-events")
|
||||
(patch' "0003-Implement-glfwSetCursorPosWayland")
|
||||
(patch' "0004-Fix-Window-size-on-unset-fullscreen")
|
||||
(patch' "0005-Avoid-error-on-startup")
|
||||
./0006-DontCrashWindowPos.patch
|
||||
];
|
||||
});
|
||||
|
||||
obs-studio = prev.obs-studio.overrideAttrs (old: {
|
||||
patches = (old.patches or []) ++ [
|
||||
./obs-wayland-window-projection.patch
|
||||
];
|
||||
});
|
||||
})
|
||||
];
|
||||
programs.xwayland.enable = true;
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
];
|
||||
}
|
||||
6
machines/universedesktop/fonts.nix
Normal file
6
machines/universedesktop/fonts.nix
Normal file
@@ -0,0 +1,6 @@
|
||||
{ config, pkgs, lib, ... }: {
|
||||
fonts.packages = with pkgs; [
|
||||
julia-mono
|
||||
bqn386
|
||||
];
|
||||
}
|
||||
@@ -1,126 +1,94 @@
|
||||
{ lib, config, pkgs, ... }: let
|
||||
py3 = pkgs.python3;
|
||||
py3Pkgs = py3.pkgs;
|
||||
# For 3D CNC machining
|
||||
opencamlib = py3Pkgs.toPythonModule (pkgs.stdenv.mkDerivation rec {
|
||||
pname = "opencamlib";
|
||||
version = "2019.07";
|
||||
nativeBuildInputs = (with pkgs;[
|
||||
cmake
|
||||
git
|
||||
doxygen
|
||||
boost
|
||||
texlive.combined.scheme-full
|
||||
]);
|
||||
propagatedNativeBuildInputs = (with pkgs; [
|
||||
py3
|
||||
py3.pkgs.boost
|
||||
py3.pkgs.vtk
|
||||
]);
|
||||
postPatch = ''
|
||||
mkdir -p $out/${py3.sitePackages}/{lib,ocl}
|
||||
sed -e 's#LIBRARY DESTINATION ''${PYTHON_ARCH_PACKAGES}#LIBRARY DESTINATION '"$out"'/${py3.sitePackages}#g' -i src/pythonlib/pythonlib.cmake
|
||||
sed -e 's#DESTINATION ''${PYTHON_SITE_PACKAGES}#DESTINATION '"$out"'/${py3.sitePackages}#g' -i src/pythonlib/pythonlib.cmake
|
||||
'';
|
||||
cmakeFlags = [
|
||||
"-DVERSION_STRING=2019.07"
|
||||
"-DBUILD_CXX_LIB=ON"
|
||||
"-DBUILD_PY_LIB=ON"
|
||||
"-DUSE_PY_3=ON"
|
||||
"-DCMAKE_BUILD_TYPE=Release"
|
||||
{ lib, config, pkgs, ... }: {
|
||||
nixpkgs.overlays = [(final: prev: rec {
|
||||
pythonPackagesExtensions = prev.pythonPackagesExtensions ++ [
|
||||
(
|
||||
python-final: python-prev: let
|
||||
py = python-prev;
|
||||
in {
|
||||
equation = py.buildPythonPackage {
|
||||
pyproject = true;
|
||||
build-system = [ py.setuptools ];
|
||||
pname = "Equation";
|
||||
version = "1.2.01";
|
||||
nativeBuildInputs = [
|
||||
py.setuptools
|
||||
py.numpy
|
||||
];
|
||||
src = pkgs.fetchzip {
|
||||
url = "https://files.pythonhosted.org/packages/2e/cc/115fb1722051f99b9699864586e7f96ca0080645387698af922fade4f7b2/Equation-1.2.01.zip";
|
||||
sha256 = "YFxZB3vaC5s49K1AQLFF4WGUr2RpomJTLQdZ24ITXr4=";
|
||||
};
|
||||
};
|
||||
morphio = py.toPythonModule ( pkgs.stdenv.mkDerivation rec {
|
||||
pyproject = true;
|
||||
build-system = [ py.setuptools ];
|
||||
pname = "MorphIO";
|
||||
version = "3.3.4";
|
||||
nativeBuildInputs = (with pkgs; [
|
||||
cmake
|
||||
ninja
|
||||
py.numpy
|
||||
hdf5
|
||||
]);
|
||||
cmakeFlags = [
|
||||
"-DMorphIO_CXX_WARNINGS=OFF"
|
||||
];
|
||||
postInstall = ''
|
||||
mkdir -p $out/${py.python.sitePackages}
|
||||
mv ../morphio $out/${py.python.sitePackages}
|
||||
cp binds/python/_morphio.* $out/${py.python.sitePackages}/morphio/
|
||||
'';
|
||||
src = pkgs.fetchFromGitHub {
|
||||
owner = "BlueBrain";
|
||||
repo = "MorphIO";
|
||||
rev = "v${version}";
|
||||
deepClone = true;
|
||||
fetchSubmodules = true;
|
||||
sha256 = "C3zDziG7LF7v22ZvplBrtOYq7iKGnAavfpiBCcShHaQ=";
|
||||
};
|
||||
});
|
||||
|
||||
}
|
||||
)
|
||||
];
|
||||
src = pkgs.fetchFromGitHub {
|
||||
owner = "aewallin";
|
||||
repo = "opencamlib";
|
||||
rev = "2019.07";
|
||||
sha256 = "1a8pxp1mh8x3bfsb0l97vgxrpk482p7q9jprkd4m9hv69vva2bdz";
|
||||
};
|
||||
});
|
||||
equation = py3Pkgs.buildPythonPackage {
|
||||
pname = "Equation";
|
||||
version = "1.2.01";
|
||||
nativeBuildInputs = [
|
||||
py3Pkgs.setuptools
|
||||
py3Pkgs.numpy
|
||||
];
|
||||
src = pkgs.fetchzip {
|
||||
url = "https://files.pythonhosted.org/packages/2e/cc/115fb1722051f99b9699864586e7f96ca0080645387698af922fade4f7b2/Equation-1.2.01.zip";
|
||||
sha256 = "YFxZB3vaC5s49K1AQLFF4WGUr2RpomJTLQdZ24ITXr4=";
|
||||
};
|
||||
};
|
||||
morphio = py3.pkgs.toPythonModule ( pkgs.stdenv.mkDerivation rec {
|
||||
pname = "MorphIO";
|
||||
version = "3.3.4";
|
||||
nativeBuildInputs = (with pkgs; [
|
||||
cmake
|
||||
ninja
|
||||
py3
|
||||
py3.pkgs.numpy
|
||||
hdf5
|
||||
]);
|
||||
cmakeFlags = [
|
||||
"-DMorphIO_CXX_WARNINGS=OFF"
|
||||
];
|
||||
postInstall = ''
|
||||
mkdir -p $out/${py3.sitePackages}
|
||||
mv ../morphio $out/${py3.sitePackages}
|
||||
cp binds/python/_morphio.* $out/${py3.sitePackages}/morphio/
|
||||
'';
|
||||
src = pkgs.fetchFromGitHub {
|
||||
owner = "BlueBrain";
|
||||
repo = "MorphIO";
|
||||
rev = "v${version}";
|
||||
deepClone = true;
|
||||
fetchSubmodules = true;
|
||||
sha256 = "C3zDziG7LF7v22ZvplBrtOYq7iKGnAavfpiBCcShHaQ=";
|
||||
};
|
||||
});
|
||||
in {
|
||||
nixpkgs.overlays = [(self: super: rec {
|
||||
# Add CUDA Support to Blender
|
||||
blender_cuda = super.blender.override {
|
||||
stdenv = super.ccacheStdenv;
|
||||
blender_cuda = prev.blender.override {
|
||||
cudaSupport = true;
|
||||
};
|
||||
# Add Opencamlib for BlenderCAM Support
|
||||
blender = blender_cuda.overrideAttrs (old: {
|
||||
pythonPath = old.pythonPath ++ (with py3Pkgs; [
|
||||
# OpenCAMLib support
|
||||
shapely
|
||||
equation
|
||||
opencamlib
|
||||
# NeuroMorphoVis support
|
||||
matplotlib
|
||||
seaborn
|
||||
pandas
|
||||
pillow
|
||||
h5py
|
||||
morphio
|
||||
# TODO add BluePy support?
|
||||
]);
|
||||
});
|
||||
# blender = final.blender_cuda.withPackages (p: with p; [
|
||||
# # OpenCAMLib support
|
||||
# shapely
|
||||
# equation
|
||||
# opencamlib
|
||||
# # NeuroMorphoVis support
|
||||
# matplotlib
|
||||
# seaborn
|
||||
# pandas
|
||||
# pillow
|
||||
# h5py
|
||||
# morphio
|
||||
# # TODO add BluePy support?
|
||||
# ]);
|
||||
# Update RX and Aseprite
|
||||
rx = super.rx.overrideAttrs (old: {
|
||||
rx = prev.rx.overrideAttrs (old: {
|
||||
version = "git";
|
||||
src = super.fetchFromGitHub {
|
||||
src = prev.fetchFromGitHub {
|
||||
owner = "cloudhead";
|
||||
repo = old.pname;
|
||||
rev = "18625a68921873ebe21a7ea8096409a9f0314541";
|
||||
sha256 = "sha256-LTpaV/fgYUgA2M6Wz5qLHnTNywh13900g+umhgLvciM=";
|
||||
};
|
||||
});
|
||||
glaxnimate = super.glaxnimate.override {
|
||||
python3 = self.python310;
|
||||
};
|
||||
})];
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
blender
|
||||
# GTK theme support (basic) for GTK apps e.g. inkscape
|
||||
gnome.adwaita-icon-theme
|
||||
adwaita-icon-theme
|
||||
|
||||
rx
|
||||
aseprite-unfree
|
||||
pixelorama
|
||||
gimp
|
||||
|
||||
glaxnimate
|
||||
|
||||
@@ -3,7 +3,9 @@
|
||||
easyeffects
|
||||
helvum
|
||||
|
||||
musescore
|
||||
# https://nixpk.gs/pr-tracker.html?pr=290037
|
||||
# Waiting for this ^
|
||||
# musescore
|
||||
audacity
|
||||
|
||||
tidal-hifi
|
||||
|
||||
@@ -1,76 +1,7 @@
|
||||
{ lib, config, pkgs, ... }: let
|
||||
# FreeCAD uses pyside2 (qt 5.15) which doesn't support > 3.10
|
||||
py3 = pkgs.python310;
|
||||
py3Pkgs = py3.pkgs;
|
||||
# For 3D CNC machining
|
||||
opencamlib = py3Pkgs.toPythonModule (pkgs.stdenv.mkDerivation rec {
|
||||
pname = "opencamlib";
|
||||
version = "2019.07";
|
||||
nativeBuildInputs = (with pkgs;[
|
||||
cmake
|
||||
git
|
||||
doxygen
|
||||
boost
|
||||
texlive.combined.scheme-full
|
||||
]);
|
||||
propagatedNativeBuildInputs = (with pkgs; [
|
||||
py3
|
||||
py3.pkgs.boost
|
||||
py3.pkgs.vtk
|
||||
]);
|
||||
postPatch = ''
|
||||
mkdir -p $out/${py3.sitePackages}/{lib,ocl}
|
||||
sed -e 's#LIBRARY DESTINATION ''${PYTHON_ARCH_PACKAGES}#LIBRARY DESTINATION '"$out"'/${py3.sitePackages}#g' -i src/pythonlib/pythonlib.cmake
|
||||
sed -e 's#DESTINATION ''${PYTHON_SITE_PACKAGES}#DESTINATION '"$out"'/${py3.sitePackages}#g' -i src/pythonlib/pythonlib.cmake
|
||||
'';
|
||||
cmakeFlags = [
|
||||
"-DVERSION_STRING=2019.07"
|
||||
"-DBUILD_CXX_LIB=ON"
|
||||
"-DBUILD_PY_LIB=ON"
|
||||
"-DUSE_PY_3=ON"
|
||||
"-DCMAKE_BUILD_TYPE=Release"
|
||||
];
|
||||
src = pkgs.fetchFromGitHub {
|
||||
owner = "aewallin";
|
||||
repo = "opencamlib";
|
||||
rev = "2019.07";
|
||||
sha256 = "1a8pxp1mh8x3bfsb0l97vgxrpk482p7q9jprkd4m9hv69vva2bdz";
|
||||
};
|
||||
});
|
||||
|
||||
py3Cad = py3.withPackages (p: (with p; [
|
||||
numpy
|
||||
scipy
|
||||
seaborn
|
||||
pandas
|
||||
matplotlib
|
||||
ipython
|
||||
python-lsp-server
|
||||
opencamlib
|
||||
]));
|
||||
in {
|
||||
# if you also want support for flakes
|
||||
nixpkgs.overlays = [(self: super: rec {
|
||||
freecad = super.freecad.override {
|
||||
stdenv = super.ccacheStdenv;
|
||||
python = py3Cad;
|
||||
boost = py3Pkgs.boost;
|
||||
inherit (py3Pkgs)
|
||||
gitpython
|
||||
matplotlib
|
||||
pivy
|
||||
ply
|
||||
pycollada
|
||||
pyside2
|
||||
pyside2-tools
|
||||
pyyaml
|
||||
scipy
|
||||
shiboken2;
|
||||
};
|
||||
})];
|
||||
|
||||
{ lib, config, pkgs, ... }: {
|
||||
environment.systemPackages = with pkgs; [
|
||||
openscad
|
||||
|
||||
freecad
|
||||
kicad
|
||||
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
{ lib, config, pkgs, nixpkgs, ... }: {
|
||||
{ lib, config, pkgs, ... }: {
|
||||
nixpkgs.overlays = [(self: super: rec {
|
||||
# Discord fix
|
||||
discord = super.discord.override {
|
||||
@@ -24,10 +24,18 @@
|
||||
nextcloud-client
|
||||
libsForQt5.kdeconnect-kde
|
||||
|
||||
discord-canary
|
||||
discord
|
||||
betterdiscordctl
|
||||
slack
|
||||
signal-desktop
|
||||
zoom-us
|
||||
|
||||
anki
|
||||
(pkgs.wrapOBS {
|
||||
plugins = with pkgs.obs-studio-plugins; [
|
||||
wlrobs
|
||||
obs-backgroundremoval
|
||||
obs-vkcapture
|
||||
input-overlay
|
||||
obs-pipewire-audio-capture
|
||||
];
|
||||
})
|
||||
];
|
||||
}
|
||||
|
||||
@@ -1,53 +1,12 @@
|
||||
{ lib, config, pkgs, ... }: let
|
||||
wiiUDownloader = pkgs.stdenv.mkDerivation rec {
|
||||
pname = "WiiUDownloader";
|
||||
version = "1.32";
|
||||
src = pkgs.fetchFromGitHub {
|
||||
owner = "Xpl0itU";
|
||||
repo = "WiiUDownloader";
|
||||
rev = "v${version}";
|
||||
fetchSubmodules = true;
|
||||
hash = "sha256-R3FiNiK27Q2x5HbHmWw3F4LPJNKz5BAoOyl4fYAEQlc=";
|
||||
};
|
||||
preConfigure = ''
|
||||
cp ${./gtitles.c} src/gtitles.c
|
||||
'';
|
||||
nativeBuildInputs = with pkgs; [
|
||||
cmake
|
||||
pkg-config
|
||||
wrapGAppsHook
|
||||
];
|
||||
buildInputs = with pkgs; [
|
||||
curl
|
||||
mbedtls
|
||||
gtkmm3
|
||||
pcre2
|
||||
pcre-cpp
|
||||
util-linux
|
||||
libselinux
|
||||
libsepol
|
||||
libthai
|
||||
libdatrie
|
||||
xorg.libXdmcp
|
||||
libxkbcommon
|
||||
libepoxy
|
||||
xorg.libXtst
|
||||
];
|
||||
|
||||
propagatedBuildInputs = with pkgs; [
|
||||
gsettings-desktop-schemas
|
||||
];
|
||||
|
||||
installPhase = ''
|
||||
runHook preInstall
|
||||
mkdir -p $out/bin
|
||||
mv * $out/bin
|
||||
runHook postInstall
|
||||
'';
|
||||
};
|
||||
in {
|
||||
# For steam
|
||||
services.flatpak.enable = true;
|
||||
{ lib, config, pkgs, ... }: {
|
||||
# # For steam
|
||||
# services.flatpak.enable = true;
|
||||
# ## Flatpak requires this
|
||||
xdg.portal.enable = true;
|
||||
xdg.portal.wlr.enable = true;
|
||||
xdg.portal.config.common.default = "*";
|
||||
# On X11: Steam requires a compositor for BigPicture
|
||||
programs.steam.enable = true;
|
||||
# Game compat
|
||||
programs.gamemode.enable = true;
|
||||
|
||||
@@ -61,11 +20,5 @@ in {
|
||||
|
||||
# PS2 Games
|
||||
pcsx2
|
||||
|
||||
# Switch / WiiU Games
|
||||
cemu
|
||||
wiiUDownloader
|
||||
yuzu-early-access
|
||||
ukmm
|
||||
];
|
||||
}
|
||||
|
||||
File diff suppressed because one or more lines are too long
@@ -1,8 +1,6 @@
|
||||
{ lib, config, pkgs, ... }: {
|
||||
environment.systemPackages = with pkgs; [
|
||||
kitty
|
||||
me-emacs
|
||||
rnix-lsp
|
||||
emacs
|
||||
texlive.combined.scheme-full
|
||||
pandoc
|
||||
libreoffice-qt
|
||||
|
||||
@@ -1,15 +1,21 @@
|
||||
{ lib, config, pkgs, ... }: {
|
||||
{ lib, config, pkgs, ... }: let
|
||||
mypython = let
|
||||
packageOverrides = final: prev: {
|
||||
matplotlib = prev.matplotlib.override {enableGtk3 = true;};
|
||||
};
|
||||
in pkgs.python3.override {inherit packageOverrides;};
|
||||
in {
|
||||
virtualisation = {
|
||||
podman = {
|
||||
enable = true;
|
||||
};
|
||||
};
|
||||
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
godot_4
|
||||
cbqn-replxx
|
||||
|
||||
(pkgs.python3.withPackages (p: (with p; [
|
||||
(mypython.withPackages (p: (with p; [
|
||||
scipy
|
||||
numpy
|
||||
pandas
|
||||
@@ -18,7 +24,7 @@
|
||||
beautifulsoup4
|
||||
tqdm
|
||||
matplotlib
|
||||
pyqt5
|
||||
colour
|
||||
|
||||
ipython
|
||||
python-lsp-server
|
||||
|
||||
@@ -9,7 +9,8 @@
|
||||
htop
|
||||
btop
|
||||
xclip
|
||||
screen
|
||||
tio
|
||||
tmux
|
||||
usbutils
|
||||
man-pages
|
||||
man-pages-posix
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
{ lib, config, pkgs, ... }: {
|
||||
environment.systemPackages = with pkgs; [
|
||||
vlc
|
||||
ffmpeg_5-full
|
||||
ffmpeg-full
|
||||
];
|
||||
}
|
||||
|
||||
6
machines/universedesktop/riscv.nix
Normal file
6
machines/universedesktop/riscv.nix
Normal file
@@ -0,0 +1,6 @@
|
||||
{ config, pkgs, lib, ... }: {
|
||||
boot.binfmt.emulatedSystems = [
|
||||
"riscv64-linux"
|
||||
];
|
||||
boot.binfmt.preferStaticEmulators = true;
|
||||
}
|
||||
@@ -1,4 +1,4 @@
|
||||
wireless: ENC[AES256_GCM,data:VS8XBhc2DfqDdOeUvwnMYy8R1x/Qbr7lSuCb3l+X1xFdK7gni5aGm71pZk4=,iv:3I/GMA6KbYyD4fOkdLrW99JoIbUPA111fpZ4mlpgA8c=,tag:fAZyTM4AhNX3SENKpJxnsw==,type:str]
|
||||
wireless: ENC[AES256_GCM,data:YR4idzvkgU7RRVeCqabyPWY42FgSqIxl8RX+y947crvLOHyk3CI=,iv:yorheNy2HE9YjWJWDN4AbxJw8lsKYKjdUw79tSy1mR0=,tag:1ofvUhNOLqxfQhNQPkN68Q==,type:str]
|
||||
sops:
|
||||
kms: []
|
||||
gcp_kms: []
|
||||
@@ -14,8 +14,8 @@ sops:
|
||||
WS93Uzg1UkFSSGM1eUR1UG9WRFVCYVEKbnE6DuVqtkynqphNIybtVgfVFJtgm6vI
|
||||
XywmFg8F1dOq1xDz97oFBbzbJa1J9qsMjNlPxZkC04snM9msZm9v2g==
|
||||
-----END AGE ENCRYPTED FILE-----
|
||||
lastmodified: "2024-01-02T02:01:25Z"
|
||||
mac: ENC[AES256_GCM,data:oZCQ9G7C7cqmuK/oXK0zo/siUvKMlKNArP39w9imAwWRSeLy1Vazu/oFH2F1Kzmq7B5iukBXID7T4kGB8vgLINa0T9qKP8s5GfxbcKadY3e6BqcMjXUXy5+UayQ+S/KxDFr4ftoJ4khwmVR8sW8Gpfo4y3VJgDBQTcrRNf8TAq0=,iv:jRMxlw+FDigIN1ZOLXQotqI+hRM6Fgi/DXWjPKKW5TQ=,tag:y7kl2Cjan+w3MqIwLW5dGA==,type:str]
|
||||
lastmodified: "2024-10-15T23:18:01Z"
|
||||
mac: ENC[AES256_GCM,data:cpnUpYOTqPYHjtsbyFxuLH+1oPKAOJeKsR6B6WWux2/yX/+aXfXVDh2MW7EVCKgnnsuj6D6xhPbFU/Fawp+5G7aXIIR8yeGM4QHxJ6qmApWDWmD5SAf/R4E+EvFfID1FVEmZC+IGN7A+1y1GmO31yI6GqRCwFcmdo0ivg1DKo6s=,iv:0Dilkkit3ZDLLYABaJtXPEZVpfxDeoB7obTahMmZGA0=,tag:EHIHM7fj3QS6hGjpCLxrkg==,type:str]
|
||||
pgp: []
|
||||
unencrypted_suffix: _unencrypted
|
||||
version: 3.8.1
|
||||
version: 3.9.1
|
||||
|
||||
4
modules/default.nix
Normal file
4
modules/default.nix
Normal file
@@ -0,0 +1,4 @@
|
||||
inputs: {
|
||||
sops = inputs.sops-nix.nixosModules.sops;
|
||||
home-manager-darwin = inputs.home-manager.darwinModules.home-manager;
|
||||
}
|
||||
5
overlays/default.nix
Normal file
5
overlays/default.nix
Normal file
@@ -0,0 +1,5 @@
|
||||
inputs: {
|
||||
hydra = import ./hydra.nix;
|
||||
nvidiaContainer = import ./nvidiacontainer.nix inputs.nixpkgs;
|
||||
emacs = inputs.me-emacs.overlays.default;
|
||||
}
|
||||
13
overlays/hydra.nix
Normal file
13
overlays/hydra.nix
Normal file
@@ -0,0 +1,13 @@
|
||||
(final: prev: {
|
||||
hydra_unstable = prev.hydra_unstable.overrideAttrs
|
||||
(old: {
|
||||
doCheck = false;
|
||||
patches = [
|
||||
(final.fetchpatch {
|
||||
name = "hydra-gitea-push-patch";
|
||||
url = "https://patch-diff.githubusercontent.com/raw/NixOS/hydra/pull/1227.patch";
|
||||
sha256 = "A4dN/4zLMKLYaD38lu87lzAWH/3EUM7G5njx7Q4W47w=";
|
||||
})
|
||||
];
|
||||
});
|
||||
})
|
||||
Reference in New Issue
Block a user