/nix/store/dlwqlnbaj5vfm9aw20r1yxk8y56lmgif-repo/header.tmpl
15 changed files with
65 additions and
289 deletions
|
|
|
@ -25,6 +25,7 @@
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
modules = {
|
|
|
|
|
desktops.hyprland.enable = true;
|
|
|
|
|
system = {
|
|
|
|
|
impermanence.enable = false;
|
|
|
|
|
services = {
|
|
|
|
@ -58,28 +59,12 @@
|
|
|
|
|
};
|
|
|
|
|
sound.enable = true;
|
|
|
|
|
};
|
|
|
|
|
usrEnv = {
|
|
|
|
|
desktops.hyprland.enable = false;
|
|
|
|
|
services = {
|
|
|
|
|
locate.enable = true;
|
|
|
|
|
|
|
|
|
|
programs = {
|
|
|
|
|
launchers = {
|
|
|
|
|
fuzzel.enable = true;
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
media = {
|
|
|
|
|
beets.enable = true;
|
|
|
|
|
mpv.enable = true;
|
|
|
|
|
ncmpcpp.enable = true;
|
|
|
|
|
};
|
|
|
|
|
media.mpd = {
|
|
|
|
|
enable = true;
|
|
|
|
|
};
|
|
|
|
|
services = {
|
|
|
|
|
locate.enable = true;
|
|
|
|
|
|
|
|
|
|
media.mpd = {
|
|
|
|
|
enable = true;
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
};
|
|
|
|
|
other = {
|
|
|
|
|
system.username = "cr";
|
|
|
|
|
|
|
|
@ -70,25 +70,13 @@ in {
|
|
|
|
|
sound.enable = true;
|
|
|
|
|
hardware.nvidia.enable = true;
|
|
|
|
|
};
|
|
|
|
|
usrEnv = {
|
|
|
|
|
desktops.hyprland.enable = true;
|
|
|
|
|
desktops.hyprland.enable = true;
|
|
|
|
|
|
|
|
|
|
programs = {
|
|
|
|
|
media = {
|
|
|
|
|
beets.enable = true;
|
|
|
|
|
mpv.enable = true;
|
|
|
|
|
ncmpcpp.enable = true;
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
services = {
|
|
|
|
|
locate.enable = true;
|
|
|
|
|
kmscon.enable = false;
|
|
|
|
|
greetd.enable = true;
|
|
|
|
|
|
|
|
|
|
media.mpd = {
|
|
|
|
|
enable = true;
|
|
|
|
|
musicDirectory = "/home/${config.modules.other.system.username}/cloud/media/Music";
|
|
|
|
|
};
|
|
|
|
|
services = {
|
|
|
|
|
locate.enable = true;
|
|
|
|
|
media.mpd = {
|
|
|
|
|
enable = true;
|
|
|
|
|
musicDirectory = "/home/${config.modules.other.system.username}/cloud/media/Music";
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
other = {
|
|
|
|
|
|
|
|
@ -25,6 +25,9 @@
|
|
|
|
|
mainUser.gitSigningKey = "";
|
|
|
|
|
};
|
|
|
|
|
modules = {
|
|
|
|
|
services = {
|
|
|
|
|
locate.enable = true;
|
|
|
|
|
};
|
|
|
|
|
system = {
|
|
|
|
|
services.forgejo.enable = true;
|
|
|
|
|
programs = {
|
|
|
|
@ -34,13 +37,6 @@
|
|
|
|
|
eza.enable = true;
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
usrEnv = {
|
|
|
|
|
desktops.hyprland.enable = false;
|
|
|
|
|
|
|
|
|
|
services = {
|
|
|
|
|
locate.enable = true;
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
other = {
|
|
|
|
|
system = {
|
|
|
|
|
username = "cr";
|
|
|
|
|
|
|
|
@ -1,81 +0,0 @@
|
|
|
|
|
{
|
|
|
|
|
config,
|
|
|
|
|
pkgs,
|
|
|
|
|
lib,
|
|
|
|
|
...
|
|
|
|
|
}: let
|
|
|
|
|
cfg = config.modules.usrEnv;
|
|
|
|
|
inherit (lib.options) mkOption;
|
|
|
|
|
inherit (lib.types) bool enum package;
|
|
|
|
|
in {
|
|
|
|
|
options.modules.usrEnv = {
|
|
|
|
|
desktop = mkOption {
|
|
|
|
|
type = enum ["none" "Hyprland" "awesomewm" "i3"];
|
|
|
|
|
default = "none";
|
|
|
|
|
description = ''
|
|
|
|
|
The desktop environment to be used.
|
|
|
|
|
'';
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
desktops = {
|
|
|
|
|
hyprland = {
|
|
|
|
|
enable = mkOption {
|
|
|
|
|
type = bool;
|
|
|
|
|
default = cfg.desktop == "Hyprland";
|
|
|
|
|
description = ''
|
|
|
|
|
Whether to enable Hyprland wayland compositor.
|
|
|
|
|
|
|
|
|
|
Will be enabled automatically when `modules.usrEnv.desktop`
|
|
|
|
|
is set to "Hyprland".
|
|
|
|
|
|
|
|
|
|
'';
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
package = mkOption {
|
|
|
|
|
type = package;
|
|
|
|
|
default = pkgs.hyprland;
|
|
|
|
|
description = ''
|
|
|
|
|
The Hyprland package to be used.
|
|
|
|
|
'';
|
|
|
|
|
};
|
|
|
|
|
portalPackage = mkOption {
|
|
|
|
|
type = package;
|
|
|
|
|
default = pkgs.xdg-desktop-portal-hyprland;
|
|
|
|
|
description = "The hyprland portal package";
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
awesomwm.enable = mkOption {
|
|
|
|
|
type = bool;
|
|
|
|
|
default = cfg.desktop == "awesomewm";
|
|
|
|
|
description = ''
|
|
|
|
|
Whether to enable Awesome window manager
|
|
|
|
|
|
|
|
|
|
Will be enabled automatically when `modules.usrEnv.desktop`
|
|
|
|
|
is set to "awesomewm".
|
|
|
|
|
'';
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
i3 = {
|
|
|
|
|
enable = mkOption {
|
|
|
|
|
type = bool;
|
|
|
|
|
default = cfg.desktop == "i3";
|
|
|
|
|
description = ''
|
|
|
|
|
Whether to enable i3 window manager
|
|
|
|
|
|
|
|
|
|
Will be enabled automatically when `modules.usrEnv.desktop`
|
|
|
|
|
is set to "i3".
|
|
|
|
|
'';
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
package = mkOption {
|
|
|
|
|
type = package;
|
|
|
|
|
default = pkgs.i3;
|
|
|
|
|
description = ''
|
|
|
|
|
The i3 package to be used.
|
|
|
|
|
'';
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
}
|
|
|
|
@ -1,8 +0,0 @@
|
|
|
|
|
_: {
|
|
|
|
|
imports = [
|
|
|
|
|
./desktop.nix
|
|
|
|
|
./programs/media.nix
|
|
|
|
|
./programs/launchers.nix
|
|
|
|
|
./services/default.nix
|
|
|
|
|
];
|
|
|
|
|
}
|
|
|
|
@ -1,10 +0,0 @@
|
|
|
|
|
{lib, ...}: let
|
|
|
|
|
inherit (lib.options) mkEnableOption;
|
|
|
|
|
in {
|
|
|
|
|
options.modules.usrEnv.programs.launchers = {
|
|
|
|
|
anyrun.enable = mkEnableOption "anyrun application launcher";
|
|
|
|
|
rofi.enable = mkEnableOption "rofi application launcher";
|
|
|
|
|
tofi.enable = mkEnableOption "tofi application launcher";
|
|
|
|
|
fuzzel.enable = mkEnableOption "fuzzel application launcher";
|
|
|
|
|
};
|
|
|
|
|
}
|
|
|
|
@ -1,60 +0,0 @@
|
|
|
|
|
{
|
|
|
|
|
config,
|
|
|
|
|
pkgs,
|
|
|
|
|
lib,
|
|
|
|
|
...
|
|
|
|
|
}: let
|
|
|
|
|
inherit (lib.options) mkOption mkEnableOption literalExpression;
|
|
|
|
|
inherit (lib.types) bool listOf package;
|
|
|
|
|
in {
|
|
|
|
|
options.modules.usrEnv.programs.media = {
|
|
|
|
|
addDefaultPackages = mkOption {
|
|
|
|
|
type = bool;
|
|
|
|
|
default = true;
|
|
|
|
|
description = ''
|
|
|
|
|
Whether to enable the default list of media-related packages ranging from audio taggers
|
|
|
|
|
to video editors.
|
|
|
|
|
'';
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
extraPackages = mkOption {
|
|
|
|
|
type = listOf package;
|
|
|
|
|
default = [];
|
|
|
|
|
description = ''
|
|
|
|
|
Additional packages that will be appended to media related packages.
|
|
|
|
|
'';
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
ncmpcpp.enable = mkEnableOption "ncmpcpp TUI music player";
|
|
|
|
|
|
|
|
|
|
beets.enable =
|
|
|
|
|
mkEnableOption ''
|
|
|
|
|
beets media library system.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
Will be enabled automatically if {option}`config.modules.usrEnv.services.mpd.enabled`
|
|
|
|
|
is set to true
|
|
|
|
|
''
|
|
|
|
|
// {default = config.modules.usrEnv.services.media.mpd.enable;};
|
|
|
|
|
|
|
|
|
|
mpv = {
|
|
|
|
|
enable = mkEnableOption "mpv media player";
|
|
|
|
|
scripts = mkOption {
|
|
|
|
|
type = listOf package;
|
|
|
|
|
description = "A list of MPV scripts that will be enabled";
|
|
|
|
|
example = literalExpression ''[ pkgs.mpvScripts.cutter ]'';
|
|
|
|
|
default = with pkgs.mpvScripts; [
|
|
|
|
|
# from nixpkgs
|
|
|
|
|
cutter # cut and automatically concat videos
|
|
|
|
|
mpris # MPRIS plugin
|
|
|
|
|
thumbnail # OSC seekbar thumbnails
|
|
|
|
|
thumbfast # on-the-fly thumbnailer
|
|
|
|
|
sponsorblock # skip sponsored segments
|
|
|
|
|
uosc # proximity UI
|
|
|
|
|
quality-menu # ytdl-format quality menu
|
|
|
|
|
seekTo # seek to specific pos.
|
|
|
|
|
];
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
}
|
|
|
|
@ -1,25 +0,0 @@
|
|
|
|
|
{
|
|
|
|
|
config,
|
|
|
|
|
lib,
|
|
|
|
|
...
|
|
|
|
|
}: let
|
|
|
|
|
inherit (lib.options) mkOption mkEnableOption;
|
|
|
|
|
inherit (lib) types;
|
|
|
|
|
inherit (config.meta.mainUser) username;
|
|
|
|
|
in {
|
|
|
|
|
options.modules.usrEnv.services = {
|
|
|
|
|
locate.enable = mkEnableOption "Locate service";
|
|
|
|
|
media = {
|
|
|
|
|
mpd = {
|
|
|
|
|
enable = mkEnableOption "mpd service";
|
|
|
|
|
musicDirectory = mkOption {
|
|
|
|
|
description = "music directory for mpd";
|
|
|
|
|
type = types.str;
|
|
|
|
|
default = "/home/${username}/cloud/media/Music";
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
kmscon.enable = mkEnableOption "Kmscon";
|
|
|
|
|
greetd.enable = mkEnableOption "Greetd";
|
|
|
|
|
};
|
|
|
|
|
}
|
|
|
|
@ -1,25 +0,0 @@
|
|
|
|
|
{
|
|
|
|
|
config,
|
|
|
|
|
lib,
|
|
|
|
|
pkgs,
|
|
|
|
|
...
|
|
|
|
|
}: let
|
|
|
|
|
inherit (lib) mkIf;
|
|
|
|
|
cfg = config.modules.usrEnv.services.kmscon;
|
|
|
|
|
in {
|
|
|
|
|
services.kmscon = mkIf cfg.enable {
|
|
|
|
|
enable = false;
|
|
|
|
|
hwRender = true;
|
|
|
|
|
fonts = [
|
|
|
|
|
{
|
|
|
|
|
name = "Iosevka";
|
|
|
|
|
package = pkgs.iosevka;
|
|
|
|
|
}
|
|
|
|
|
];
|
|
|
|
|
extraOptions = "--term xterm-256color";
|
|
|
|
|
extraConfig = ''
|
|
|
|
|
font-size=18
|
|
|
|
|
xkb-layout=${config.console.keyMap}
|
|
|
|
|
'';
|
|
|
|
|
};
|
|
|
|
|
}
|
|
|
|
@ -4,9 +4,11 @@
|
|
|
|
|
pkgs,
|
|
|
|
|
...
|
|
|
|
|
}: let
|
|
|
|
|
cfg = config.modules.usrEnv.services.locate;
|
|
|
|
|
inherit (lib) mkIf;
|
|
|
|
|
cfg = config.modules.services.locate;
|
|
|
|
|
inherit (lib.modules) mkIf;
|
|
|
|
|
inherit (lib.options) mkEnableOption;
|
|
|
|
|
in {
|
|
|
|
|
options.modules.services.locate.enable = mkEnableOption "Locate service";
|
|
|
|
|
config = mkIf cfg.enable {
|
|
|
|
|
environment.systemPackages = with pkgs; [plocate];
|
|
|
|
|
services.locate = {
|
|
|
|
|
|
|
|
@ -7,6 +7,5 @@ _: {
|
|
|
|
|
./mako.nix
|
|
|
|
|
./mpd.nix
|
|
|
|
|
./firewall.nix
|
|
|
|
|
./kmscon.nix
|
|
|
|
|
];
|
|
|
|
|
}
|
|
|
|
|
|
|
|
@ -4,12 +4,28 @@
|
|
|
|
|
pkgs,
|
|
|
|
|
...
|
|
|
|
|
}: let
|
|
|
|
|
cfg = config.modules.usrEnv.services.media.mpd;
|
|
|
|
|
inherit (config.modules.other.system) username;
|
|
|
|
|
inherit (lib) mkIf;
|
|
|
|
|
cfg = config.modules.services.media.mpd;
|
|
|
|
|
inherit (config.meta.mainUser) username;
|
|
|
|
|
inherit (lib.modules) mkIf;
|
|
|
|
|
inherit (lib.types) str;
|
|
|
|
|
inherit (lib.options) mkOption mkEnableOption;
|
|
|
|
|
in {
|
|
|
|
|
options.modules.services = {
|
|
|
|
|
media = {
|
|
|
|
|
mpd = {
|
|
|
|
|
enable = mkEnableOption "mpd service";
|
|
|
|
|
musicDirectory = mkOption {
|
|
|
|
|
description = "music directory for mpd";
|
|
|
|
|
type = str;
|
|
|
|
|
default = "/home/${username}/cloud/media/Music";
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
config = mkIf cfg.enable {
|
|
|
|
|
# command line interface to mpd
|
|
|
|
|
environment.systemPackages = [pkgs.mpc];
|
|
|
|
|
|
|
|
|
|
systemd.services.mpd.environment = {
|
|
|
|
|
# https://gitlab.freedesktop.org/pipewire/pipewire/-/issues/609
|
|
|
|
|
XDG_RUNTIME_DIR = "/run/user/1000";
|
|
|
|
|
|
|
|
@ -1,26 +0,0 @@
|
|
|
|
|
{
|
|
|
|
|
config,
|
|
|
|
|
lib,
|
|
|
|
|
pkgs,
|
|
|
|
|
...
|
|
|
|
|
}: let
|
|
|
|
|
inherit (lib) mkIf getExe;
|
|
|
|
|
cfg = config.modules.usrEnv.services.greetd;
|
|
|
|
|
in {
|
|
|
|
|
services.greetd = mkIf cfg.enable {
|
|
|
|
|
enable = true;
|
|
|
|
|
restart = true;
|
|
|
|
|
vt = 2;
|
|
|
|
|
settings = {
|
|
|
|
|
default_session = {
|
|
|
|
|
command = ''
|
|
|
|
|
${getExe pkgs.greetd.tuigreet} \
|
|
|
|
|
-c \"Hyprland\" \
|
|
|
|
|
-r
|
|
|
|
|
-t --time-format "DD.MM.YYYY"
|
|
|
|
|
--asteriks
|
|
|
|
|
'';
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
}
|
|
|
|
@ -3,7 +3,7 @@
|
|
|
|
|
pkgs,
|
|
|
|
|
...
|
|
|
|
|
}: let
|
|
|
|
|
cfg = config.modules.usrEnv.desktops.hyprland;
|
|
|
|
|
cfg = config.modules.desktops.hyprland;
|
|
|
|
|
inherit (builtins) map genList toString;
|
|
|
|
|
in {
|
|
|
|
|
programs.hyprland.settings = {
|
|
|
|
|
|
|
|
@ -4,9 +4,11 @@
|
|
|
|
|
lib,
|
|
|
|
|
...
|
|
|
|
|
}: let
|
|
|
|
|
cfg = config.modules.usrEnv.desktops.hyprland;
|
|
|
|
|
cfg = config.modules.desktops.hyprland;
|
|
|
|
|
# inherit (inputs.hyprsplit.packages.${pkgs.system}) hyprsplit;
|
|
|
|
|
inherit (lib) mkIf mkDefault;
|
|
|
|
|
inherit (lib.modules) mkIf mkDefault;
|
|
|
|
|
inherit (lib.options) mkOption;
|
|
|
|
|
inherit (lib.types) bool enum package;
|
|
|
|
|
in {
|
|
|
|
|
imports = [
|
|
|
|
|
./binds.nix
|
|
|
|
@ -19,6 +21,29 @@ in {
|
|
|
|
|
# we disable the default hyprland module
|
|
|
|
|
disabledModules = ["programs/hyprland.nix"];
|
|
|
|
|
|
|
|
|
|
options.modules.desktops.hyprland = {
|
|
|
|
|
enable = mkOption {
|
|
|
|
|
type = bool;
|
|
|
|
|
default = false;
|
|
|
|
|
description = ''
|
|
|
|
|
Whether to enable Hyprland wayland compositor.
|
|
|
|
|
'';
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
package = mkOption {
|
|
|
|
|
type = package;
|
|
|
|
|
default = pkgs.hyprland;
|
|
|
|
|
description = ''
|
|
|
|
|
The Hyprland package to be used.
|
|
|
|
|
'';
|
|
|
|
|
};
|
|
|
|
|
portalPackage = mkOption {
|
|
|
|
|
type = package;
|
|
|
|
|
default = pkgs.xdg-desktop-portal-hyprland;
|
|
|
|
|
description = "The hyprland portal package";
|
|
|
|
|
};
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
config = mkIf cfg.enable {
|
|
|
|
|
programs.hyprland = {
|
|
|
|
|
enable = true;
|
|
|
|
|