major rewrite
This commit is contained in:
parent
47a79eea64
commit
4adf705a13
20 changed files with 50 additions and 294 deletions
|
@ -35,6 +35,9 @@ in {
|
|||
|
||||
# systemd-nspawn containers
|
||||
# ./containers.nix
|
||||
|
||||
# monitor configuration
|
||||
./monitors.nix
|
||||
];
|
||||
config = {
|
||||
warnings = mkMerge [
|
||||
|
@ -89,6 +92,8 @@ in {
|
|||
|
||||
video = {
|
||||
enable = mkEnableOption "video drivers and programs that require a graphical user interface";
|
||||
nvidia = mkOption "Nvidia graphics drivers";
|
||||
amd = mkOption "AMD graphics drivers";
|
||||
};
|
||||
|
||||
bluetooth = {
|
||||
|
|
71
modules/options/system/monitors.nix
Normal file
71
modules/options/system/monitors.nix
Normal file
|
@ -0,0 +1,71 @@
|
|||
{lib, ...}:
|
||||
with lib; {
|
||||
options.modules.other.system.monitors = mkOption {
|
||||
description = "\n List of monitors to use\n ";
|
||||
default = [];
|
||||
type = with types;
|
||||
types.listOf (submodule {
|
||||
options = {
|
||||
name = mkOption {
|
||||
type = types.str;
|
||||
description = "Give your monitor a cute name";
|
||||
default = "monitor0(I am lazy)";
|
||||
};
|
||||
device = mkOption {
|
||||
type = types.str;
|
||||
description = "The actual device name of the monitor";
|
||||
};
|
||||
resolution = mkOption {
|
||||
type = types.submodule {
|
||||
options = {
|
||||
x = mkOption {
|
||||
type = types.int;
|
||||
description = "monitor width";
|
||||
default = "1920";
|
||||
};
|
||||
y = mkOption {
|
||||
type = types.int;
|
||||
description = "monitor height";
|
||||
default = "1080";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
scale = mkOption {
|
||||
type = types.number;
|
||||
description = "monitor scale";
|
||||
default = 1.0;
|
||||
};
|
||||
refresh_rate = mkOption {
|
||||
type = types.int;
|
||||
description = "monitor refresh rate (in Hz)";
|
||||
default = 60;
|
||||
};
|
||||
position = mkOption {
|
||||
type = types.submodule {
|
||||
options = {
|
||||
x = mkOption {
|
||||
type = types.int;
|
||||
default = 0;
|
||||
};
|
||||
y = mkOption {
|
||||
type = types.int;
|
||||
default = 0;
|
||||
};
|
||||
};
|
||||
};
|
||||
description = "absolute monitor posititon";
|
||||
default = {
|
||||
x = 0;
|
||||
y = 0;
|
||||
};
|
||||
};
|
||||
transform = mkOption {
|
||||
type = types.ints.between 0 3;
|
||||
description = "Rotation of the monitor counterclockwise";
|
||||
default = 0;
|
||||
};
|
||||
};
|
||||
});
|
||||
};
|
||||
}
|
0
modules/system/hardware/sound/default.nix
Normal file
0
modules/system/hardware/sound/default.nix
Normal file
19
modules/system/hardware/sound/pipewire/default.nix
Normal file
19
modules/system/hardware/sound/pipewire/default.nix
Normal file
|
@ -0,0 +1,19 @@
|
|||
{
|
||||
config,
|
||||
lib,
|
||||
...
|
||||
}: let
|
||||
inherit (config.modules.system.hardware.sound) pipewire;
|
||||
inherit (lib) mkIf;
|
||||
in {
|
||||
config = mkIf pipewire.enable {
|
||||
services.pipewire = {
|
||||
enable = true;
|
||||
audio.enable = true;
|
||||
|
||||
pulse.enable = true;
|
||||
jack.enable = true;
|
||||
alsa.enable = true;
|
||||
};
|
||||
};
|
||||
}
|
|
@ -7,6 +7,7 @@
|
|||
imports = [
|
||||
./documentation.nix # nixos documentation
|
||||
./nixpkgs.nix # global nixpkgs configuration.nix
|
||||
./registry.nix
|
||||
];
|
||||
|
||||
nix = {
|
||||
|
|
22
modules/system/nix/registry.nix
Normal file
22
modules/system/nix/registry.nix
Normal file
|
@ -0,0 +1,22 @@
|
|||
{
|
||||
inputs,
|
||||
pkgs,
|
||||
...
|
||||
}: let
|
||||
inherit (inputs) nixpkgs;
|
||||
nixpkgsPath = nixpkgs.outPath;
|
||||
in {
|
||||
# Big thanks to Dianimo for this!
|
||||
nix = {
|
||||
registry = {
|
||||
nixpkgs.flake = inputs.nixpkgs;
|
||||
default.flake = inputs.nixpkgs;
|
||||
};
|
||||
|
||||
nixPath = [
|
||||
"nixpkgs=${nixpkgsPath}"
|
||||
"n=${nixpkgsPath}"
|
||||
"default=${nixpkgsPath}"
|
||||
];
|
||||
};
|
||||
}
|
|
@ -46,7 +46,7 @@ in {
|
|||
home-manager.users.${username} = {
|
||||
wayland.windowManager.hyprland = {
|
||||
enable = true;
|
||||
# inherit (cfg) package;
|
||||
inherit (cfg) package;
|
||||
|
||||
# Split-monitor-workspaces provides awesome-like workspace behaviour
|
||||
plugins = [
|
||||
|
|
0
modules/wms/wayland/hyprland/binds.nix
Normal file
0
modules/wms/wayland/hyprland/binds.nix
Normal file
0
modules/wms/wayland/hyprland/decorations.nix
Normal file
0
modules/wms/wayland/hyprland/decorations.nix
Normal file
0
modules/wms/wayland/hyprland/exec.nix
Normal file
0
modules/wms/wayland/hyprland/exec.nix
Normal file
0
modules/wms/wayland/hyprland/module.nix
Normal file
0
modules/wms/wayland/hyprland/module.nix
Normal file
0
modules/wms/wayland/hyprland/settings.nix
Normal file
0
modules/wms/wayland/hyprland/settings.nix
Normal file
Loading…
Add table
Add a link
Reference in a new issue