Compare commits
2 commits
main
...
main-nix-l
Author | SHA1 | Date | |
---|---|---|---|
564944cbdf | |||
935f13beea |
66 changed files with 474 additions and 1794 deletions
1
.envrc
1
.envrc
|
@ -1 +0,0 @@
|
|||
use flake
|
3
.gitignore
vendored
3
.gitignore
vendored
|
@ -1,5 +1,4 @@
|
|||
result
|
||||
*.swp
|
||||
*.qcow2
|
||||
.idea/
|
||||
.direnv
|
||||
.idea/
|
61
README.md
61
README.md
|
@ -10,6 +10,31 @@ nixos-rebuild switch --flake flake_path_directory#hostname
|
|||
nix flake update --extra-experimental-features "nix-command flakes"
|
||||
```
|
||||
|
||||
## Configure VM
|
||||
|
||||
Configure VM
|
||||
```nix
|
||||
users.users.<user>.initialPassword = "<password>";
|
||||
virtualisation.vmVariant = {
|
||||
# following configuration is added only when building VM with build-vm
|
||||
virtualisation = {
|
||||
memorySize = <RAM in MiB>; # Use 8192MiB memory.
|
||||
cores = <CPU Core number>;
|
||||
# And more here https://github.com/NixOS/nixpkgs/blob/nixos-unstable/nixos/modules/virtualisation/qemu-vm.nix
|
||||
};
|
||||
};
|
||||
```
|
||||
|
||||
Build
|
||||
```bash
|
||||
nixos-rebuild build-vm --flake .#nixos-test
|
||||
```
|
||||
|
||||
Run
|
||||
```bash
|
||||
./result/bin/run-nixos-vm-vm
|
||||
```
|
||||
|
||||
## Show changements between revisions
|
||||
|
||||
|
||||
|
@ -47,6 +72,36 @@ error: cached failure of attribute 'nixosConfigurations.perso-desktop.config.sys
|
|||
sudo rm -fr /root/.cache/nix/
|
||||
```
|
||||
|
||||
## If package is marked as insecure
|
||||
|
||||
Example:
|
||||
|
||||
> error: Package 'nix-2.16.2' in /nix/store/nra828scc8qs92b9pxra5csqzffb6hpl-source/pkgs/tools/package-management/nix/default.nix:229 is marked as insecure, refusing to evaluate.
|
||||
>
|
||||
> Known issues:
|
||||
> - CVE-2024-27297
|
||||
|
||||
```bash
|
||||
nix path-info -r /run/current-system | grep nix-2.16.2
|
||||
```
|
||||
Result:
|
||||
> [...]
|
||||
>
|
||||
> /nix/store/g4ss2h40n3j37bq20x1qw5s7nl82lch5-nix-2.16.2
|
||||
>
|
||||
> [...]
|
||||
|
||||
```bash
|
||||
nix-store -q --referrers /nix/store/g4ss2h40n3j37bq20x1qw5s7nl82lch5-nix-2.16.2
|
||||
```
|
||||
Result:
|
||||
> /nix/store/g4ss2h40n3j37bq20x1qw5s7nl82lch5-nix-2.16.2
|
||||
>
|
||||
> /nix/store/72pfc05339izcwqhlbs8441brrdasas7-nix-2.16.2-dev
|
||||
>
|
||||
> /nix/store/ln2z5d5izn8icm3wx94ci13ad19lzjhr-nixd-1.2.3
|
||||
|
||||
nixd is not up to date and require nix 2.16.2
|
||||
|
||||
## To limit resources use during build
|
||||
|
||||
|
@ -54,12 +109,6 @@ sudo rm -fr /root/.cache/nix/
|
|||
nixos-rebuild build-vm --cores 16 --max-jobs 1 --flake .#nixos-test
|
||||
```
|
||||
|
||||
Or without NixOS
|
||||
|
||||
```
|
||||
nix build .#nixosConfigurations.nixos-test.config.system.build.vm
|
||||
```
|
||||
|
||||
# Usefull links
|
||||
|
||||
- https://api.github.com/rate_limit
|
||||
|
|
780
flake.lock
780
flake.lock
|
@ -9,16 +9,14 @@
|
|||
"nixpkgs": [
|
||||
"nixpkgs"
|
||||
],
|
||||
"systems": [
|
||||
"systems"
|
||||
]
|
||||
"systems": "systems"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1723293904,
|
||||
"narHash": "sha256-b+uqzj+Wa6xgMS9aNbX4I+sXeb5biPDi39VgvSFqFvU=",
|
||||
"lastModified": 1718371084,
|
||||
"narHash": "sha256-abpBi61mg0g+lFFU0zY4C6oP6fBwPzbHPKBGw676xsA=",
|
||||
"owner": "ryantm",
|
||||
"repo": "agenix",
|
||||
"rev": "f6291c5935fdc4e0bef208cfc0dcab7e3f7a1c41",
|
||||
"rev": "3a56735779db467538fb2e577eda28a9daacaca6",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
@ -27,27 +25,6 @@
|
|||
"type": "github"
|
||||
}
|
||||
},
|
||||
"crane": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
"lanzaboote",
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1717535930,
|
||||
"narHash": "sha256-1hZ/txnbd/RmiBPNUs7i8UQw2N89uAK3UzrGAWdnFfU=",
|
||||
"owner": "ipetkov",
|
||||
"repo": "crane",
|
||||
"rev": "55e7754ec31dac78980c8be45f8a28e80e370946",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "ipetkov",
|
||||
"repo": "crane",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"darwin": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
|
@ -70,303 +47,6 @@
|
|||
"type": "github"
|
||||
}
|
||||
},
|
||||
"doom-emacs": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1662497747,
|
||||
"narHash": "sha256-4n7E1fqda7cn5/F2jTkOnKw1juG6XMS/FI9gqODL3aU=",
|
||||
"owner": "doomemacs",
|
||||
"repo": "doomemacs",
|
||||
"rev": "3853dff5e11655e858d0bfae64b70cb12ef685ac",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "doomemacs",
|
||||
"repo": "doomemacs",
|
||||
"rev": "3853dff5e11655e858d0bfae64b70cb12ef685ac",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"doom-snippets": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1694887483,
|
||||
"narHash": "sha256-KlKhruPSLPSKqUnr5/U65arm16VrY9ORzm+XKNZhpTQ=",
|
||||
"owner": "doomemacs",
|
||||
"repo": "snippets",
|
||||
"rev": "f022984ee1318a4015d5d081b3c3dab5a60dc6ff",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "doomemacs",
|
||||
"repo": "snippets",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"emacs-overlay": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1676366521,
|
||||
"narHash": "sha256-i4UAY8t9Au9SJtsgYppa3NHSVf1YkV6yqnNIQd+Km4g=",
|
||||
"owner": "nix-community",
|
||||
"repo": "emacs-overlay",
|
||||
"rev": "c16be6de78ea878aedd0292aa5d4a1ee0a5da501",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nix-community",
|
||||
"repo": "emacs-overlay",
|
||||
"rev": "c16be6de78ea878aedd0292aa5d4a1ee0a5da501",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"emacs-so-long": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1575031854,
|
||||
"narHash": "sha256-xIa5zO0ZaToDrec1OFjBK6l39AbA4l/CE4LInVu2hi0=",
|
||||
"owner": "hlissner",
|
||||
"repo": "emacs-so-long",
|
||||
"rev": "ed666b0716f60e8988c455804de24b55919e71ca",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "hlissner",
|
||||
"repo": "emacs-so-long",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"evil-escape": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1588439096,
|
||||
"narHash": "sha256-aB2Ge5o/93B18tPf4fN1c+O46CNh/nOqwLJbox4c8Gw=",
|
||||
"owner": "hlissner",
|
||||
"repo": "evil-escape",
|
||||
"rev": "819f1ee1cf3f69a1ae920e6004f2c0baeebbe077",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "hlissner",
|
||||
"repo": "evil-escape",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"evil-markdown": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1626852210,
|
||||
"narHash": "sha256-HBBuZ1VWIn6kwK5CtGIvHM1+9eiNiKPH0GUsyvpUVN8=",
|
||||
"owner": "Somelauw",
|
||||
"repo": "evil-markdown",
|
||||
"rev": "8e6cc68af83914b2fa9fd3a3b8472573dbcef477",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "Somelauw",
|
||||
"repo": "evil-markdown",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"evil-org-mode": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1607203864,
|
||||
"narHash": "sha256-JxwqVYDN6OIJEH15MVI6XOZAPtUWUhJQWHyzcrUvrFg=",
|
||||
"owner": "hlissner",
|
||||
"repo": "evil-org-mode",
|
||||
"rev": "a9706da260c45b98601bcd72b1d2c0a24a017700",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "hlissner",
|
||||
"repo": "evil-org-mode",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"evil-quick-diff": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1575189609,
|
||||
"narHash": "sha256-oGzl1ayW9rIuq0haoiFS7RZsS8NFMdEA7K1BSozgnJU=",
|
||||
"owner": "rgrinberg",
|
||||
"repo": "evil-quick-diff",
|
||||
"rev": "69c883720b30a892c63bc89f49d4f0e8b8028908",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "rgrinberg",
|
||||
"repo": "evil-quick-diff",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"explain-pause-mode": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1595842060,
|
||||
"narHash": "sha256-++znrjiDSx+cy4okFBBXUBkRFdtnE2x+trkmqjB3Njs=",
|
||||
"owner": "lastquestion",
|
||||
"repo": "explain-pause-mode",
|
||||
"rev": "2356c8c3639cbeeb9751744dbe737267849b4b51",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "lastquestion",
|
||||
"repo": "explain-pause-mode",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"flake-compat": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1696426674,
|
||||
"narHash": "sha256-kvjfFW7WAETZlt09AgDn1MrtKzP7t90Vf7vypd3OL1U=",
|
||||
"owner": "edolstra",
|
||||
"repo": "flake-compat",
|
||||
"rev": "0f9255e01c2351cc7d116c072cb317785dd33b33",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "edolstra",
|
||||
"repo": "flake-compat",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"flake-compat_2": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1673956053,
|
||||
"narHash": "sha256-4gtG9iQuiKITOjNQQeQIpoIB6b16fm+504Ch3sNKLd8=",
|
||||
"owner": "edolstra",
|
||||
"repo": "flake-compat",
|
||||
"rev": "35bb57c0c8d8b62bbfd284272c928ceb64ddbde9",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "edolstra",
|
||||
"repo": "flake-compat",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"flake-parts": {
|
||||
"inputs": {
|
||||
"nixpkgs-lib": [
|
||||
"lanzaboote",
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1717285511,
|
||||
"narHash": "sha256-iKzJcpdXih14qYVcZ9QC9XuZYnPc6T8YImb6dX166kw=",
|
||||
"owner": "hercules-ci",
|
||||
"repo": "flake-parts",
|
||||
"rev": "2a55567fcf15b1b1c7ed712a2c6fadaec7412ea8",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "hercules-ci",
|
||||
"repo": "flake-parts",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"flake-parts_2": {
|
||||
"inputs": {
|
||||
"nixpkgs-lib": [
|
||||
"nur",
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1733312601,
|
||||
"narHash": "sha256-4pDvzqnegAfRkPwO3wmwBhVi/Sye1mzps0zHWYnP88c=",
|
||||
"owner": "hercules-ci",
|
||||
"repo": "flake-parts",
|
||||
"rev": "205b12d8b7cd4802fbcb8e8ef6a0f1408781a4f9",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "hercules-ci",
|
||||
"repo": "flake-parts",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"flake-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"
|
||||
}
|
||||
},
|
||||
"flake-utils_2": {
|
||||
"inputs": {
|
||||
"systems": "systems"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1710146030,
|
||||
"narHash": "sha256-SZ5L6eA7HJ/nmkzGG7/ISclqe6oZdOZTNoesiInkXPQ=",
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"rev": "b1d9ab70662946ef0850d488da1c9019f3a9752a",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "numtide",
|
||||
"repo": "flake-utils",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"format-all": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1581716637,
|
||||
"narHash": "sha256-ul7LCe60W8TIvUmUtZtZRo8489TK9iTPDsLHmzxY57M=",
|
||||
"owner": "lassik",
|
||||
"repo": "emacs-format-all-the-code",
|
||||
"rev": "47d862d40a088ca089c92cd393c6dca4628f87d3",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "lassik",
|
||||
"repo": "emacs-format-all-the-code",
|
||||
"rev": "47d862d40a088ca089c92cd393c6dca4628f87d3",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"gitignore": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
"lanzaboote",
|
||||
"pre-commit-hooks-nix",
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1709087332,
|
||||
"narHash": "sha256-HG2cCnktfHsKV0s4XW83gU3F57gaTljL9KNSuG6bnQs=",
|
||||
"owner": "hercules-ci",
|
||||
"repo": "gitignore.nix",
|
||||
"rev": "637db329424fd7e46cf4185293b9cc8c88c95394",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "hercules-ci",
|
||||
"repo": "gitignore.nix",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"home-manager": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
|
@ -374,11 +54,11 @@
|
|||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1736089250,
|
||||
"narHash": "sha256-/LPWMiiJGPHGd7ZYEgmbE2da4zvBW0acmshUjYC3WG4=",
|
||||
"lastModified": 1718243258,
|
||||
"narHash": "sha256-abBpj2VU8p6qlRzTU8o22q68MmOaZ4v8zZ4UlYl5YRU=",
|
||||
"owner": "nix-community",
|
||||
"repo": "home-manager",
|
||||
"rev": "172b91bfb2b7f5c4a8c6ceac29fd53a01ef07196",
|
||||
"rev": "8d5e27b4807d25308dfe369d5a923d87e7dbfda3",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
@ -387,81 +67,6 @@
|
|||
"type": "github"
|
||||
}
|
||||
},
|
||||
"lanzaboote": {
|
||||
"inputs": {
|
||||
"crane": "crane",
|
||||
"flake-compat": "flake-compat",
|
||||
"flake-parts": "flake-parts",
|
||||
"flake-utils": "flake-utils_2",
|
||||
"nixpkgs": [
|
||||
"nixpkgs"
|
||||
],
|
||||
"pre-commit-hooks-nix": "pre-commit-hooks-nix",
|
||||
"rust-overlay": "rust-overlay"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1718178907,
|
||||
"narHash": "sha256-eSZyrQ9uoPB9iPQ8Y5H7gAmAgAvCw3InStmU3oEjqsE=",
|
||||
"owner": "nix-community",
|
||||
"repo": "lanzaboote",
|
||||
"rev": "b627ccd97d0159214cee5c7db1412b75e4be6086",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nix-community",
|
||||
"ref": "v0.4.1",
|
||||
"repo": "lanzaboote",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nix-doom-emacs": {
|
||||
"inputs": {
|
||||
"doom-emacs": "doom-emacs",
|
||||
"doom-snippets": "doom-snippets",
|
||||
"emacs-overlay": "emacs-overlay",
|
||||
"emacs-so-long": "emacs-so-long",
|
||||
"evil-escape": "evil-escape",
|
||||
"evil-markdown": "evil-markdown",
|
||||
"evil-org-mode": "evil-org-mode",
|
||||
"evil-quick-diff": "evil-quick-diff",
|
||||
"explain-pause-mode": "explain-pause-mode",
|
||||
"flake-compat": "flake-compat_2",
|
||||
"flake-utils": [
|
||||
"flake-utils"
|
||||
],
|
||||
"format-all": "format-all",
|
||||
"nix-straight": [
|
||||
"nix-straight"
|
||||
],
|
||||
"nixpkgs": [
|
||||
"nixpkgs"
|
||||
],
|
||||
"nose": "nose",
|
||||
"ob-racket": "ob-racket",
|
||||
"org": "org",
|
||||
"org-contrib": "org-contrib",
|
||||
"org-yt": "org-yt",
|
||||
"php-extras": "php-extras",
|
||||
"revealjs": "revealjs",
|
||||
"rotate-text": "rotate-text",
|
||||
"sln-mode": "sln-mode",
|
||||
"ts-fold": "ts-fold",
|
||||
"ws-butler": "ws-butler"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1701264882,
|
||||
"narHash": "sha256-MBXR7x7Ua8qystlGr+lenwjQd7dsFNFpEFmtHhh10zM=",
|
||||
"owner": "nix-community",
|
||||
"repo": "nix-doom-emacs",
|
||||
"rev": "f7413022370f24bb53cb450bfb2803233510113e",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nix-community",
|
||||
"repo": "nix-doom-emacs",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nix-flatpak": {
|
||||
"locked": {
|
||||
"lastModified": 1711997201,
|
||||
|
@ -478,53 +83,13 @@
|
|||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nix-straight": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1696948727,
|
||||
"narHash": "sha256-6fQamWVIyeLoFSJl1WKcIl+LUdZluzFla4H+4Z5Cv2E=",
|
||||
"owner": "codingkoi",
|
||||
"repo": "nix-straight.el",
|
||||
"rev": "c64edbf49598453bd85dae1acef9a0f9d294185d",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "codingkoi",
|
||||
"ref": "codingkoi/apply-librephoenixs-fix",
|
||||
"repo": "nix-straight.el",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixgl": {
|
||||
"inputs": {
|
||||
"flake-utils": [
|
||||
"flake-utils"
|
||||
],
|
||||
"nixpkgs": [
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1713543440,
|
||||
"narHash": "sha256-lnzZQYG0+EXl/6NkGpyIz+FEOc/DSEG57AP1VsdeNrM=",
|
||||
"owner": "nix-community",
|
||||
"repo": "nixGL",
|
||||
"rev": "310f8e49a149e4c9ea52f1adf70cdc768ec53f8a",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nix-community",
|
||||
"repo": "nixGL",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs": {
|
||||
"locked": {
|
||||
"lastModified": 1736012469,
|
||||
"narHash": "sha256-/qlNWm/IEVVH7GfgAIyP6EsVZI6zjAx1cV5zNyrs+rI=",
|
||||
"lastModified": 1718318537,
|
||||
"narHash": "sha256-4Zu0RYRcAY/VWuu6awwq4opuiD//ahpc2aFHg2CWqFY=",
|
||||
"owner": "nixos",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "8f3e1f807051e32d8c95cd12b9b421623850a34d",
|
||||
"rev": "e9ee548d90ff586a6471b4ae80ae9cfcbceb3420",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
|
@ -534,267 +99,12 @@
|
|||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs-stable": {
|
||||
"locked": {
|
||||
"lastModified": 1710695816,
|
||||
"narHash": "sha256-3Eh7fhEID17pv9ZxrPwCLfqXnYP006RKzSs0JptsN84=",
|
||||
"owner": "NixOS",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "614b4613980a522ba49f0d194531beddbb7220d3",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "NixOS",
|
||||
"ref": "nixos-23.11",
|
||||
"repo": "nixpkgs",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nixpkgs_2": {
|
||||
"locked": {
|
||||
"lastModified": 1736012469,
|
||||
"narHash": "sha256-/qlNWm/IEVVH7GfgAIyP6EsVZI6zjAx1cV5zNyrs+rI=",
|
||||
"owner": "nixos",
|
||||
"repo": "nixpkgs",
|
||||
"rev": "8f3e1f807051e32d8c95cd12b9b421623850a34d",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nixos",
|
||||
"ref": "nixos-unstable",
|
||||
"repo": "nixpkgs",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nose": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1400604510,
|
||||
"narHash": "sha256-daEi8Kta1oGaDEmUUDDQMahTTPOpvNpDKk22rlr7cB0=",
|
||||
"owner": "emacsattic",
|
||||
"repo": "nose",
|
||||
"rev": "f8528297519eba911696c4e68fa88892de9a7b72",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "emacsattic",
|
||||
"repo": "nose",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"nur": {
|
||||
"inputs": {
|
||||
"flake-parts": "flake-parts_2",
|
||||
"nixpkgs": "nixpkgs_2",
|
||||
"treefmt-nix": "treefmt-nix"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1736195583,
|
||||
"narHash": "sha256-o9X/eAJGvUiqs4eP3zp9WQgnuvXaPNxcgy4ww+TrHvw=",
|
||||
"owner": "nix-community",
|
||||
"repo": "NUR",
|
||||
"rev": "ee2a092b4b4a2dd676d28c7228474e530622a79e",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nix-community",
|
||||
"repo": "NUR",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"ob-racket": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1584656173,
|
||||
"narHash": "sha256-rBUYDDCXb+3D4xTPQo9UocbTPZ32kWV1Uya/1DmZknU=",
|
||||
"owner": "xchrishawk",
|
||||
"repo": "ob-racket",
|
||||
"rev": "83457ec9e1e96a29fd2086ed19432b9d75787673",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "xchrishawk",
|
||||
"repo": "ob-racket",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"org": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1695726851,
|
||||
"narHash": "sha256-qgbjspklSoI8M3cbCJOcUdjuijRgsL/+PSyEOW9VX4I=",
|
||||
"owner": "emacs-straight",
|
||||
"repo": "org-mode",
|
||||
"rev": "aa9177e1a8b039c357d369c1c9aaab710bb247a9",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "emacs-straight",
|
||||
"repo": "org-mode",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"org-contrib": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1694946041,
|
||||
"narHash": "sha256-X/HFG6NZe5BY00KvGbcsIuf9R6Lg8x7Uhd0Y5+Q3qZU=",
|
||||
"owner": "emacsmirror",
|
||||
"repo": "org-contrib",
|
||||
"rev": "5eabbf22bdd4523c922a30787e98ee66c24221aa",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "emacsmirror",
|
||||
"repo": "org-contrib",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"org-yt": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1527381913,
|
||||
"narHash": "sha256-dzQ6B7ryzatHCTLyEnRSbWO0VUiX/FHYnpHTs74aVUs=",
|
||||
"owner": "TobiasZawada",
|
||||
"repo": "org-yt",
|
||||
"rev": "40cc1ac76d741055cbefa13860d9f070a7ade001",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "TobiasZawada",
|
||||
"repo": "org-yt",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"php-extras": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1573312690,
|
||||
"narHash": "sha256-r4WyVbzvT0ra4Z6JywNBOw5RxOEYd6Qe2IpebHXkj1U=",
|
||||
"owner": "arnested",
|
||||
"repo": "php-extras",
|
||||
"rev": "d410c5af663c30c01d461ac476d1cbfbacb49367",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "arnested",
|
||||
"repo": "php-extras",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"pre-commit-hooks-nix": {
|
||||
"inputs": {
|
||||
"flake-compat": [
|
||||
"lanzaboote",
|
||||
"flake-compat"
|
||||
],
|
||||
"gitignore": "gitignore",
|
||||
"nixpkgs": [
|
||||
"lanzaboote",
|
||||
"nixpkgs"
|
||||
],
|
||||
"nixpkgs-stable": "nixpkgs-stable"
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1717664902,
|
||||
"narHash": "sha256-7XfBuLULizXjXfBYy/VV+SpYMHreNRHk9nKMsm1bgb4=",
|
||||
"owner": "cachix",
|
||||
"repo": "pre-commit-hooks.nix",
|
||||
"rev": "cc4d466cb1254af050ff7bdf47f6d404a7c646d1",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "cachix",
|
||||
"repo": "pre-commit-hooks.nix",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"revealjs": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1695738029,
|
||||
"narHash": "sha256-Z9c9Q41jMkj/DyXOiZYyIa7Gmn8VB8yauTyWrSsT+ps=",
|
||||
"owner": "hakimel",
|
||||
"repo": "reveal.js",
|
||||
"rev": "88fbfc5751ad01e3f6adee5819eabeb9e73c3757",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "hakimel",
|
||||
"repo": "reveal.js",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"root": {
|
||||
"inputs": {
|
||||
"agenix": "agenix",
|
||||
"flake-utils": "flake-utils",
|
||||
"home-manager": "home-manager",
|
||||
"lanzaboote": "lanzaboote",
|
||||
"nix-doom-emacs": "nix-doom-emacs",
|
||||
"nix-flatpak": "nix-flatpak",
|
||||
"nix-straight": "nix-straight",
|
||||
"nixgl": "nixgl",
|
||||
"nixpkgs": "nixpkgs",
|
||||
"nur": "nur",
|
||||
"systems": "systems_2"
|
||||
}
|
||||
},
|
||||
"rotate-text": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1322962747,
|
||||
"narHash": "sha256-SOeOgSlcEIsKhUiYDJv0p+mLUb420s9E2BmvZQvZ0wk=",
|
||||
"owner": "debug-ito",
|
||||
"repo": "rotate-text.el",
|
||||
"rev": "48f193697db996855aee1ad2bc99b38c6646fe76",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "debug-ito",
|
||||
"repo": "rotate-text.el",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"rust-overlay": {
|
||||
"inputs": {
|
||||
"flake-utils": [
|
||||
"lanzaboote",
|
||||
"flake-utils"
|
||||
],
|
||||
"nixpkgs": [
|
||||
"lanzaboote",
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1717813066,
|
||||
"narHash": "sha256-wqbRwq3i7g5EHIui0bIi84mdqZ/It1AXBSLJ5tafD28=",
|
||||
"owner": "oxalica",
|
||||
"repo": "rust-overlay",
|
||||
"rev": "6dc3e45fe4aee36efeed24d64fc68b1f989d5465",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "oxalica",
|
||||
"repo": "rust-overlay",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"sln-mode": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1423727528,
|
||||
"narHash": "sha256-XqkqPyEJuTtFslOz1fpTf/Klbd/zA7IGpzpmum/MGao=",
|
||||
"owner": "sensorflo",
|
||||
"repo": "sln-mode",
|
||||
"rev": "0f91d1b957c7d2a7bab9278ec57b54d57f1dbd9c",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "sensorflo",
|
||||
"repo": "sln-mode",
|
||||
"type": "github"
|
||||
"nixpkgs": "nixpkgs"
|
||||
}
|
||||
},
|
||||
"systems": {
|
||||
|
@ -811,74 +121,6 @@
|
|||
"repo": "default",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"systems_2": {
|
||||
"locked": {
|
||||
"lastModified": 1681028828,
|
||||
"narHash": "sha256-Vy1rq5AaRuLzOxct8nz4T6wlgyUR7zLU309k9mBC768=",
|
||||
"owner": "nix-systems",
|
||||
"repo": "default",
|
||||
"rev": "da67096a3b9bf56a91d16901293e51ba5b49a27e",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "nix-systems",
|
||||
"repo": "default",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"treefmt-nix": {
|
||||
"inputs": {
|
||||
"nixpkgs": [
|
||||
"nur",
|
||||
"nixpkgs"
|
||||
]
|
||||
},
|
||||
"locked": {
|
||||
"lastModified": 1733222881,
|
||||
"narHash": "sha256-JIPcz1PrpXUCbaccEnrcUS8jjEb/1vJbZz5KkobyFdM=",
|
||||
"owner": "numtide",
|
||||
"repo": "treefmt-nix",
|
||||
"rev": "49717b5af6f80172275d47a418c9719a31a78b53",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "numtide",
|
||||
"repo": "treefmt-nix",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"ts-fold": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1695278494,
|
||||
"narHash": "sha256-O4NcUC1u08W8ZslqoA/i+iTaLotKwheURXQWBxLLMFc=",
|
||||
"owner": "jcs-elpa",
|
||||
"repo": "ts-fold",
|
||||
"rev": "70b2c79ff4daa7351d4e2917b0343b9a18d4d4f2",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "jcs-elpa",
|
||||
"repo": "ts-fold",
|
||||
"type": "github"
|
||||
}
|
||||
},
|
||||
"ws-butler": {
|
||||
"flake": false,
|
||||
"locked": {
|
||||
"lastModified": 1634511126,
|
||||
"narHash": "sha256-c0y0ZPtxxICPk+eaNbbQf6t+FRCliNY54CCz9QHQ8ZI=",
|
||||
"owner": "hlissner",
|
||||
"repo": "ws-butler",
|
||||
"rev": "572a10c11b6cb88293de48acbb59a059d36f9ba5",
|
||||
"type": "github"
|
||||
},
|
||||
"original": {
|
||||
"owner": "hlissner",
|
||||
"repo": "ws-butler",
|
||||
"type": "github"
|
||||
}
|
||||
}
|
||||
},
|
||||
"root": "root",
|
||||
|
|
98
flake.nix
98
flake.nix
|
@ -4,15 +4,6 @@
|
|||
inputs = {
|
||||
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
|
||||
|
||||
# Use to clean dependencies
|
||||
systems.url = "github:nix-systems/default";
|
||||
flake-utils = {
|
||||
url = "github:numtide/flake-utils";
|
||||
inputs.systems.follows = "systems";
|
||||
};
|
||||
|
||||
nur.url = "github:nix-community/NUR";
|
||||
|
||||
home-manager = {
|
||||
url = "github:nix-community/home-manager";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
|
@ -22,44 +13,16 @@
|
|||
url = "github:ryantm/agenix";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
inputs.home-manager.follows = "home-manager";
|
||||
inputs.systems.follows = "systems";
|
||||
};
|
||||
|
||||
nix-flatpak.url = "github:gmodena/nix-flatpak/?ref=v0.4.1";
|
||||
|
||||
# Follow nix-doom-emacs completely when this is merged or fixed
|
||||
# - https://github.com/nix-community/nix-doom-emacs/issues/409
|
||||
# - https://github.com/nix-community/nix-straight.el/pull/4
|
||||
nix-straight = {
|
||||
url = "github:codingkoi/nix-straight.el?ref=codingkoi/apply-librephoenixs-fix";
|
||||
flake = false;
|
||||
};
|
||||
nix-doom-emacs = {
|
||||
url = "github:nix-community/nix-doom-emacs";
|
||||
inputs.nix-straight.follows = "nix-straight";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
inputs.flake-utils.follows = "flake-utils";
|
||||
};
|
||||
|
||||
# To use nixos program on others distros
|
||||
nixgl = {
|
||||
url = "github:nix-community/nixGL";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
inputs.flake-utils.follows = "flake-utils";
|
||||
};
|
||||
|
||||
lanzaboote = {
|
||||
url = "github:nix-community/lanzaboote/v0.4.1";
|
||||
inputs.nixpkgs.follows = "nixpkgs";
|
||||
};
|
||||
};
|
||||
|
||||
outputs = inputs@{
|
||||
nixpkgs,
|
||||
flake-utils,
|
||||
home-manager,
|
||||
agenix,
|
||||
lanzaboote,
|
||||
nix-flatpak,
|
||||
...
|
||||
}:
|
||||
let
|
||||
|
@ -67,23 +30,9 @@
|
|||
{ name = "nixos-test"; system = "x86_64-linux"; }
|
||||
{ name = "perso-laptop"; system = "x86_64-linux"; }
|
||||
{ name = "perso-desktop"; system = "x86_64-linux"; }
|
||||
];
|
||||
|
||||
home-modules = with inputs; [
|
||||
nix-flatpak.homeManagerModules.nix-flatpak
|
||||
nix-doom-emacs.hmModule
|
||||
];
|
||||
|
||||
overlays = with inputs; [
|
||||
nur.overlays.default
|
||||
nixgl.overlay
|
||||
{ name = "pro-laptop"; system = "x86_64-linux"; }
|
||||
];
|
||||
in {
|
||||
#####################################################################
|
||||
#####################################################################
|
||||
# Configure all nixos configurations
|
||||
#####################################################################
|
||||
#####################################################################
|
||||
nixosConfigurations = nixpkgs.lib.foldl (c: s:
|
||||
c // {
|
||||
${s.name} = nixpkgs.lib.nixosSystem {
|
||||
|
@ -92,54 +41,17 @@
|
|||
./hosts/${s.name}/configuration.nix
|
||||
home-manager.nixosModules.home-manager
|
||||
agenix.nixosModules.default
|
||||
lanzaboote.nixosModules.lanzaboote
|
||||
{ nixpkgs.overlays = overlays; }
|
||||
{
|
||||
home-manager.useGlobalPkgs = true;
|
||||
home-manager.useUserPackages = true;
|
||||
home-manager.extraSpecialArgs = inputs;
|
||||
home-manager.users.florian.imports = home-modules ++ [
|
||||
home-manager.users.florian.imports = [
|
||||
nix-flatpak.homeManagerModules.nix-flatpak
|
||||
./hosts/${s.name}/home.nix
|
||||
];
|
||||
}
|
||||
];
|
||||
};
|
||||
}) {} systems;
|
||||
|
||||
#####################################################################
|
||||
#####################################################################
|
||||
# Configure home configuration for all others systems like Arch Linux
|
||||
#####################################################################
|
||||
#####################################################################
|
||||
homeConfigurations = {
|
||||
perso-home = home-manager.lib.homeManagerConfiguration rec {
|
||||
pkgs = import nixpkgs { system = "x86_64-linux"; inherit overlays; };
|
||||
|
||||
modules = home-modules ++ [
|
||||
{ nix.package = pkgs.nix; }
|
||||
./hosts/perso-home/home.nix
|
||||
];
|
||||
};
|
||||
};
|
||||
}
|
||||
|
||||
#####################################################################
|
||||
#####################################################################
|
||||
# Configure development shell for all systems and merge with all
|
||||
# previous configurations with //
|
||||
#####################################################################
|
||||
#####################################################################
|
||||
// flake-utils.lib.eachSystem flake-utils.lib.allSystems (system:
|
||||
let
|
||||
pkgs = import nixpkgs { inherit system; };
|
||||
in
|
||||
{
|
||||
devShells = {
|
||||
default = pkgs.mkShell {
|
||||
packages = with pkgs; [
|
||||
nixd
|
||||
];
|
||||
};
|
||||
};
|
||||
});
|
||||
};
|
||||
}
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
# your system. Help is available in the configuration.nix(5) man page
|
||||
# and in the NixOS manual (accessible by running ‘nixos-help’).
|
||||
|
||||
{ ... }:
|
||||
{ config, pkgs, ... }:
|
||||
|
||||
{
|
||||
imports =
|
||||
|
@ -31,53 +31,28 @@
|
|||
# following configuration is added only when building VM with build-vm
|
||||
virtualisation = {
|
||||
memorySize = 8192; # Use 8192MiB memory.
|
||||
cores = 8;
|
||||
forwardPorts = [
|
||||
{ from = "host"; host.port = 8888; guest.port = 80; }
|
||||
];
|
||||
sharedDirectories = {
|
||||
home = {
|
||||
source = "/home/florian";
|
||||
target = "/mnt/shared_home";
|
||||
};
|
||||
};
|
||||
cores = 8;
|
||||
};
|
||||
};
|
||||
|
||||
modules.system = {
|
||||
desktop = {
|
||||
plasma.enable = true;
|
||||
};
|
||||
|
||||
server = {
|
||||
docker.enable = true;
|
||||
openssh.enable = true;
|
||||
};
|
||||
|
||||
desktop = {
|
||||
plasma = {
|
||||
enable = true;
|
||||
};
|
||||
};
|
||||
|
||||
hardware = {
|
||||
bluetooth.enable = true;
|
||||
gamingKernel.enable = true;
|
||||
keymaps.layout = "us";
|
||||
pipewire.enable = true;
|
||||
plymouth.enable = true;
|
||||
printing.enable = true;
|
||||
waydroid.enable = true;
|
||||
};
|
||||
};
|
||||
|
||||
# Run containers
|
||||
virtualisation.oci-containers.containers."hello" = {
|
||||
image = "docker.io/nginxdemos/hello:latest";
|
||||
|
||||
ports = [
|
||||
"9000:80/tcp"
|
||||
];
|
||||
};
|
||||
|
||||
services.nginx = {
|
||||
enable = true;
|
||||
virtualHosts."hello.local" = {
|
||||
locations."/" = {
|
||||
proxyPass = "http://127.0.0.1:9000";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
networking.firewall.allowedTCPPorts = [ 80 ]; # Opens port 80 for HTTP traffic.
|
||||
}
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
# Do not modify this file! It was generated by ‘nixos-generate-config’
|
||||
# and may be overwritten by future invocations. Please make changes
|
||||
# to /etc/nixos/configuration.nix instead.
|
||||
{ lib, modulesPath, ... }:
|
||||
{ config, lib, pkgs, modulesPath, ... }:
|
||||
|
||||
{
|
||||
imports =
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
{ ... }:
|
||||
{ config, pkgs, ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
|
@ -7,6 +7,7 @@
|
|||
|
||||
modules.home = {
|
||||
apps = {
|
||||
chromium.enable = true;
|
||||
flatpak.enable = true;
|
||||
jetbrainsToolbox.enable = true;
|
||||
kitty.enable = true;
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
# 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, ... }:
|
||||
|
||||
{
|
||||
imports =
|
||||
|
@ -14,32 +14,14 @@
|
|||
];
|
||||
|
||||
# Bootloader.
|
||||
# For lanzaboote see https://github.com/nix-community/lanzaboote/blob/master/docs/QUICK_START.md
|
||||
boot.loader.systemd-boot.enable = lib.mkForce false;
|
||||
boot.lanzaboote = {
|
||||
enable = true;
|
||||
pkiBundle = "/var/lib/sbctl";
|
||||
};
|
||||
boot.loader.systemd-boot.windows = {
|
||||
"11-pro" = {
|
||||
title = "Windows 11 Pro";
|
||||
efiDeviceHandle = "HD1b";
|
||||
};
|
||||
};
|
||||
boot.loader.systemd-boot.enable = true;
|
||||
boot.loader.efi.canTouchEfiVariables = true;
|
||||
|
||||
networking.hostName = "nixos-desktop-perso"; # Define your hostname.
|
||||
|
||||
modules.system = {
|
||||
apps = {
|
||||
flatpak.enable = true;
|
||||
steam.enable = true;
|
||||
};
|
||||
|
||||
desktop = {
|
||||
plasma = {
|
||||
enable = true;
|
||||
};
|
||||
plasma.enable = true;
|
||||
};
|
||||
|
||||
hardware = {
|
||||
|
@ -51,10 +33,15 @@
|
|||
plymouth.enable = true;
|
||||
printing.enable = true;
|
||||
waydroid.enable = true;
|
||||
|
||||
nix-ld = {
|
||||
enable = true;
|
||||
enableKdeDevelopmentEnvironment = true;
|
||||
};
|
||||
};
|
||||
|
||||
server = {
|
||||
distrobox.enable = true;
|
||||
ollama.enable = true;
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
|
@ -8,24 +8,23 @@
|
|||
[ (modulesPath + "/installer/scan/not-detected.nix")
|
||||
];
|
||||
|
||||
boot.initrd.availableKernelModules = [ "xhci_pci" "ahci" "nvme" "usbhid" "usb_storage" "sd_mod" ];
|
||||
boot.initrd.availableKernelModules = [ "xhci_pci" "ahci" "nvme" "usb_storage" "usbhid" "sd_mod" ];
|
||||
boot.initrd.kernelModules = [ ];
|
||||
boot.kernelModules = [ "kvm-amd" ];
|
||||
boot.extraModulePackages = [ ];
|
||||
|
||||
fileSystems."/" =
|
||||
{ device = "/dev/disk/by-uuid/b10668d4-6394-4e00-b6ec-54fe688484d2";
|
||||
{ device = "/dev/disk/by-uuid/00bd8694-ef7c-49c5-95ec-7d9fecb73944";
|
||||
fsType = "ext4";
|
||||
};
|
||||
|
||||
fileSystems."/boot" =
|
||||
{ device = "/dev/disk/by-uuid/FACE-AC18";
|
||||
{ device = "/dev/disk/by-uuid/9062-09B7";
|
||||
fsType = "vfat";
|
||||
options = [ "fmask=0077" "dmask=0077" ];
|
||||
};
|
||||
|
||||
swapDevices =
|
||||
[ { device = "/var/lib/swapfile"; size = 32*1024; }
|
||||
[ { device = "/dev/disk/by-uuid/585d371b-36e7-4df7-98fc-697135a36538"; }
|
||||
];
|
||||
|
||||
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
{ ... }:
|
||||
{ config, pkgs, ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
|
@ -7,6 +7,7 @@
|
|||
|
||||
modules.home = {
|
||||
apps = {
|
||||
chromium.enable = true;
|
||||
flatpak.enable = true;
|
||||
jetbrainsToolbox.enable = true;
|
||||
kitty.enable = true;
|
||||
|
|
|
@ -2,7 +2,7 @@
|
|||
# your system. Help is available in the configuration.nix(5) man page
|
||||
# and in the NixOS manual (accessible by running ‘nixos-help’).
|
||||
|
||||
{ ... }:
|
||||
{ config, pkgs, ... }:
|
||||
|
||||
{
|
||||
imports =
|
||||
|
@ -33,11 +33,6 @@
|
|||
};
|
||||
|
||||
modules.system = {
|
||||
apps = {
|
||||
steam.enable = true;
|
||||
flatpak.enable = true;
|
||||
};
|
||||
|
||||
desktop = {
|
||||
plasma.enable = true;
|
||||
};
|
||||
|
@ -52,5 +47,9 @@
|
|||
printing.enable = true;
|
||||
waydroid.enable = true;
|
||||
};
|
||||
|
||||
server = {
|
||||
ollama.enable = true;
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
|
@ -14,18 +14,17 @@
|
|||
boot.extraModulePackages = [ ];
|
||||
|
||||
fileSystems."/" =
|
||||
{ device = "/dev/disk/by-uuid/e0c9f32c-0a05-4fec-a3d5-5507b9c0b3c2";
|
||||
{ device = "/dev/disk/by-uuid/2559c3d8-2d01-4666-b1e2-e448dbe90dda";
|
||||
fsType = "ext4";
|
||||
};
|
||||
|
||||
fileSystems."/boot" =
|
||||
{ device = "/dev/disk/by-uuid/3F81-54F0";
|
||||
{ device = "/dev/disk/by-uuid/D8F8-89DC";
|
||||
fsType = "vfat";
|
||||
options = [ "fmask=0077" "dmask=0077" ];
|
||||
};
|
||||
|
||||
swapDevices =
|
||||
[ { device = "/dev/disk/by-uuid/b0aedbe7-9ffe-4039-9151-4d64a13b133d"; }
|
||||
[ { device = "/dev/disk/by-uuid/9dae0d33-697c-442e-bc64-b79ad643d089"; }
|
||||
];
|
||||
|
||||
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
{ ... }:
|
||||
{ config, pkgs, ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
|
@ -7,6 +7,7 @@
|
|||
|
||||
modules.home = {
|
||||
apps = {
|
||||
chromium.enable = true;
|
||||
flatpak.enable = true;
|
||||
jetbrainsToolbox.enable = true;
|
||||
kitty.enable = true;
|
||||
|
|
42
hosts/pro-laptop/configuration.nix
Normal file
42
hosts/pro-laptop/configuration.nix
Normal file
|
@ -0,0 +1,42 @@
|
|||
# Edit this configuration file to define what should be installed on
|
||||
# your system. Help is available in the configuration.nix(5) man page
|
||||
# and in the NixOS manual (accessible by running ‘nixos-help’).
|
||||
|
||||
{ config, pkgs, ... }:
|
||||
|
||||
{
|
||||
imports =
|
||||
[
|
||||
../../modules/system
|
||||
|
||||
# Include the results of the hardware scan.
|
||||
./hardware-configuration.nix
|
||||
];
|
||||
|
||||
# Bootloader.
|
||||
boot.loader.systemd-boot.enable = true;
|
||||
boot.loader.efi.canTouchEfiVariables = true;
|
||||
|
||||
networking.hostName = "nixos-laptop-pro"; # Define your hostname.
|
||||
|
||||
modules.system = {
|
||||
desktop = {
|
||||
plasma.enable = true;
|
||||
};
|
||||
|
||||
hardware = {
|
||||
bluetooth.enable = true;
|
||||
gamingKernel.enable = true;
|
||||
keymaps.layout = "fr";
|
||||
nvidia.enable = true;
|
||||
pipewire.enable = true;
|
||||
plymouth.enable = true;
|
||||
printing.enable = true;
|
||||
waydroid.enable = true;
|
||||
};
|
||||
|
||||
server = {
|
||||
ollama.enable = true;
|
||||
};
|
||||
};
|
||||
}
|
40
hosts/pro-laptop/hardware-configuration.nix
Normal file
40
hosts/pro-laptop/hardware-configuration.nix
Normal file
|
@ -0,0 +1,40 @@
|
|||
# Do not modify this file! It was generated by ‘nixos-generate-config’
|
||||
# and may be overwritten by future invocations. Please make changes
|
||||
# to /etc/nixos/configuration.nix instead.
|
||||
{ config, lib, pkgs, modulesPath, ... }:
|
||||
|
||||
{
|
||||
imports =
|
||||
[ (modulesPath + "/installer/scan/not-detected.nix")
|
||||
];
|
||||
|
||||
boot.initrd.availableKernelModules = [ "xhci_pci" "nvme" "usb_storage" "sd_mod" "rtsx_pci_sdmmc" ];
|
||||
boot.initrd.kernelModules = [ ];
|
||||
boot.kernelModules = [ "kvm-intel" ];
|
||||
boot.extraModulePackages = [ ];
|
||||
|
||||
fileSystems."/" =
|
||||
{ device = "/dev/disk/by-uuid/98137863-d1f5-4286-9385-42abf74b44a6";
|
||||
fsType = "ext4";
|
||||
};
|
||||
|
||||
fileSystems."/boot" =
|
||||
{ device = "/dev/disk/by-uuid/51DB-A393";
|
||||
fsType = "vfat";
|
||||
};
|
||||
|
||||
swapDevices =
|
||||
[ { device = "/dev/disk/by-uuid/7b49cd63-3b19-43bb-acc9-0d27d92152b9"; }
|
||||
];
|
||||
|
||||
# Enables DHCP on each ethernet and wireless interface. In case of scripted networking
|
||||
# (the default) this is the recommended approach. When using systemd-networkd it's
|
||||
# still possible to use this option, but it's recommended to use it in conjunction
|
||||
# with explicit per-interface declarations with `networking.interfaces.<interface>.useDHCP`.
|
||||
networking.useDHCP = lib.mkDefault true;
|
||||
# networking.interfaces.enp0s31f6.useDHCP = lib.mkDefault true;
|
||||
# networking.interfaces.wlp0s20f3.useDHCP = lib.mkDefault true;
|
||||
|
||||
nixpkgs.hostPlatform = lib.mkDefault "x86_64-linux";
|
||||
hardware.cpu.intel.updateMicrocode = lib.mkDefault config.hardware.enableRedistributableFirmware;
|
||||
}
|
|
@ -1,4 +1,4 @@
|
|||
{ ... }:
|
||||
{ config, pkgs, ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
|
@ -7,6 +7,9 @@
|
|||
|
||||
modules.home = {
|
||||
apps = {
|
||||
chromium.enable = true;
|
||||
flatpak.enable = true;
|
||||
jetbrainsToolbox.enable = true;
|
||||
kitty.enable = true;
|
||||
};
|
||||
|
||||
|
@ -18,3 +21,4 @@
|
|||
};
|
||||
};
|
||||
}
|
||||
|
|
@ -1,5 +0,0 @@
|
|||
{ ... }:
|
||||
|
||||
{
|
||||
nix.settings.experimental-features = [ "nix-command" "flakes" ];
|
||||
}
|
|
@ -1,11 +1,10 @@
|
|||
{ ... }:
|
||||
{ config, pkgs, ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
./chromium
|
||||
./firefox
|
||||
./flatpak
|
||||
./jetbrainsToolbox
|
||||
./kitty
|
||||
];
|
||||
}
|
||||
}
|
|
@ -1,44 +0,0 @@
|
|||
{ config, pkgs, lib, ... }:
|
||||
|
||||
with lib;
|
||||
let
|
||||
cfg = config.modules.home.apps.firefox;
|
||||
in
|
||||
{
|
||||
options.modules.home.apps.firefox = {
|
||||
enable = mkEnableOption ''
|
||||
Enable firefox with my custom configurations
|
||||
'';
|
||||
};
|
||||
config = mkIf cfg.enable {
|
||||
programs.firefox = {
|
||||
enable = true;
|
||||
|
||||
nativeMessagingHosts = [
|
||||
pkgs.kdePackages.plasma-browser-integration
|
||||
];
|
||||
|
||||
profiles = {
|
||||
perso = {
|
||||
id = 0;
|
||||
|
||||
name = "Perso";
|
||||
|
||||
extensions = with pkgs.nur.repos.rycee.firefox-addons; [
|
||||
ublock-origin
|
||||
bitwarden
|
||||
floccus
|
||||
plasma-integration
|
||||
istilldontcareaboutcookies
|
||||
darkreader
|
||||
];
|
||||
|
||||
settings = {
|
||||
# Enable multi-pip
|
||||
"media.videocontrols.picture-in-picture.allow-multiple" = true;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
|
@ -12,6 +12,7 @@ in
|
|||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
|
||||
services.flatpak = {
|
||||
enable = true;
|
||||
|
||||
|
@ -20,16 +21,23 @@ in
|
|||
packages = [
|
||||
# Gaming
|
||||
{ appId = "com.discordapp.Discord"; origin = "flathub"; }
|
||||
{ appId = "com.valvesoftware.Steam"; origin = "flathub"; }
|
||||
{ appId = "net.lutris.Lutris"; origin = "flathub"; }
|
||||
|
||||
# Pro
|
||||
{ appId = "com.slack.Slack"; origin = "flathub"; }
|
||||
{ appId = "com.skype.Client"; origin = "flathub"; }
|
||||
{ appId = "org.mozilla.Thunderbird"; origin = "flathub"; }
|
||||
{ appId = "ch.protonmail.protonmail-bridge"; origin = "flathub"; }
|
||||
{ appId = "org.kde.neochat"; origin = "flathub"; }
|
||||
{ appId = "com.visualstudio.code"; origin = "flathub"; }
|
||||
|
||||
# Loisir
|
||||
{ appId = "io.github.zen_browser.zen"; origin = "flathub"; }
|
||||
{ appId = "com.spotify.Client"; origin = "flathub"; }
|
||||
{ appId = "io.gitlab.news_flash.NewsFlash"; origin = "flathub"; }
|
||||
{ appId = "org.videolan.VLC"; origin = "flathub"; }
|
||||
{ appId = "com.obsproject.Studio"; origin = "flathub"; }
|
||||
{ appId = "io.github.achetagames.epic_asset_manager"; origin = "flathub"; }
|
||||
];
|
||||
};
|
||||
};
|
||||
|
|
|
@ -11,6 +11,6 @@ in
|
|||
'';
|
||||
};
|
||||
config = mkIf cfg.enable {
|
||||
home.packages = with pkgs; [jetbrains-toolbox graalvm-ce];
|
||||
home.packages = with pkgs; [jetbrains-toolbox];
|
||||
};
|
||||
}
|
|
@ -25,7 +25,7 @@ in
|
|||
|
||||
font = {
|
||||
name = "FiraCode Nerd Font";
|
||||
package = pkgs.nerd-fonts.fira-code;
|
||||
package = pkgs.fira-code-nerdfont;
|
||||
};
|
||||
|
||||
settings = lib.mkMerge [
|
||||
|
|
|
@ -1,10 +1,8 @@
|
|||
{ ... }:
|
||||
{ config, pkgs, ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
../common.nix
|
||||
./apps
|
||||
./editors
|
||||
./desktop
|
||||
./shell
|
||||
];
|
||||
|
@ -13,9 +11,10 @@
|
|||
username = "florian";
|
||||
homeDirectory = "/home/florian";
|
||||
|
||||
stateVersion = "25.05";
|
||||
stateVersion = "24.05";
|
||||
};
|
||||
|
||||
programs.home-manager.enable = true;
|
||||
nix.settings.experimental-features = [ "nix-command" "flakes" ];
|
||||
}
|
||||
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
{ ... }:
|
||||
{ config, pkgs, ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
|
|
|
@ -1,8 +0,0 @@
|
|||
{ ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
./emacs
|
||||
./vscode
|
||||
];
|
||||
}
|
|
@ -1,19 +0,0 @@
|
|||
{ config, lib, ... }:
|
||||
|
||||
with lib;
|
||||
let
|
||||
cfg = config.modules.home.editors.emacs;
|
||||
in
|
||||
{
|
||||
options.modules.home.editors.emacs = {
|
||||
enable = mkEnableOption ''
|
||||
Enable emacs with my custom configurations
|
||||
'';
|
||||
};
|
||||
config = mkIf cfg.enable {
|
||||
programs.doom-emacs = {
|
||||
enable = true;
|
||||
doomPrivateDir = ./doom.d;
|
||||
};
|
||||
};
|
||||
}
|
|
@ -1,76 +0,0 @@
|
|||
;;; $DOOMDIR/config.el -*- lexical-binding: t; -*-
|
||||
|
||||
;; Place your private configuration here! Remember, you do not need to run 'doom
|
||||
;; sync' after modifying this file!
|
||||
|
||||
|
||||
;; Some functionality uses this to identify you, e.g. GPG configuration, email
|
||||
;; clients, file templates and snippets. It is optional.
|
||||
;; (setq user-full-name "John Doe"
|
||||
;; user-mail-address "john@doe.com")
|
||||
|
||||
;; Doom exposes five (optional) variables for controlling fonts in Doom:
|
||||
;;
|
||||
;; - `doom-font' -- the primary font to use
|
||||
;; - `doom-variable-pitch-font' -- a non-monospace font (where applicable)
|
||||
;; - `doom-big-font' -- used for `doom-big-font-mode'; use this for
|
||||
;; presentations or streaming.
|
||||
;; - `doom-symbol-font' -- for symbols
|
||||
;; - `doom-serif-font' -- for the `fixed-pitch-serif' face
|
||||
;;
|
||||
;; See 'C-h v doom-font' for documentation and more examples of what they
|
||||
;; accept. For example:
|
||||
;;
|
||||
;; (setq doom-font (font-spec :family "Fira Code" :size 12 :weight 'semi-light)
|
||||
;; doom-variable-pitch-font (font-spec :family "Fira Sans" :size 13))
|
||||
;;
|
||||
;; If you or Emacs can't find your font, use 'M-x describe-font' to look them
|
||||
;; up, `M-x eval-region' to execute elisp code, and 'M-x doom/reload-font' to
|
||||
;; refresh your font settings. If Emacs still can't find your font, it likely
|
||||
;; wasn't installed correctly. Font issues are rarely Doom issues!
|
||||
|
||||
;; There are two ways to load a theme. Both assume the theme is installed and
|
||||
;; available. You can either set `doom-theme' or manually load a theme with the
|
||||
;; `load-theme' function. This is the default:
|
||||
(setq doom-theme 'doom-one)
|
||||
|
||||
;; This determines the style of line numbers in effect. If set to `nil', line
|
||||
;; numbers are disabled. For relative line numbers, set this to `relative'.
|
||||
(setq display-line-numbers-type t)
|
||||
|
||||
;; If you use `org' and don't want your org files in the default location below,
|
||||
;; change `org-directory'. It must be set before org loads!
|
||||
(setq org-directory "~/org/")
|
||||
|
||||
|
||||
;; Whenever you reconfigure a package, make sure to wrap your config in an
|
||||
;; `after!' block, otherwise Doom's defaults may override your settings. E.g.
|
||||
;;
|
||||
;; (after! PACKAGE
|
||||
;; (setq x y))
|
||||
;;
|
||||
;; The exceptions to this rule:
|
||||
;;
|
||||
;; - Setting file/directory variables (like `org-directory')
|
||||
;; - Setting variables which explicitly tell you to set them before their
|
||||
;; package is loaded (see 'C-h v VARIABLE' to look up their documentation).
|
||||
;; - Setting doom variables (which start with 'doom-' or '+').
|
||||
;;
|
||||
;; Here are some additional functions/macros that will help you configure Doom.
|
||||
;;
|
||||
;; - `load!' for loading external *.el files relative to this one
|
||||
;; - `use-package!' for configuring packages
|
||||
;; - `after!' for running code after a package has loaded
|
||||
;; - `add-load-path!' for adding directories to the `load-path', relative to
|
||||
;; this file. Emacs searches the `load-path' when you load packages with
|
||||
;; `require' or `use-package'.
|
||||
;; - `map!' for binding new keys
|
||||
;;
|
||||
;; To get information about any of these functions/macros, move the cursor over
|
||||
;; the highlighted symbol at press 'K' (non-evil users must press 'C-c c k').
|
||||
;; This will open documentation for it, including demos of how they are used.
|
||||
;; Alternatively, use `C-h o' to look up a symbol (functions, variables, faces,
|
||||
;; etc).
|
||||
;;
|
||||
;; You can also try 'gd' (or 'C-c c d') to jump to their definition and see how
|
||||
;; they are implemented.
|
|
@ -1,195 +0,0 @@
|
|||
;;; init.el -*- lexical-binding: t; -*-
|
||||
|
||||
;; This file controls what Doom modules are enabled and what order they load
|
||||
;; in. Remember to run 'doom sync' after modifying it!
|
||||
|
||||
;; NOTE Press 'SPC h d h' (or 'C-h d h' for non-vim users) to access Doom's
|
||||
;; documentation. There you'll find a link to Doom's Module Index where all
|
||||
;; of our modules are listed, including what flags they support.
|
||||
|
||||
;; NOTE Move your cursor over a module's name (or its flags) and press 'K' (or
|
||||
;; 'C-c c k' for non-vim users) to view its documentation. This works on
|
||||
;; flags as well (those symbols that start with a plus).
|
||||
;;
|
||||
;; Alternatively, press 'gd' (or 'C-c c d') on a module to browse its
|
||||
;; directory (for easy access to its source code).
|
||||
|
||||
(doom! :input
|
||||
;;bidi ; (tfel ot) thgir etirw uoy gnipleh
|
||||
;;chinese
|
||||
;;japanese
|
||||
;;layout ; auie,ctsrnm is the superior home row
|
||||
|
||||
:completion
|
||||
company ; the ultimate code completion backend
|
||||
;;helm ; the *other* search engine for love and life
|
||||
;;ido ; the other *other* search engine...
|
||||
;;ivy ; a search engine for love and life
|
||||
vertico ; the search engine of the future
|
||||
|
||||
:ui
|
||||
;;deft ; notational velocity for Emacs
|
||||
doom ; what makes DOOM look the way it does
|
||||
doom-dashboard ; a nifty splash screen for Emacs
|
||||
;;doom-quit ; DOOM quit-message prompts when you quit Emacs
|
||||
(emoji +unicode) ; 🙂
|
||||
hl-todo ; highlight TODO/FIXME/NOTE/DEPRECATED/HACK/REVIEW
|
||||
;;hydra
|
||||
;;indent-guides ; highlighted indent columns
|
||||
ligatures ; ligatures and symbols to make your code pretty again
|
||||
;;minimap ; show a map of the code on the side
|
||||
modeline ; snazzy, Atom-inspired modeline, plus API
|
||||
nav-flash ; blink cursor line after big motions
|
||||
;;neotree ; a project drawer, like NERDTree for vim
|
||||
ophints ; highlight the region an operation acts on
|
||||
(popup +defaults) ; tame sudden yet inevitable temporary windows
|
||||
tabs ; a tab bar for Emacs
|
||||
(treemacs +lsp) ; a project drawer, like neotree but cooler
|
||||
;;unicode ; extended unicode support for various languages
|
||||
(vc-gutter +pretty) ; vcs diff in the fringe
|
||||
vi-tilde-fringe ; fringe tildes to mark beyond EOB
|
||||
;;window-select ; visually switch windows
|
||||
workspaces ; tab emulation, persistence & separate workspaces
|
||||
;;zen ; distraction-free coding or writing
|
||||
|
||||
:editor
|
||||
(evil +everywhere); come to the dark side, we have cookies
|
||||
file-templates ; auto-snippets for empty files
|
||||
fold ; (nigh) universal code folding
|
||||
;;(format +onsave) ; automated prettiness
|
||||
;;god ; run Emacs commands without modifier keys
|
||||
;;lispy ; vim for lisp, for people who don't like vim
|
||||
multiple-cursors ; editing in many places at once
|
||||
;;objed ; text object editing for the innocent
|
||||
;;parinfer ; turn lisp into python, sort of
|
||||
;;rotate-text ; cycle region at point between text candidates
|
||||
snippets ; my elves. They type so I don't have to
|
||||
;;word-wrap ; soft wrapping with language-aware indent
|
||||
|
||||
:emacs
|
||||
dired ; making dired pretty [functional]
|
||||
electric ; smarter, keyword-based electric-indent
|
||||
(ibuffer +icons) ; interactive buffer management
|
||||
undo ; persistent, smarter undo for your inevitable mistakes
|
||||
vc ; version-control and Emacs, sitting in a tree
|
||||
|
||||
:term
|
||||
eshell ; the elisp shell that works everywhere
|
||||
;;shell ; simple shell REPL for Emacs
|
||||
;;term ; basic terminal emulator for Emacs
|
||||
;;vterm ; the best terminal emulation in Emacs
|
||||
|
||||
:checkers
|
||||
syntax ; tasing you for every semicolon you forget
|
||||
;;(spell +flyspell) ; tasing you for misspelling mispelling
|
||||
;;grammar ; tasing grammar mistake every you make
|
||||
|
||||
:tools
|
||||
;;ansible
|
||||
;;biblio ; Writes a PhD for you (citation needed)
|
||||
;;collab ; buffers with friends
|
||||
(debugger +lsp) ; FIXME stepping through code, to help you add bugs
|
||||
;;direnv
|
||||
;;docker
|
||||
;;editorconfig ; let someone else argue about tabs vs spaces
|
||||
;;ein ; tame Jupyter notebooks with emacs
|
||||
(eval +overlay) ; run code, run (also, repls)
|
||||
;;gist ; interacting with github gists
|
||||
lookup ; navigate your code and its documentation
|
||||
lsp ; M-x vscode
|
||||
magit ; a git porcelain for Emacs
|
||||
;;make ; run make tasks from Emacs
|
||||
;;pass ; password manager for nerds
|
||||
;;pdf ; pdf enhancements
|
||||
;;prodigy ; FIXME managing external services & code builders
|
||||
rgb ; creating color strings
|
||||
;;taskrunner ; taskrunner for all your projects
|
||||
;;terraform ; infrastructure as code
|
||||
;;tmux ; an API for interacting with tmux
|
||||
tree-sitter ; syntax and parsing, sitting in a tree...
|
||||
;;upload ; map local to remote projects via ssh/ftp
|
||||
|
||||
:os
|
||||
(:if IS-MAC macos) ; improve compatibility with macOS
|
||||
;;tty ; improve the terminal Emacs experience
|
||||
|
||||
:lang
|
||||
;;agda ; types of types of types of types...
|
||||
;;beancount ; mind the GAAP
|
||||
(cc +lsp) ; C > C++ == 1
|
||||
;;cloju
|
||||
;;common-lisp ; if you've seen one lisp, you've seen them all
|
||||
;;coq ; proofs-as-programs
|
||||
;;crystal ; ruby at the speed of c
|
||||
;;csharp ; unity, .NET, and mono shenanigans
|
||||
;;data ; config/data formats
|
||||
(dart +flutter +lsp) ; paint ui and not much else
|
||||
;;dhall
|
||||
(elixir +lsp) ; erlang done right
|
||||
;;elm ; care for a cup of TEA?
|
||||
emacs-lisp ; drown in parentheses
|
||||
;;erlang ; an elegant language for a more civilized age
|
||||
;;ess ; emacs speaks statistics
|
||||
;;factor
|
||||
;;faust ; dsp, but you get to keep your soul
|
||||
;;fortran ; in FORTRAN, GOD is REAL (unless declared INTEGER)
|
||||
;;fsharp ; ML stands for Microsoft's Language
|
||||
;;fstar ; (dependent) types and (monadic) effects and Z3
|
||||
;;gdscript ; the language you waited for
|
||||
;;(go +lsp) ; the hipster dialect
|
||||
;;(graphql +lsp) ; Give queries a REST
|
||||
;;(haskell +lsp) ; a language that's lazier than I am
|
||||
;;hy ; readability of scheme w/ speed of python
|
||||
;;idris ; a language you can depend on
|
||||
json ; At least it ain't XML
|
||||
(java +lsp) ; the poster child for carpal tunnel syndrome
|
||||
;;javascript ; all(hope(abandon(ye(who(enter(here))))))
|
||||
;;julia ; a better, faster MATLAB
|
||||
(kotlin +lsp) ; a better, slicker Java(Script)
|
||||
;;latex ; writing papers in Emacs has never been so fun
|
||||
;;lean ; for folks with too much to prove
|
||||
;;ledger ; be audit you can be
|
||||
;;lua ; one-based indices? one-based indices
|
||||
markdown ; writing docs for people to ignore
|
||||
;;nim ; python + lisp at the speed of c
|
||||
;;nix ; I hereby declare "nix geht mehr!"
|
||||
;;ocaml ; an objective camel
|
||||
org ; organize your plain life in plain text
|
||||
;;php ; perl's insecure younger brother
|
||||
;;plantuml ; diagrams for confusing people more
|
||||
;;purescript ; javascript, but functional
|
||||
;;python ; beautiful is better than ugly
|
||||
(qt +lsp +xp) ; the 'cutest' gui framework ever
|
||||
;;racket ; a DSL for DSLs
|
||||
;;raku ; the artist formerly known as perl6
|
||||
;;rest ; Emacs as a REST client
|
||||
;;rst ; ReST in peace
|
||||
(ruby +lsp +rails) ; 1.step {|i| p "Ruby is #{i.even? ? 'love' : 'life'}"}
|
||||
(rust +lsp) ; Fe2O3.unwrap().unwrap().unwrap().unwrap()
|
||||
;;scala ; java, but good
|
||||
;;(scheme +guile) ; a fully conniving family of lisps
|
||||
sh ; she sells {ba,z,fi}sh shells on the C xor
|
||||
;;sml
|
||||
;;solidity ; do you need a blockchain? No.
|
||||
;;swift ; who asked for emoji variables?
|
||||
;;terra ; Earth and Moon in alignment for performance.
|
||||
;;web ; the tubes
|
||||
yaml ; JSON, but readable
|
||||
;;zig ; C, but simpler
|
||||
|
||||
:email
|
||||
;;(mu4e +org +gmail)
|
||||
;;notmuch
|
||||
;;(wanderlust +gmail)
|
||||
|
||||
:app
|
||||
;;calendar
|
||||
;;emms
|
||||
;;everywhere ; *leave* Emacs!? You must be joking
|
||||
;;irc ; how neckbeards socialize
|
||||
;;(rss +org) ; emacs as an RSS reader
|
||||
;;twitter ; twitter client https://twitter.com/vnought
|
||||
|
||||
:config
|
||||
;;literate
|
||||
(default +bindings +smartparens))
|
|
@ -1,52 +0,0 @@
|
|||
;; -*- no-byte-compile: t; -*-
|
||||
;;; $DOOMDIR/packages.el
|
||||
|
||||
;; To install a package with Doom you must declare them here and run 'doom sync'
|
||||
;; on the command line, then restart Emacs for the changes to take effect -- or
|
||||
;; use 'M-x doom/reload'.
|
||||
|
||||
|
||||
;; To install SOME-PACKAGE from MELPA, ELPA or emacsmirror:
|
||||
;(package! some-package)
|
||||
|
||||
;; To install a package directly from a remote git repo, you must specify a
|
||||
;; `:recipe'. You'll find documentation on what `:recipe' accepts here:
|
||||
;; https://github.com/radian-software/straight.el#the-recipe-format
|
||||
;(package! another-package
|
||||
; :recipe (:host github :repo "username/repo"))
|
||||
|
||||
;; If the package you are trying to install does not contain a PACKAGENAME.el
|
||||
;; file, or is located in a subdirectory of the repo, you'll need to specify
|
||||
;; `:files' in the `:recipe':
|
||||
;(package! this-package
|
||||
; :recipe (:host github :repo "username/repo"
|
||||
; :files ("some-file.el" "src/lisp/*.el")))
|
||||
|
||||
;; If you'd like to disable a package included with Doom, you can do so here
|
||||
;; with the `:disable' property:
|
||||
;(package! builtin-package :disable t)
|
||||
|
||||
;; You can override the recipe of a built in package without having to specify
|
||||
;; all the properties for `:recipe'. These will inherit the rest of its recipe
|
||||
;; from Doom or MELPA/ELPA/Emacsmirror:
|
||||
;(package! builtin-package :recipe (:nonrecursive t))
|
||||
;(package! builtin-package-2 :recipe (:repo "myfork/package"))
|
||||
|
||||
;; Specify a `:branch' to install a package from a particular branch or tag.
|
||||
;; This is required for some packages whose default branch isn't 'master' (which
|
||||
;; our package manager can't deal with; see radian-software/straight.el#279)
|
||||
;(package! builtin-package :recipe (:branch "develop"))
|
||||
|
||||
;; Use `:pin' to specify a particular commit to install.
|
||||
;(package! builtin-package :pin "1a2b3c4d5e")
|
||||
|
||||
|
||||
;; Doom's packages are pinned to a specific commit and updated from release to
|
||||
;; release. The `unpin!' macro allows you to unpin single packages...
|
||||
;(unpin! pinned-package)
|
||||
;; ...or multiple packages
|
||||
;(unpin! pinned-package another-pinned-package)
|
||||
;; ...Or *all* packages (NOT RECOMMENDED; will likely break things)
|
||||
;(unpin! t)
|
||||
|
||||
(package! ripgrep)
|
|
@ -1,48 +0,0 @@
|
|||
{ config, pkgs, lib, ... }:
|
||||
|
||||
with lib;
|
||||
let
|
||||
cfg = config.modules.home.editors.vscode;
|
||||
in
|
||||
{
|
||||
options.modules.home.editors.vscode = {
|
||||
enable = mkEnableOption ''
|
||||
Enable vscode with my custom configurations
|
||||
'';
|
||||
};
|
||||
config = mkIf cfg.enable {
|
||||
programs.vscode = {
|
||||
enable = true;
|
||||
enableUpdateCheck = false;
|
||||
enableExtensionUpdateCheck = false;
|
||||
|
||||
userSettings = {
|
||||
"files.autoSave" = "onFocusChange";
|
||||
"emmet.includeLanguages" = {
|
||||
"phoenix-heex" = "html";
|
||||
};
|
||||
"git.autofetch" = true;
|
||||
};
|
||||
|
||||
userTasks = {};
|
||||
|
||||
# Waiting https://github.com/nix-community/home-manager/pull/5640 to support multi-profiles support
|
||||
extensions = with pkgs; with vscode-extensions; [
|
||||
# Nix
|
||||
bbenoist.nix
|
||||
|
||||
# Rust
|
||||
rust-lang.rust-analyzer
|
||||
serayuzgur.crates
|
||||
tamasfe.even-better-toml
|
||||
|
||||
# Phoenix
|
||||
phoenixframework.phoenix
|
||||
elixir-lsp.vscode-elixir-ls
|
||||
|
||||
# Ruby
|
||||
shopify.ruby-lsp
|
||||
];
|
||||
};
|
||||
};
|
||||
}
|
|
@ -1,4 +1,4 @@
|
|||
{ config, lib, ... }:
|
||||
{ config, pkgs, lib, ... }:
|
||||
|
||||
with lib;
|
||||
let
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
{ ... }:
|
||||
{ config, pkgs, ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
{ config, lib, ... }:
|
||||
{ config, pkgs, lib, ... }:
|
||||
|
||||
with lib;
|
||||
let
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
{ config, lib, ... }:
|
||||
{ config, pkgs, lib, ... }:
|
||||
|
||||
with lib;
|
||||
let
|
||||
|
@ -13,19 +13,14 @@ in
|
|||
config = mkIf cfg.enable {
|
||||
programs.git = {
|
||||
enable = true;
|
||||
lfs.enable = true;
|
||||
|
||||
userName = "Florian RICHER";
|
||||
userEmail = "florian.richer@protonmail.com";
|
||||
|
||||
signing = {
|
||||
signByDefault = true;
|
||||
key = "B19E3F4A2D806AB4793FDF2FC73D37CBED7BFC77";
|
||||
};
|
||||
# signing.signByDefault = true;
|
||||
|
||||
extraConfig = {
|
||||
url."https://invent.kde.org/".insteadOf = "kde:";
|
||||
url."ssh://git@invent.kde.org/".pushInsteadOf = "kde:";
|
||||
url."https://invent.kde.org/".insteadOf = "kde:";
|
||||
url."ssh://git@invent.kde.org/".pushInsteadOf = "kde:";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
|
|
@ -1,8 +0,0 @@
|
|||
{ ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
./flatpak
|
||||
./steam
|
||||
];
|
||||
}
|
|
@ -1,17 +0,0 @@
|
|||
{ config, lib, ... }:
|
||||
|
||||
with lib;
|
||||
let
|
||||
cfg = config.modules.system.apps.flatpak;
|
||||
in
|
||||
{
|
||||
options.modules.system.apps.flatpak = {
|
||||
enable = mkEnableOption ''
|
||||
Enable flatpak
|
||||
'';
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
services.flatpak.enable = true; # Important can't be enabled from home-manager
|
||||
};
|
||||
}
|
|
@ -1,22 +0,0 @@
|
|||
{ config, pkgs, lib, ... }:
|
||||
|
||||
with lib;
|
||||
let
|
||||
cfg = config.modules.system.apps.steam;
|
||||
in
|
||||
{
|
||||
options.modules.system.apps.steam = {
|
||||
enable = mkEnableOption ''
|
||||
Enable steam with my custom configurations
|
||||
'';
|
||||
};
|
||||
config = mkIf cfg.enable {
|
||||
programs.steam = {
|
||||
enable = true;
|
||||
extraPackages = with pkgs; [ gamescope ];
|
||||
extraCompatPackages = with pkgs; [ proton-ge-bin ];
|
||||
};
|
||||
|
||||
hardware.steam-hardware.enable = true;
|
||||
};
|
||||
}
|
|
@ -1,10 +1,6 @@
|
|||
{ pkgs, ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
../common.nix
|
||||
];
|
||||
|
||||
# Set your time zone.
|
||||
time.timeZone = "Europe/Paris";
|
||||
|
||||
|
@ -25,30 +21,12 @@
|
|||
|
||||
nixpkgs.config.allowUnfree = true;
|
||||
|
||||
services.udev.packages = [ pkgs.yubikey-personalization ];
|
||||
services.pcscd.enable = true;
|
||||
|
||||
programs.gnupg.agent = {
|
||||
enable = true;
|
||||
enableSSHSupport = true;
|
||||
};
|
||||
|
||||
# List packages installed in system profile. To search, run:
|
||||
# $ nix search wget
|
||||
environment.systemPackages = with pkgs; [
|
||||
vim
|
||||
nixd
|
||||
|
||||
# For debugging and troubleshooting Secure Boot.
|
||||
sbctl
|
||||
|
||||
# Usefull tools to debug
|
||||
gdb
|
||||
lldb
|
||||
gammaray # QT Inspector
|
||||
|
||||
yubikey-manager
|
||||
|
||||
# Usefull for automatic informations collect software like KDE
|
||||
vulkan-tools # For vulkaninfo command
|
||||
wayland-utils # For wayland-info command
|
||||
|
@ -68,9 +46,7 @@
|
|||
extraGroups = [ "networkmanager" "wheel" ];
|
||||
};
|
||||
|
||||
# Downloads and provides debug symbols and source code for nix derivations to gdb and other debuginfod-capable debuggers as needed.
|
||||
# Require https://github.com/symphorien/nixseparatedebuginfod?tab=readme-ov-file#gdb
|
||||
services.nixseparatedebuginfod.enable = true;
|
||||
services.flatpak.enable = true; # Important can't be enabled from home-manager
|
||||
|
||||
# networking.wireless.enable = true; # Enables wireless support via wpa_supplicant.
|
||||
|
||||
|
@ -96,5 +72,5 @@
|
|||
# this value at the release version of the first install of this system.
|
||||
# Before changing this value read the documentation for this option
|
||||
# (e.g. man configuration.nix or on https://nixos.org/nixos/options.html).
|
||||
system.stateVersion = "25.05"; # Did you read the comment?
|
||||
system.stateVersion = "24.05"; # Did you read the comment?
|
||||
}
|
||||
|
|
|
@ -1,8 +1,7 @@
|
|||
{ ... }:
|
||||
{ config, pkgs, ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
./apps
|
||||
./desktop
|
||||
./hardware
|
||||
./server
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
{ ... }:
|
||||
{ config, pkgs, ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
{ config, lib, ... }:
|
||||
{ config, pkgs, lib, ... }:
|
||||
|
||||
with lib;
|
||||
let
|
||||
|
@ -9,19 +9,13 @@ in
|
|||
enable = mkEnableOption ''
|
||||
Enable gnome with my custom configurations
|
||||
'';
|
||||
|
||||
enableGdm = mkOption {
|
||||
type = types.bool;
|
||||
description = "Enable gdm with custom gnome";
|
||||
default = true;
|
||||
};
|
||||
};
|
||||
config = mkIf cfg.enable {
|
||||
# Enable the X11 windowing system.
|
||||
services.xserver.enable = true;
|
||||
|
||||
# Enable the Gnome Desktop Environment.
|
||||
services.xserver.displayManager.gdm.enable = cfg.enableGdm;
|
||||
services.xserver.displayManager.gdm.enable = true;
|
||||
|
||||
# Enable the GNOME shell.
|
||||
services.xserver.desktopManager.gnome.enable = true;
|
||||
|
|
|
@ -3,26 +3,12 @@
|
|||
with lib;
|
||||
let
|
||||
cfg = config.modules.system.desktop.plasma;
|
||||
nixpkgsPr = builtins.fetchTarball {
|
||||
url = "https://github.com/Sicheng-Pan/nixpkgs/archive/5ba93319d81da028339755243fa405556a2b18d7.tar.gz";
|
||||
sha256 = "0xiighffwyhis6ni815s6bqcrvhsr3s7c208sq3c4y5p2f1g397w";
|
||||
};
|
||||
in
|
||||
{
|
||||
options.modules.system.desktop.plasma = {
|
||||
enable = mkEnableOption ''
|
||||
Enable plasma with my custom configurations
|
||||
'';
|
||||
|
||||
enableWallpaperEngine = mkEnableOption ''
|
||||
Enable wallpaper engine plugin for plasma
|
||||
'';
|
||||
|
||||
enableSddm = mkOption {
|
||||
type = types.bool;
|
||||
description = "Enable sddm with custom plasma";
|
||||
default = true;
|
||||
};
|
||||
};
|
||||
config = mkIf cfg.enable {
|
||||
# Enable the X11 windowing system.
|
||||
|
@ -30,7 +16,7 @@ in
|
|||
|
||||
# Enable the KDE Plasma Desktop Environment.
|
||||
services.displayManager = {
|
||||
sddm.enable = cfg.enableSddm;
|
||||
sddm.enable = true;
|
||||
defaultSession = "plasma";
|
||||
};
|
||||
services.desktopManager.plasma6.enable = true;
|
||||
|
@ -40,17 +26,6 @@ in
|
|||
environment.systemPackages = with pkgs; with kdePackages; [
|
||||
krfb # Use by kdeconnect for virtualmonitorplugin "krfb-virtualmonitor"
|
||||
discover
|
||||
kgpg
|
||||
yakuake
|
||||
] ++ lib.optionals cfg.enableWallpaperEngine [
|
||||
### wallpaper-engine-plugin
|
||||
(callPackage "${nixpkgsPr}/pkgs/kde/third-party/wallpaper-engine-plugin/default.nix" {})
|
||||
qtmultimedia
|
||||
qtwebchannel
|
||||
qtwebengine
|
||||
qtwebsockets
|
||||
(python3.withPackages (python-pkgs: [ python-pkgs.websockets ]))
|
||||
###
|
||||
];
|
||||
};
|
||||
}
|
||||
|
|
|
@ -5,6 +5,7 @@
|
|||
./bluetooth
|
||||
./gamingKernel
|
||||
./keymaps
|
||||
./nix-ld
|
||||
./nvidia
|
||||
./pipewire
|
||||
./plymouth
|
||||
|
|
31
modules/system/hardware/nix-ld/default.nix
Normal file
31
modules/system/hardware/nix-ld/default.nix
Normal file
|
@ -0,0 +1,31 @@
|
|||
{ config, pkgs, lib, ... }:
|
||||
|
||||
with lib;
|
||||
let
|
||||
cfg = config.modules.system.hardware.nix-ld;
|
||||
in
|
||||
{
|
||||
options.modules.system.hardware.nix-ld = {
|
||||
enable = mkEnableOption ''
|
||||
Enable nixLd with my custom configurations
|
||||
'';
|
||||
|
||||
enableKdeDevelopmentEnvironment = mkEnableOption ''
|
||||
Configure all required packages to develop with kde-builder
|
||||
'';
|
||||
};
|
||||
config = mkIf cfg.enable {
|
||||
# Enable nix ld
|
||||
programs.nix-ld.enable = true;
|
||||
|
||||
programs.nix-ld.package = pkgs.nix-ld-rs;
|
||||
|
||||
programs.nix-ld.libraries = [
|
||||
# Empty for now but used for default packages
|
||||
] ++ lib.optionals cfg.enableKdeDevelopmentEnvironment (import ./kde/libs.nix { inherit pkgs; });
|
||||
} // mkIf cfg.enableKdeDevelopmentEnvironment {
|
||||
environment.systemPackages = [
|
||||
(import ../../../../pkgs/kde-builder.nix { inherit pkgs; })
|
||||
] ++ (import ./kde/programs.nix { inherit pkgs; });
|
||||
};
|
||||
}
|
110
modules/system/hardware/nix-ld/kde/libs.nix
Normal file
110
modules/system/hardware/nix-ld/kde/libs.nix
Normal file
|
@ -0,0 +1,110 @@
|
|||
{ pkgs }:
|
||||
|
||||
with pkgs; [
|
||||
# From https://invent.kde.org/sysadmin/repo-metadata/-/blob/6ddda1e450fdbc093ca0138cf1c850e7b7e75044/distro-dependencies/arch.ini
|
||||
|
||||
# Qt-related
|
||||
kdePackages.accounts-qt
|
||||
|
||||
libdbusmenu
|
||||
packagekit
|
||||
kdePackages.qtbase
|
||||
kdePackages.qttools
|
||||
kdePackages.qtdeclarative
|
||||
kdePackages.phonon
|
||||
kdePackages.poppler
|
||||
kdePackages.qca
|
||||
kdePackages.qcoro
|
||||
kdePackages.qtkeychain
|
||||
|
||||
# Others/Unsorted
|
||||
black-hole-solver
|
||||
check
|
||||
eigen
|
||||
enchant
|
||||
exiv2
|
||||
flatpak
|
||||
fluidsynth
|
||||
freecell-solver
|
||||
giflib
|
||||
itstool
|
||||
jasper
|
||||
kdePackages.kdsoap # QT6
|
||||
libcanberra
|
||||
libdisplay-info
|
||||
libdmtx
|
||||
libfakekey
|
||||
libgit2
|
||||
libical
|
||||
olm
|
||||
libpwquality
|
||||
libqalculate
|
||||
libraw
|
||||
libutempter
|
||||
xorg.libxcvt
|
||||
expat
|
||||
libxml2
|
||||
xorg.libX11 xorg.libXext xorg.libXft xorg.libXpm xorg.libXrandr xorg.libXScrnSaver # Replacement of libxss ?
|
||||
lmdb
|
||||
microsoft-gsl
|
||||
mlt
|
||||
mpv
|
||||
networkmanager
|
||||
openal
|
||||
openexr
|
||||
plymouth
|
||||
power-profiles-daemon
|
||||
kdePackages.qgpgme # qt6
|
||||
qrencode
|
||||
# ruby-sass
|
||||
# ruby-test-unit
|
||||
# sane
|
||||
sccache
|
||||
shared-mime-info
|
||||
kdePackages.signond
|
||||
udisks2
|
||||
upower
|
||||
vala
|
||||
vlc
|
||||
wayland
|
||||
wayland-protocols
|
||||
wayland-scanner
|
||||
xapian
|
||||
xercesc
|
||||
xorg.xf86inputlibinput
|
||||
xf86_input_wacom
|
||||
xmlto
|
||||
xorg.xorgserver
|
||||
xsd
|
||||
zxing-cpp
|
||||
gtk3
|
||||
|
||||
# plasma-desktop
|
||||
xdotool
|
||||
|
||||
# appstream
|
||||
gobject-introspection
|
||||
xorg.xf86inputevdev
|
||||
|
||||
# okular
|
||||
discount
|
||||
djvulibre
|
||||
ebook_tools
|
||||
libspectre
|
||||
libzip
|
||||
|
||||
(pkgs.python3.withPackages (python-pkgs: with python-pkgs; [
|
||||
pycairo
|
||||
pip
|
||||
setuptools
|
||||
sphinx
|
||||
|
||||
# drkonqi
|
||||
psutil
|
||||
pygdbmi
|
||||
sentry-sdk
|
||||
]))
|
||||
|
||||
# kpipewire
|
||||
pipewire
|
||||
] ++ (import ./programs.nix { inherit pkgs; })
|
33
modules/system/hardware/nix-ld/kde/programs.nix
Normal file
33
modules/system/hardware/nix-ld/kde/programs.nix
Normal file
|
@ -0,0 +1,33 @@
|
|||
{ pkgs }:
|
||||
|
||||
with pkgs; [
|
||||
# .. gnu
|
||||
autoconf
|
||||
automake
|
||||
bison
|
||||
flex
|
||||
gcc
|
||||
gperf
|
||||
gnumake
|
||||
texinfo
|
||||
|
||||
# .. llvm
|
||||
clang
|
||||
cmake
|
||||
|
||||
# .. build systems
|
||||
meson
|
||||
ninja
|
||||
|
||||
# .. rust
|
||||
corrosion
|
||||
|
||||
# .. others
|
||||
boost
|
||||
docbook_xsl
|
||||
doxygen
|
||||
gi-docgen
|
||||
git
|
||||
intltool
|
||||
pkg-config
|
||||
]
|
|
@ -11,51 +11,41 @@ in
|
|||
'';
|
||||
};
|
||||
config = mkIf cfg.enable {
|
||||
# Enable OpenGL
|
||||
hardware.opengl = {
|
||||
enable = true;
|
||||
driSupport = true;
|
||||
driSupport32Bit = true;
|
||||
};
|
||||
|
||||
# Load nvidia driver for Xorg and Wayland
|
||||
services.xserver.videoDrivers = ["nvidia"];
|
||||
|
||||
hardware = {
|
||||
graphics = {
|
||||
enable = true;
|
||||
enable32Bit = true;
|
||||
};
|
||||
hardware.nvidia = {
|
||||
# Modesetting is required.
|
||||
modesetting.enable = true;
|
||||
|
||||
nvidia-container-toolkit.enable = true;
|
||||
# Nvidia power management. Experimental, and can cause sleep/suspend to fail.
|
||||
powerManagement.enable = false;
|
||||
# Fine-grained power management. Turns off GPU when not in use.
|
||||
# Experimental and only works on modern Nvidia GPUs (Turing or newer).
|
||||
powerManagement.finegrained = false;
|
||||
|
||||
nvidia = {
|
||||
# Modesetting is required.
|
||||
modesetting.enable = true;
|
||||
# Use the NVidia open source kernel module (not to be confused with the
|
||||
# independent third-party "nouveau" open source driver).
|
||||
# Support is limited to the Turing and later architectures. Full list of
|
||||
# supported GPUs is at:
|
||||
# https://github.com/NVIDIA/open-gpu-kernel-modules#compatible-gpus
|
||||
# Only available from driver 515.43.04+
|
||||
# Currently alpha-quality/buggy, so false is currently the recommended setting.
|
||||
open = false;
|
||||
|
||||
# Nvidia power management. Experimental, and can cause sleep/suspend to fail.
|
||||
# Enable this if you have graphical corruption issues or application crashes after waking
|
||||
# up from sleep. This fixes it by saving the entire VRAM memory to /tmp/ instead
|
||||
# of just the bare essentials.
|
||||
powerManagement.enable = true;
|
||||
# Enable the Nvidia settings menu,
|
||||
# accessible via `nvidia-settings`.
|
||||
nvidiaSettings = true;
|
||||
|
||||
# Fine-grained power management. Turns off GPU when not in use.
|
||||
# Experimental and only works on modern Nvidia GPUs (Turing or newer).
|
||||
powerManagement.finegrained = false;
|
||||
|
||||
# Use the NVidia open source kernel module (not to be confused with the
|
||||
# independent third-party "nouveau" open source driver).
|
||||
# Support is limited to the Turing and later architectures. Full list of
|
||||
# supported GPUs is at:
|
||||
# https://github.com/NVIDIA/open-gpu-kernel-modules#compatible-gpus
|
||||
# Only available from driver 515.43.04+
|
||||
# Currently alpha-quality/buggy, so false is currently the recommended setting.
|
||||
open = true;
|
||||
|
||||
# Enable the Nvidia settings menu,
|
||||
# accessible via `nvidia-settings`.
|
||||
nvidiaSettings = true;
|
||||
|
||||
# Optionally, you may need to select the appropriate driver version for your specific GPU.
|
||||
package = config.boot.kernelPackages.nvidiaPackages.latest;
|
||||
};
|
||||
# Optionally, you may need to select the appropriate driver version for your specific GPU.
|
||||
package = config.boot.kernelPackages.nvidiaPackages.beta;
|
||||
};
|
||||
|
||||
# boot.extraModprobeConfig = ''
|
||||
# options nvidia NVreg_EnableGpuFirmware=0
|
||||
# '';
|
||||
};
|
||||
}
|
||||
}
|
|
@ -12,6 +12,7 @@ in
|
|||
};
|
||||
config = mkIf cfg.enable {
|
||||
# Enable sound with pipewire.
|
||||
sound.enable = true;
|
||||
hardware.pulseaudio.enable = false;
|
||||
security.rtkit.enable = true;
|
||||
services.pipewire = {
|
||||
|
@ -27,4 +28,4 @@ in
|
|||
#media-session.enable = true;
|
||||
};
|
||||
};
|
||||
}
|
||||
}
|
|
@ -1,4 +1,4 @@
|
|||
{ config, lib, ... }:
|
||||
{ config, pkgs, lib, ... }:
|
||||
|
||||
with lib;
|
||||
let
|
||||
|
|
|
@ -1,8 +1,7 @@
|
|||
{ ... }:
|
||||
{ config, pkgs, ... }:
|
||||
|
||||
{
|
||||
imports = [
|
||||
./distrobox
|
||||
./docker
|
||||
./ollama
|
||||
./openssh
|
||||
|
|
|
@ -1,17 +0,0 @@
|
|||
{ config, pkgs, lib, ... }:
|
||||
|
||||
with lib;
|
||||
let
|
||||
cfg = config.modules.system.server.distrobox;
|
||||
in
|
||||
{
|
||||
options.modules.system.server.distrobox = {
|
||||
enable = mkEnableOption ''
|
||||
Enable distrobox with my custom configurations
|
||||
'';
|
||||
};
|
||||
config = mkIf cfg.enable {
|
||||
modules.system.server.docker.enable = true;
|
||||
environment.systemPackages = with pkgs; [ distrobox ];
|
||||
};
|
||||
}
|
|
@ -1,4 +1,4 @@
|
|||
{ config, lib, ... }:
|
||||
{ config, pkgs, lib, ... }:
|
||||
|
||||
with lib;
|
||||
let
|
||||
|
@ -13,9 +13,7 @@ in
|
|||
config = mkIf cfg.enable {
|
||||
virtualisation.docker = {
|
||||
enable = true;
|
||||
enableNvidia = config.modules.system.hardware.nvidia.enable;
|
||||
};
|
||||
virtualisation.oci-containers.backend = "docker";
|
||||
|
||||
users.users.florian.extraGroups = [ "docker" ];
|
||||
};
|
||||
}
|
|
@ -1,4 +1,4 @@
|
|||
{ config, lib, ... }:
|
||||
{ config, pkgs, lib, ... }:
|
||||
|
||||
with lib;
|
||||
let
|
||||
|
@ -18,4 +18,4 @@ in
|
|||
acceleration = if nvidiaEnabled then "cuda" else null;
|
||||
};
|
||||
};
|
||||
}
|
||||
}
|
|
@ -1,4 +1,4 @@
|
|||
{ config, lib, ... }:
|
||||
{ config, pkgs, lib, ... }:
|
||||
|
||||
with lib;
|
||||
let
|
||||
|
|
0
pkgs/.gitkeep
Normal file
0
pkgs/.gitkeep
Normal file
31
pkgs/kde-builder.nix
Normal file
31
pkgs/kde-builder.nix
Normal file
|
@ -0,0 +1,31 @@
|
|||
{
|
||||
pkgs
|
||||
}:
|
||||
|
||||
with pkgs;
|
||||
stdenv.mkDerivation rec {
|
||||
pname = "kde-builder";
|
||||
version = "50a5c745e5bc6a47779abc4e441e6a13749d9f67";
|
||||
|
||||
src = fetchFromGitLab {
|
||||
domain = "invent.kde.org";
|
||||
owner = "sdk";
|
||||
repo = "kde-builder";
|
||||
rev = version;
|
||||
sha256 = "l3V9EyiOZXKMUuUvlX8awWbHiaufc9XjNhdPb1YnaKw=";
|
||||
};
|
||||
|
||||
# https://invent.kde.org/sdk/kde-builder/-/blob/45eaedd70d39059a2fa94f4774b9c0642d02ec21/scripts/initial_setup.sh#L23
|
||||
buildInputs = [
|
||||
(pkgs.python3.withPackages (python-pkgs: with python-pkgs; [
|
||||
dbus-python
|
||||
pyyaml
|
||||
setproctitle
|
||||
]))
|
||||
];
|
||||
|
||||
installPhase = ''
|
||||
mkdir -p $out/bin
|
||||
cp -r * $out/bin/
|
||||
'';
|
||||
}
|
|
@ -1,6 +0,0 @@
|
|||
# Tips: Home
|
||||
|
||||
- [Debug insecure package error](./debug_insecure_package.md)
|
||||
- [How try pull request](./how_to_test_pr.md)
|
||||
- [Build and run VM from nixos configuration](./test_on_vm.md)
|
||||
- [Home Manager on others distros](./home_manager.md)
|
|
@ -1,30 +0,0 @@
|
|||
## If package is marked as insecure
|
||||
|
||||
Example:
|
||||
|
||||
> error: Package 'nix-2.16.2' in /nix/store/nra828scc8qs92b9pxra5csqzffb6hpl-source/pkgs/tools/package-management/nix/default.nix:229 is marked as insecure, refusing to evaluate.
|
||||
>
|
||||
> Known issues:
|
||||
> - CVE-2024-27297
|
||||
|
||||
```bash
|
||||
nix path-info -r /run/current-system | grep nix-2.16.2
|
||||
```
|
||||
Result:
|
||||
> [...]
|
||||
>
|
||||
> /nix/store/g4ss2h40n3j37bq20x1qw5s7nl82lch5-nix-2.16.2
|
||||
>
|
||||
> [...]
|
||||
|
||||
```bash
|
||||
nix-store -q --referrers /nix/store/g4ss2h40n3j37bq20x1qw5s7nl82lch5-nix-2.16.2
|
||||
```
|
||||
Result:
|
||||
> /nix/store/g4ss2h40n3j37bq20x1qw5s7nl82lch5-nix-2.16.2
|
||||
>
|
||||
> /nix/store/72pfc05339izcwqhlbs8441brrdasas7-nix-2.16.2-dev
|
||||
>
|
||||
> /nix/store/ln2z5d5izn8icm3wx94ci13ad19lzjhr-nixd-1.2.3
|
||||
|
||||
nixd is not up to date and require nix 2.16.2
|
|
@ -1,24 +0,0 @@
|
|||
# Required for kde-builder command
|
||||
if [[ $PATH != *".local/bin"* ]]; then
|
||||
export PATH="$HOME/.local/bin:$PATH"
|
||||
fi
|
||||
|
||||
# Workaround for NixOS
|
||||
# ENVs have nix store references and made conflict during build or run of KDE Apps, Shells, Frameworks
|
||||
alias new_shell="env -u PATH -u QML2_IMPORT_PATH -u QT_PLUGIN_PATH -u NIXPKGS_QT6_QML_IMPORT_PATH -u XDG_CONFIG_DIRS bash -l"
|
||||
|
||||
alias build_plasma_mobile="kde-builder plasma-mobile plasma-settings plasma-desktop kactivitymanagerd"
|
||||
|
||||
function run_mobile() {
|
||||
source "$HOME/kde/build/plasma-mobile/prefix.sh"
|
||||
|
||||
QT_QPA_PLATFORM=offscreen plasma-mobile-envmanager --apply-settings
|
||||
|
||||
# Environment variables
|
||||
export QT_WAYLAND_DISABLE_WINDOWDECORATION=1
|
||||
export QT_QUICK_CONTROLS_MOBILE=1
|
||||
export PLASMA_PLATFORM=phone:handheld
|
||||
export QT_QUICK_CONTROLS_STYLE=org.kde.breeze
|
||||
|
||||
QT_QPA_PLATFORM=wayland dbus-run-session kwin_wayland --xwayland "plasmashell -p org.kde.plasma.mobileshell" --width 360 --height 720
|
||||
}
|
|
@ -1,20 +0,0 @@
|
|||
#!/bin/bash
|
||||
|
||||
if ! grep -Fxq "source ~/.kde_bashrc" ~/.bashrc
|
||||
then
|
||||
cp .kde_bashrc ~/.kde_bashrc
|
||||
echo "source ~/.kde_bashrc" > ~/.bashrc
|
||||
source ~/.bashrc
|
||||
fi
|
||||
|
||||
echo "Installing kde-builder"
|
||||
curl 'https://invent.kde.org/sdk/kde-builder/-/raw/master/scripts/initial_setup.sh?ref_type=heads' > ~/initial_setup.sh
|
||||
bash ~/initial_setup.sh && rm ~/initial_setup.sh
|
||||
|
||||
echo "Run initial setup from kde-builder"
|
||||
kde-builder --initial-setup
|
||||
|
||||
echo "Install missing dependencies"
|
||||
sudo dnf install qt6-*-devel librsvg2-devel
|
||||
|
||||
echo "Configuration DONE"
|
|
@ -1,6 +0,0 @@
|
|||
[kdedev]
|
||||
image=quay.io/fedora/fedora:latest
|
||||
home="${HOME}/.distrobox_home/kdedev"
|
||||
nvidia=true
|
||||
root=false
|
||||
pull=true
|
|
@ -1,19 +0,0 @@
|
|||
# How to develop on KDE
|
||||
|
||||
## First configuration
|
||||
|
||||
1. `distrobox assemble`
|
||||
> You can add --replace to recreate distrobox container
|
||||
2. `distrobox enter kdedev`
|
||||
3. `bash configure.sh`
|
||||
4. `kde-builder run solid`
|
||||
> You use NixOS ? It's necessary to run `new_shell` alias before.
|
||||
> The alias unset all nixos env variables with nix store references to avoid conflicts with build or run of KDE Shells/Apps/Tools.
|
||||
|
||||
## Usefull config in ~/.config/kdesrc-buildrc
|
||||
|
||||
Autogenerate editor configuration
|
||||
|
||||
- generate-clion-project-config
|
||||
- generate-vscode-project-config
|
||||
- generate-qtcreator-project-config
|
|
@ -1,32 +0,0 @@
|
|||
# Home Manager on others distros
|
||||
|
||||
## Install home-manager
|
||||
|
||||
1. Add `nixpkgs` and `home-manager` channels
|
||||
|
||||
```bash
|
||||
nix-channel --add https://nixos.org/channels/nixpkgs-unstable
|
||||
nix-channel --add https://github.com/nix-community/home-manager/archive/master.tar.gz home-manager
|
||||
nix-channel --update
|
||||
```
|
||||
|
||||
2. Install `home-manager`
|
||||
|
||||
```bash
|
||||
export NIX_PATH=$HOME/.nix-defexpr/channels:/nix/var/nix/profiles/per-user/root/channels${NIX_PATH:+:$NIX_PATH}
|
||||
nix-shell '<home-manager>' -A install
|
||||
```
|
||||
|
||||
## How use home-manager
|
||||
|
||||
1. Switch
|
||||
|
||||
```bash
|
||||
home-manager switch --flake .#perso-home
|
||||
```
|
||||
|
||||
2. List generations
|
||||
|
||||
```bash
|
||||
home-manager generations
|
||||
```
|
|
@ -1,36 +0,0 @@
|
|||
# Example for ollama
|
||||
|
||||
```nix
|
||||
{ config, pkgs, lib, ... }:
|
||||
|
||||
with lib;
|
||||
let
|
||||
cfg = config.modules.system.server.ollama;
|
||||
nvidiaEnabled = config.modules.system.hardware.nvidia.enable;
|
||||
nixpkgsPr = builtins.fetchTarball {
|
||||
url = "https://github.com/abysssol/nixpkgs/archive/ollama-driver-runpath.tar.gz";
|
||||
sha256 = "1ixfvdpi2v4r9yrkvqnfk9whs8lyjhrkdph47bcznh8ak9aipr8p";
|
||||
};
|
||||
in
|
||||
{
|
||||
disabledModules = [ "services/misc/ollama.nix" ];
|
||||
imports = [
|
||||
(import "${nixpkgsPr}/nixos/modules/services/misc/ollama.nix")
|
||||
];
|
||||
|
||||
options.modules.system.server.ollama = {
|
||||
enable = mkEnableOption ''
|
||||
Enable ollama with my custom configurations
|
||||
'';
|
||||
};
|
||||
config = mkIf cfg.enable {
|
||||
services.ollama = {
|
||||
enable = true;
|
||||
|
||||
package = (import nixpkgsPr { inherit (pkgs) system; config.allowUnfree = true; }).ollama;
|
||||
|
||||
acceleration = if nvidiaEnabled then "cuda" else null;
|
||||
};
|
||||
};
|
||||
}
|
||||
```
|
|
@ -1,24 +0,0 @@
|
|||
## Configure VM
|
||||
|
||||
Configure VM
|
||||
```nix
|
||||
users.users.<user>.initialPassword = "<password>";
|
||||
virtualisation.vmVariant = {
|
||||
# following configuration is added only when building VM with build-vm
|
||||
virtualisation = {
|
||||
memorySize = <RAM in MiB>; # Use 8192MiB memory.
|
||||
cores = <CPU Core number>;
|
||||
# And more here https://github.com/NixOS/nixpkgs/blob/nixos-unstable/nixos/modules/virtualisation/qemu-vm.nix
|
||||
};
|
||||
};
|
||||
```
|
||||
|
||||
Build
|
||||
```bash
|
||||
nixos-rebuild build-vm --flake .#nixos-test
|
||||
```
|
||||
|
||||
Run
|
||||
```bash
|
||||
./result/bin/run-nixos-vm-vm
|
||||
```
|
Loading…
Reference in a new issue