refactor: change to litterate config

Configuration is now held by the `.org` files. All `.nix` files are
tangled from the org-mode files.
This commit is contained in:
2026-10-06 12:40:58 +02:00
parent 5f4a7a4a42
commit ba018ef841
62 changed files with 2374 additions and 519 deletions
+4 -12
View File
@@ -1,16 +1,8 @@
{
flake.modules.nixos.appimage = {
lib,
config,
...
}:
with lib; let
cfg = config.mySystem.packages.appimage;
in {
options.mySystem.packages.appimage.enable = mkEnableOption "Enables AppImage support";
config.programs.appimage = mkIf cfg.enable {
inherit (cfg) enable;
binfmt = true;
};
programs.appimage = {
enable = true;
binfmt = true;
};
};
}
+24
View File
@@ -0,0 +1,24 @@
#+title: AppImage
#+setupfile: ../headers
* AppImage
A small module to let AppImages run directly, without having to
extract or wrap them by hand first. Here’s the =nixos.appimage= module.
#+begin_src nix :tangle yes
{
flake.modules.nixos.appimage = {
<<enable-appimage>>
};
}
#+end_src
=binfmt= registers AppImages with the kernel’s =binfmt_misc=, so running
one is as simple as executing it directly, the same as any other
binary.
#+name: enable-appimage
#+begin_src nix
programs.appimage = {
enable = true;
binfmt = true;
};
#+end_src
+2 -5
View File
@@ -8,11 +8,8 @@
with lib; let
cfg = config.mySystem.packages.flatpak;
in {
options.mySystem.packages.flatpak = {
enable = mkEnableOption "Enable Flatpak support";
builder.enable = mkEnableOption "Enable Flatpak builder";
};
config = mkIf cfg.enable {
options.mySystem.packages.flatpak.builder.enable = mkEnableOption "Enable Flatpak builder";
config = {
environment.systemPackages = lists.optional cfg.builder.enable pkgs.flatpak-builder;
services.flatpak.enable = true;
};