summaryrefslogtreecommitdiff
path: root/modules/root
diff options
context:
space:
mode:
Diffstat (limited to 'modules/root')
-rw-r--r--modules/root/autologin.nix13
-rw-r--r--modules/root/awesome.nix28
-rw-r--r--modules/root/default.nix3
-rw-r--r--modules/root/normaluser.nix2
-rw-r--r--modules/root/powerkeys.nix7
-rw-r--r--modules/root/software.nix1
6 files changed, 51 insertions, 3 deletions
diff --git a/modules/root/autologin.nix b/modules/root/autologin.nix
new file mode 100644
index 0000000..6e66160
--- /dev/null
+++ b/modules/root/autologin.nix
@@ -0,0 +1,13 @@
+{ lib, config, userDetails, ... }: {
+ options = {
+ autologin.enable = lib.mkEnableOption "enables getty automatic login";
+ #autologin.user = lib.mkEnableOption "populate username";
+ #autologin.password = lib.mkEnableOption "populate password";
+ };
+
+ config = lib.mkIf config.autologin.enable {
+ services.getty = {
+ autologinUser = userDetails.username;
+ };
+ };
+}
diff --git a/modules/root/awesome.nix b/modules/root/awesome.nix
index 4db5230..af1318f 100644
--- a/modules/root/awesome.nix
+++ b/modules/root/awesome.nix
@@ -1,9 +1,33 @@
-{ lib, config, ... }: {
+{ nixpkgs, pkgs, lib, config, ... }: {
options = {
xserver.awesome.enable = lib.mkEnableOption "enables awesomewm";
};
config = lib.mkIf config.xserver.awesome.enable {
- services.xserver.windowManager.awesome.enable = true;
+ services.xserver.windowManager.awesome = {
+ enable = true;
+ noArgb = true; # disables transparency. why not?
+ luaModules = with pkgs; [
+ luajitPackages.lgi
+ ];
+ };
+
+ #getLuaPath = lib: dir: "${lib}/${dir}/lua/${pkgs.luajit.luaversion}";
+ #makeSearchPath = lib.concatMapStrings (
+ # path:
+ # " --search "
+ # + (getLuaPath path "share")
+ # + " --search "
+ # + (getLuaPath path "lib")
+ #);
+
+
+ environment.systemPackages = with pkgs; [
+ (awesome.override {
+ gtk3Support = true;
+ gtk3 = gtk3;
+ lua = luajit;
+ })
+ ];
};
}
diff --git a/modules/root/default.nix b/modules/root/default.nix
index b03fab4..2ef73aa 100644
--- a/modules/root/default.nix
+++ b/modules/root/default.nix
@@ -1,5 +1,6 @@
{ lib, ... }: {
imports = [
+ ./autologin.nix
./awesome.nix
./cups.nix
./doas.nix
@@ -11,12 +12,14 @@
./nix.nix
./normaluser.nix
./pipewire.nix
+ ./powerkeys.nix
./software.nix
./virtualisation.nix
./wifi.nix
./x11.nix
];
+ autologin.enable = lib.mkDefault true;
cups.enable = lib.mkDefault true;
doas.enable = lib.mkDefault true;
docker = {
diff --git a/modules/root/normaluser.nix b/modules/root/normaluser.nix
index 5d436e8..192e64e 100644
--- a/modules/root/normaluser.nix
+++ b/modules/root/normaluser.nix
@@ -1,7 +1,7 @@
{ userDetails, ... }: {
users.users.${userDetails.username} = {
description = userDetails.fullname;
- home = userDetails.home.root;
+ #home = userDetails.home.root;
isNormalUser = true;
extraGroups = [ "wheel" ];
};
diff --git a/modules/root/powerkeys.nix b/modules/root/powerkeys.nix
new file mode 100644
index 0000000..dcb3616
--- /dev/null
+++ b/modules/root/powerkeys.nix
@@ -0,0 +1,7 @@
+{
+ services.logind = {
+ powerKey = "ignore";
+ powerKeyLongPress = "poweroff";
+ hibernateKey = "suspend";
+ };
+}
diff --git a/modules/root/software.nix b/modules/root/software.nix
index 4aa6f64..f52f25c 100644
--- a/modules/root/software.nix
+++ b/modules/root/software.nix
@@ -35,6 +35,7 @@
inkscape
qbittorrent
qdirstat
+ thunderbird
ungoogled-chromium
] ++ pkgs.lib.optionals config.software.dev.enable [
# Development