328 current 1970-01-01 01:00:00 23.11.20240518.e7cc617 6.6.30-rt30 *
This commit is contained in:
parent
da0bf720dd
commit
1c8ffbf289
@ -3,12 +3,11 @@
|
|||||||
../../modules/home
|
../../modules/home
|
||||||
];
|
];
|
||||||
|
|
||||||
shell.enable = true;
|
myConfig = {
|
||||||
git.enable = true;
|
enable = true;
|
||||||
music.enable = true;
|
desktop = true;
|
||||||
sway.enable = true;
|
laptop = true;
|
||||||
sway.laptop = true;
|
};
|
||||||
myPrograms.enable = true;
|
|
||||||
|
|
||||||
# Home Manager needs a bit of information about you and the paths it should
|
# Home Manager needs a bit of information about you and the paths it should
|
||||||
# manage.
|
# manage.
|
||||||
|
@ -1,3 +1,26 @@
|
|||||||
{...}: {
|
{
|
||||||
|
lib,
|
||||||
|
config,
|
||||||
|
...
|
||||||
|
}: let
|
||||||
|
cfg = config.myConfig;
|
||||||
|
in {
|
||||||
imports = [./git ./music ./programs ./shell ./sway];
|
imports = [./git ./music ./programs ./shell ./sway];
|
||||||
|
|
||||||
|
options.myConfig = {
|
||||||
|
enable = lib.mkEnableOption "custom home-manager config";
|
||||||
|
desktop = lib.mkEnableOption "custom home-manager config for desktop use";
|
||||||
|
laptop = lib.mkEnableOption "extra settings for laptop use";
|
||||||
|
};
|
||||||
|
|
||||||
|
config.myConfig = lib.mkIf cfg.enable {
|
||||||
|
shell.enable = true;
|
||||||
|
git.enable = true;
|
||||||
|
|
||||||
|
sway.enable = lib.mkIf cfg.desktop true;
|
||||||
|
music.enable = lib.mkIf cfg.desktop true;
|
||||||
|
programs.enable = lib.mkIf cfg.desktop true;
|
||||||
|
|
||||||
|
sway.laptop = lib.mkIf cfg.laptop true;
|
||||||
|
};
|
||||||
}
|
}
|
||||||
|
@ -3,16 +3,16 @@
|
|||||||
config,
|
config,
|
||||||
...
|
...
|
||||||
}: let
|
}: let
|
||||||
cfg = config.git;
|
cfg = config.myConfig.git;
|
||||||
in {
|
in {
|
||||||
imports = [./lazygit.nix];
|
imports = [./lazygit.nix];
|
||||||
|
|
||||||
options = {
|
options.myConfig.git = {
|
||||||
git.enable = lib.mkEnableOption "git";
|
enable = lib.mkEnableOption "git";
|
||||||
};
|
};
|
||||||
|
|
||||||
config = lib.mkIf cfg.enable {
|
config = lib.mkIf cfg.enable {
|
||||||
git.lazygit.enable = lib.mkDefault true;
|
myConfig.git.lazygit.enable = lib.mkDefault true;
|
||||||
|
|
||||||
programs.git = {
|
programs.git = {
|
||||||
enable = true;
|
enable = true;
|
||||||
|
@ -3,10 +3,10 @@
|
|||||||
config,
|
config,
|
||||||
...
|
...
|
||||||
}: let
|
}: let
|
||||||
cfg = config.git.lazygit;
|
cfg = config.myConfig.git.lazygit;
|
||||||
in {
|
in {
|
||||||
options = {
|
options.myConfig.git.lazygit = {
|
||||||
git.lazygit.enable = lib.mkEnableOption "lazygit, a git tui";
|
enable = lib.mkEnableOption "lazygit, a git tui";
|
||||||
};
|
};
|
||||||
|
|
||||||
config = lib.mkIf cfg.enable {
|
config = lib.mkIf cfg.enable {
|
||||||
|
@ -4,15 +4,15 @@
|
|||||||
inputs,
|
inputs,
|
||||||
...
|
...
|
||||||
}: let
|
}: let
|
||||||
cfg = config.music;
|
cfg = config.myConfig.music;
|
||||||
in {
|
in {
|
||||||
imports = [./mpd.nix];
|
imports = [./mpd.nix];
|
||||||
|
|
||||||
options = {
|
options.myConfig.music = {
|
||||||
music.enable = lib.mkEnableOption "make the system ready for listening to music";
|
enable = lib.mkEnableOption "make the system ready for listening to music";
|
||||||
};
|
};
|
||||||
|
|
||||||
config = lib.mkIf cfg.enable {
|
config = lib.mkIf cfg.enable {
|
||||||
music.mpd.enable = lib.mkDefault true;
|
myConfig.music.mpd.enable = lib.mkDefault true;
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
@ -4,10 +4,10 @@
|
|||||||
pkgs,
|
pkgs,
|
||||||
...
|
...
|
||||||
}: let
|
}: let
|
||||||
cfg = config.music.mpd;
|
cfg = config.myConfig.music.mpd;
|
||||||
in {
|
in {
|
||||||
options = {
|
options.myConfig.music.mpd = {
|
||||||
music.mpd.enable = lib.mkEnableOption "Music Player Daemon";
|
enable = lib.mkEnableOption "Music Player Daemon";
|
||||||
};
|
};
|
||||||
|
|
||||||
config = lib.mkIf cfg.enable {
|
config = lib.mkIf cfg.enable {
|
||||||
|
@ -4,19 +4,21 @@
|
|||||||
pkgs,
|
pkgs,
|
||||||
...
|
...
|
||||||
}: let
|
}: let
|
||||||
cfg = config.myPrograms;
|
cfg = config.myConfig.programs;
|
||||||
in {
|
in {
|
||||||
imports = [./foot.nix ./thunderbird.nix ./nextcloud.nix ./udiskie.nix];
|
imports = [./foot.nix ./thunderbird.nix ./nextcloud.nix ./udiskie.nix];
|
||||||
|
|
||||||
options = {
|
options.myConfig.programs = {
|
||||||
myPrograms.enable = lib.mkEnableOption "programs for desktop use";
|
enable = lib.mkEnableOption "programs for desktop use";
|
||||||
};
|
};
|
||||||
|
|
||||||
config = lib.mkIf cfg.enable {
|
config = lib.mkIf cfg.enable {
|
||||||
myPrograms.foot.enable = lib.mkDefault true;
|
myConfig.programs = {
|
||||||
myPrograms.thunderbird.enable = lib.mkDefault true;
|
foot.enable = lib.mkDefault true;
|
||||||
myPrograms.nextcloud.enable = lib.mkDefault true;
|
thunderbird.enable = lib.mkDefault true;
|
||||||
myPrograms.udiskie.enable = lib.mkDefault true;
|
nextcloud.enable = lib.mkDefault true;
|
||||||
|
udiskie.enable = lib.mkDefault true;
|
||||||
|
};
|
||||||
|
|
||||||
home.packages = with pkgs; [
|
home.packages = with pkgs; [
|
||||||
unzip
|
unzip
|
||||||
|
@ -3,10 +3,10 @@
|
|||||||
config,
|
config,
|
||||||
...
|
...
|
||||||
}: let
|
}: let
|
||||||
cfg = config.myPrograms.foot;
|
cfg = config.myConfig.programs.foot;
|
||||||
in {
|
in {
|
||||||
options = {
|
options.myConfig.programs.foot = {
|
||||||
myPrograms.foot.enable = lib.mkEnableOption "foot, a lightweight wayland terminal emulator";
|
enable = lib.mkEnableOption "foot, a lightweight wayland terminal emulator";
|
||||||
};
|
};
|
||||||
|
|
||||||
config = lib.mkIf cfg.enable {
|
config = lib.mkIf cfg.enable {
|
||||||
|
@ -3,10 +3,10 @@
|
|||||||
config,
|
config,
|
||||||
...
|
...
|
||||||
}: let
|
}: let
|
||||||
cfg = config.myPrograms.nextcloud;
|
cfg = config.myConfig.programs.nextcloud;
|
||||||
in {
|
in {
|
||||||
options = {
|
options.myConfig.programs.nextcloud = {
|
||||||
myPrograms.nextcloud.enable = lib.mkEnableOption "nextcloud client";
|
enable = lib.mkEnableOption "nextcloud client";
|
||||||
};
|
};
|
||||||
|
|
||||||
config = lib.mkIf cfg.enable {
|
config = lib.mkIf cfg.enable {
|
||||||
|
@ -3,10 +3,10 @@
|
|||||||
config,
|
config,
|
||||||
...
|
...
|
||||||
}: let
|
}: let
|
||||||
cfg = config.myPrograms.thunderbird;
|
cfg = config.myConfig.programs.thunderbird;
|
||||||
in {
|
in {
|
||||||
options = {
|
options.myConfig.programs.thunderbird = {
|
||||||
myPrograms.thunderbird.enable = lib.mkEnableOption "thunderbird, a email client";
|
enable = lib.mkEnableOption "thunderbird, a email client";
|
||||||
};
|
};
|
||||||
|
|
||||||
config = lib.mkIf cfg.enable {
|
config = lib.mkIf cfg.enable {
|
||||||
|
@ -3,10 +3,10 @@
|
|||||||
config,
|
config,
|
||||||
...
|
...
|
||||||
}: let
|
}: let
|
||||||
cfg = config.myPrograms.udiskie;
|
cfg = config.myConfig.programs.udiskie;
|
||||||
in {
|
in {
|
||||||
options = {
|
options.myConfig.programs.udiskie = {
|
||||||
myPrograms.udiskie.enable = lib.mkEnableOption "auto media mounting";
|
enable = lib.mkEnableOption "auto media mounting";
|
||||||
};
|
};
|
||||||
|
|
||||||
config = lib.mkIf cfg.enable {
|
config = lib.mkIf cfg.enable {
|
||||||
|
@ -3,10 +3,10 @@
|
|||||||
config,
|
config,
|
||||||
...
|
...
|
||||||
}: let
|
}: let
|
||||||
cfg = config.shell.bat;
|
cfg = config.myConfig.shell.bat;
|
||||||
in {
|
in {
|
||||||
options = {
|
options.myConfig.shell.bat = {
|
||||||
shell.bat.enable = lib.mkEnableOption "bat, a cat replacement with syntax highlighting";
|
enable = lib.mkEnableOption "bat, a cat replacement with syntax highlighting";
|
||||||
};
|
};
|
||||||
|
|
||||||
config = lib.mkIf cfg.enable {
|
config = lib.mkIf cfg.enable {
|
||||||
|
@ -4,10 +4,10 @@
|
|||||||
pkgs,
|
pkgs,
|
||||||
...
|
...
|
||||||
}: let
|
}: let
|
||||||
cfg = config.shell.btop;
|
cfg = config.myConfig.shell.btop;
|
||||||
in {
|
in {
|
||||||
options = {
|
options.myConfig.shell.btop = {
|
||||||
shell.btop.enable = lib.mkEnableOption "btop, a system monitor";
|
enable = lib.mkEnableOption "btop, a system monitor";
|
||||||
};
|
};
|
||||||
|
|
||||||
config = lib.mkIf cfg.enable {
|
config = lib.mkIf cfg.enable {
|
||||||
|
@ -3,18 +3,20 @@
|
|||||||
config,
|
config,
|
||||||
...
|
...
|
||||||
}: let
|
}: let
|
||||||
cfg = config.shell;
|
cfg = config.myConfig.shell;
|
||||||
in {
|
in {
|
||||||
imports = [./zsh.nix ./bat.nix ./btop.nix ./neovim.nix];
|
imports = [./zsh.nix ./bat.nix ./btop.nix ./neovim.nix];
|
||||||
|
|
||||||
options = {
|
options.myConfig.shell = {
|
||||||
shell.enable = lib.mkEnableOption "my shell environment";
|
enable = lib.mkEnableOption "my shell environment";
|
||||||
};
|
};
|
||||||
|
|
||||||
config = lib.mkIf cfg.enable {
|
config = lib.mkIf cfg.enable {
|
||||||
shell.zsh.enable = lib.mkDefault true;
|
myConfig.shell = {
|
||||||
shell.neovim.enable = lib.mkDefault true;
|
zsh.enable = lib.mkDefault true;
|
||||||
shell.btop.enable = lib.mkDefault true;
|
neovim.enable = lib.mkDefault true;
|
||||||
shell.bat.enable = lib.mkDefault true;
|
btop.enable = lib.mkDefault true;
|
||||||
|
bat.enable = lib.mkDefault true;
|
||||||
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
@ -4,10 +4,10 @@
|
|||||||
pkgs,
|
pkgs,
|
||||||
...
|
...
|
||||||
}: let
|
}: let
|
||||||
cfg = config.shell.neovim;
|
cfg = config.myConfig.shell.neovim;
|
||||||
in {
|
in {
|
||||||
options = {
|
options.myConfig.shell.neovim = {
|
||||||
shell.neovim.enable = lib.mkEnableOption "neovim";
|
enable = lib.mkEnableOption "neovim";
|
||||||
};
|
};
|
||||||
|
|
||||||
config = lib.mkIf cfg.enable {
|
config = lib.mkIf cfg.enable {
|
||||||
|
@ -4,10 +4,10 @@
|
|||||||
pkgs,
|
pkgs,
|
||||||
...
|
...
|
||||||
}: let
|
}: let
|
||||||
cfg = config.shell.zsh;
|
cfg = config.myConfig.shell.zsh;
|
||||||
in {
|
in {
|
||||||
options = {
|
options.myConfig.shell.zsh = {
|
||||||
shell.zsh.enable = lib.mkEnableOption "Zsh, an advanced shell";
|
enable = lib.mkEnableOption "Zsh, an advanced shell";
|
||||||
};
|
};
|
||||||
|
|
||||||
config = lib.mkIf cfg.enable {
|
config = lib.mkIf cfg.enable {
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
lib,
|
lib,
|
||||||
...
|
...
|
||||||
}: let
|
}: let
|
||||||
cfg = config.sway;
|
cfg = config.myConfig.sway;
|
||||||
|
|
||||||
rotate_lisgd = pkgs.writeShellScriptBin "rotate_lisgd" ''
|
rotate_lisgd = pkgs.writeShellScriptBin "rotate_lisgd" ''
|
||||||
# PREV_ORIENTATION and ORIENTATION are given by rot8
|
# PREV_ORIENTATION and ORIENTATION are given by rot8
|
||||||
@ -44,19 +44,21 @@
|
|||||||
in {
|
in {
|
||||||
imports = [./kanshi.nix ./waybar.nix ./theme.nix ./mako.nix];
|
imports = [./kanshi.nix ./waybar.nix ./theme.nix ./mako.nix];
|
||||||
|
|
||||||
options = {
|
options.myConfig.sway = {
|
||||||
sway.enable = lib.mkEnableOption "sway, a lightweight window manager";
|
enable = lib.mkEnableOption "sway, a lightweight window manager";
|
||||||
sway.laptop = lib.mkEnableOption "laptop config";
|
laptop = lib.mkEnableOption "laptop config";
|
||||||
};
|
};
|
||||||
|
|
||||||
config = lib.mkIf cfg.enable {
|
config = lib.mkIf cfg.enable {
|
||||||
sway.kanshi.enable = lib.mkDefault true;
|
myConfig.sway = {
|
||||||
sway.waybar.enable = lib.mkDefault true;
|
kanshi.enable = lib.mkDefault true;
|
||||||
sway.theming.enable = lib.mkDefault true;
|
waybar.enable = lib.mkDefault true;
|
||||||
sway.mako.enable = lib.mkDefault true;
|
theming.enable = lib.mkDefault true;
|
||||||
sway.waybar.battery = lib.mkIf cfg.laptop (lib.mkDefault true);
|
mako.enable = lib.mkDefault true;
|
||||||
sway.waybar.backlight = lib.mkIf cfg.laptop (lib.mkDefault true);
|
waybar.battery = lib.mkIf cfg.laptop (lib.mkDefault true);
|
||||||
sway.waybar.squeekboard = lib.mkIf cfg.laptop (lib.mkDefault true);
|
waybar.backlight = lib.mkIf cfg.laptop (lib.mkDefault true);
|
||||||
|
waybar.squeekboard = lib.mkIf cfg.laptop (lib.mkDefault true);
|
||||||
|
};
|
||||||
|
|
||||||
home.packages = with pkgs; [
|
home.packages = with pkgs; [
|
||||||
swaylock # screen locking
|
swaylock # screen locking
|
||||||
|
@ -4,11 +4,11 @@
|
|||||||
pkgs,
|
pkgs,
|
||||||
...
|
...
|
||||||
}: let
|
}: let
|
||||||
cfg = config.sway.kanshi;
|
cfg = config.myConfig.sway.kanshi;
|
||||||
in {
|
in {
|
||||||
options = {
|
options.myConfig.sway.kanshi = {
|
||||||
sway.kanshi.enable = lib.mkEnableOption "kanshi, a dynamic display recognizer";
|
enable = lib.mkEnableOption "kanshi, a dynamic display recognizer";
|
||||||
sway.kanshi.laptop = lib.mkEnableOption "laptop workspaces";
|
laptop = lib.mkEnableOption "laptop workspaces";
|
||||||
};
|
};
|
||||||
|
|
||||||
config = lib.mkIf cfg.enable {
|
config = lib.mkIf cfg.enable {
|
||||||
|
@ -3,10 +3,10 @@
|
|||||||
config,
|
config,
|
||||||
...
|
...
|
||||||
}: let
|
}: let
|
||||||
cfg = config.sway.mako;
|
cfg = config.myConfig.sway.mako;
|
||||||
in {
|
in {
|
||||||
options = {
|
options.myConfig.sway.mako = {
|
||||||
sway.mako.enable = lib.mkEnableOption "mako, a notification deamon";
|
enable = lib.mkEnableOption "mako, a notification deamon";
|
||||||
};
|
};
|
||||||
|
|
||||||
config = lib.mkIf cfg.enable {
|
config = lib.mkIf cfg.enable {
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
pkgs,
|
pkgs,
|
||||||
...
|
...
|
||||||
}: let
|
}: let
|
||||||
cfg = config.sway.theming;
|
cfg = config.myConfig.sway.theming;
|
||||||
|
|
||||||
# currently, there is some friction between sway and gtk:
|
# currently, there is some friction between sway and gtk:
|
||||||
# https://github.com/swaywm/sway/wiki/GTK-3-settings-on-Wayland
|
# https://github.com/swaywm/sway/wiki/GTK-3-settings-on-Wayland
|
||||||
@ -13,8 +13,8 @@
|
|||||||
gsettings set $gnome_schema gtk-theme 'Dracula'
|
gsettings set $gnome_schema gtk-theme 'Dracula'
|
||||||
'';
|
'';
|
||||||
in {
|
in {
|
||||||
options = {
|
options.myConfig.sway.theming = {
|
||||||
sway.theming.enable = lib.mkEnableOption "theming for sway";
|
enable = lib.mkEnableOption "theming for sway";
|
||||||
};
|
};
|
||||||
|
|
||||||
config = lib.mkIf cfg.enable {
|
config = lib.mkIf cfg.enable {
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
pkgs,
|
pkgs,
|
||||||
...
|
...
|
||||||
}: let
|
}: let
|
||||||
cfg = config.sway.waybar;
|
cfg = config.myConfig.sway.waybar;
|
||||||
|
|
||||||
schema = "org.gnome.desktop.a11y.applications";
|
schema = "org.gnome.desktop.a11y.applications";
|
||||||
key = "screen-keyboard-enabled";
|
key = "screen-keyboard-enabled";
|
||||||
@ -25,12 +25,12 @@
|
|||||||
fi
|
fi
|
||||||
'';
|
'';
|
||||||
in {
|
in {
|
||||||
options = {
|
options.myConfig.sway.waybar = {
|
||||||
sway.waybar.enable = lib.mkEnableOption "waybar, a status bar for wayland compositors";
|
enable = lib.mkEnableOption "waybar, a status bar for wayland compositors";
|
||||||
sway.waybar.squeekboard = lib.mkEnableOption "squeekboard";
|
squeekboard = lib.mkEnableOption "squeekboard";
|
||||||
sway.waybar.mpd = lib.mkEnableOption "mpd";
|
mpd = lib.mkEnableOption "mpd";
|
||||||
sway.waybar.battery = lib.mkEnableOption "battery";
|
battery = lib.mkEnableOption "battery";
|
||||||
sway.waybar.backlight = lib.mkEnableOption "backlight";
|
backlight = lib.mkEnableOption "backlight";
|
||||||
};
|
};
|
||||||
|
|
||||||
config = lib.mkIf cfg.enable {
|
config = lib.mkIf cfg.enable {
|
||||||
|
Loading…
Reference in New Issue
Block a user