Reformatted with nixfmt
This commit is contained in:
parent
f51256c3ae
commit
3f16537322
80 changed files with 1454 additions and 992 deletions
|
@ -3,11 +3,13 @@
|
|||
lib,
|
||||
namespace,
|
||||
...
|
||||
}: let
|
||||
}:
|
||||
let
|
||||
inherit (lib) mkIf mkEnableOption;
|
||||
|
||||
cfg = config.${namespace}.apps.bat;
|
||||
in {
|
||||
in
|
||||
{
|
||||
options.${namespace}.apps.bat = {
|
||||
enable = mkEnableOption "bat";
|
||||
};
|
||||
|
|
|
@ -3,11 +3,13 @@
|
|||
lib,
|
||||
namespace,
|
||||
...
|
||||
}: let
|
||||
}:
|
||||
let
|
||||
inherit (lib) mkIf mkEnableOption;
|
||||
|
||||
cfg = config.${namespace}.apps.btop;
|
||||
in {
|
||||
in
|
||||
{
|
||||
options.${namespace}.apps.btop = {
|
||||
enable = mkEnableOption "btop";
|
||||
};
|
||||
|
|
|
@ -4,7 +4,8 @@
|
|||
pkgs,
|
||||
namespace,
|
||||
...
|
||||
}: let
|
||||
}:
|
||||
let
|
||||
inherit (lib) mkEnableOption;
|
||||
inherit (pkgs) tmuxPlugins;
|
||||
|
||||
|
@ -20,13 +21,14 @@
|
|||
}
|
||||
];
|
||||
};
|
||||
in {
|
||||
in
|
||||
{
|
||||
options.${namespace}.apps.tmux = {
|
||||
enable = mkEnableOption "tmux";
|
||||
};
|
||||
|
||||
config = lib.mkIf cfg.enable {
|
||||
home.packages = [pkgs.tmux-sessionizer];
|
||||
home.packages = [ pkgs.tmux-sessionizer ];
|
||||
|
||||
catppuccin.tmux = {
|
||||
enable = true;
|
||||
|
@ -102,6 +104,6 @@ in {
|
|||
'';
|
||||
};
|
||||
|
||||
xdg.configFile."tms/config.toml".source = (pkgs.formats.toml {}).generate "tms-config" tmsConfig;
|
||||
xdg.configFile."tms/config.toml".source = (pkgs.formats.toml { }).generate "tms-config" tmsConfig;
|
||||
};
|
||||
}
|
||||
|
|
|
@ -4,9 +4,11 @@
|
|||
pkgs,
|
||||
namespace,
|
||||
...
|
||||
}: let
|
||||
}:
|
||||
let
|
||||
cfg = config.${namespace}.fonts;
|
||||
in {
|
||||
in
|
||||
{
|
||||
options.${namespace}.fonts = {
|
||||
enable = lib.mkEnableOption "font config";
|
||||
};
|
||||
|
@ -24,10 +26,10 @@ in {
|
|||
fonts.fontconfig = {
|
||||
enable = true;
|
||||
defaultFonts = {
|
||||
monospace = ["Hack Nerd Font"];
|
||||
emoji = ["Noto Color Emoji"];
|
||||
serif = ["Noto Serif"];
|
||||
sansSerif = ["Noto Sans"];
|
||||
monospace = [ "Hack Nerd Font" ];
|
||||
emoji = [ "Noto Color Emoji" ];
|
||||
serif = [ "Noto Serif" ];
|
||||
sansSerif = [ "Noto Sans" ];
|
||||
};
|
||||
};
|
||||
};
|
||||
|
|
|
@ -1,10 +1,11 @@
|
|||
{
|
||||
config,
|
||||
lib,
|
||||
osConfig ? {},
|
||||
osConfig ? { },
|
||||
namespace,
|
||||
...
|
||||
}: {
|
||||
}:
|
||||
{
|
||||
options.${namespace} = {
|
||||
isHeadless = lib.mkOption {
|
||||
type = lib.types.bool;
|
||||
|
@ -20,15 +21,13 @@
|
|||
};
|
||||
|
||||
config = lib.mkMerge [
|
||||
(
|
||||
lib.mkIf (!config.${namespace}.isHeadless) {
|
||||
${namespace} = {
|
||||
programs.firefox.enable = true;
|
||||
programs.kitty.enable = true;
|
||||
windowManagers.sway.enable = true;
|
||||
};
|
||||
}
|
||||
)
|
||||
(lib.mkIf (!config.${namespace}.isHeadless) {
|
||||
${namespace} = {
|
||||
programs.firefox.enable = true;
|
||||
programs.kitty.enable = true;
|
||||
windowManagers.sway.enable = true;
|
||||
};
|
||||
})
|
||||
(lib.mkIf (config.${namespace}.installDefaults) {
|
||||
${namespace} = {
|
||||
apps = {
|
||||
|
|
|
@ -3,11 +3,13 @@
|
|||
lib,
|
||||
namespace,
|
||||
...
|
||||
}: let
|
||||
}:
|
||||
let
|
||||
inherit (lib) mkEnableOption mkIf;
|
||||
|
||||
cfg = config.${namespace}.programs.firefox;
|
||||
in {
|
||||
in
|
||||
{
|
||||
options.${namespace}.programs.firefox = {
|
||||
enable = mkEnableOption "firefox";
|
||||
};
|
||||
|
|
|
@ -4,15 +4,17 @@
|
|||
pkgs,
|
||||
namespace,
|
||||
...
|
||||
}: let
|
||||
}:
|
||||
let
|
||||
cfg = config.${namespace}.programs.fuzzel;
|
||||
in {
|
||||
in
|
||||
{
|
||||
options.${namespace}.programs.fuzzel = {
|
||||
enable = lib.mkEnableOption "fuzzel";
|
||||
};
|
||||
|
||||
config = lib.mkIf cfg.enable {
|
||||
home.packages = [pkgs.bemoji];
|
||||
home.packages = [ pkgs.bemoji ];
|
||||
|
||||
catppuccin.fuzzel.enable = true;
|
||||
programs.fuzzel.enable = true;
|
||||
|
|
|
@ -3,9 +3,11 @@
|
|||
lib,
|
||||
namespace,
|
||||
...
|
||||
}: let
|
||||
}:
|
||||
let
|
||||
cfg = config.${namespace}.programs.fzf;
|
||||
in {
|
||||
in
|
||||
{
|
||||
options.${namespace}.programs.fzf = {
|
||||
enable = lib.mkEnableOption "fzf";
|
||||
};
|
||||
|
|
|
@ -5,11 +5,13 @@
|
|||
namespace,
|
||||
system,
|
||||
...
|
||||
}: let
|
||||
}:
|
||||
let
|
||||
inherit (lib) mkIf mkEnableOption;
|
||||
|
||||
cfg = config.${namespace}.programs.gpg;
|
||||
in {
|
||||
in
|
||||
{
|
||||
options.${namespace}.programs.gpg = {
|
||||
enable = mkEnableOption "gpg";
|
||||
};
|
||||
|
@ -33,9 +35,7 @@ in {
|
|||
services.gpg-agent = mkIf (system == "x86_64-linux") {
|
||||
enable = true;
|
||||
pinentryPackage =
|
||||
if config.${namespace}.windowManagers.sway.enable
|
||||
then pkgs.pinentry-qt
|
||||
else pkgs.pinentry-curses;
|
||||
if config.${namespace}.windowManagers.sway.enable then pkgs.pinentry-qt else pkgs.pinentry-curses;
|
||||
enableZshIntegration = true;
|
||||
enableSshSupport = true;
|
||||
sshKeys = [
|
||||
|
|
|
@ -3,9 +3,11 @@
|
|||
lib,
|
||||
namespace,
|
||||
...
|
||||
}: let
|
||||
}:
|
||||
let
|
||||
cfg = config.${namespace}.programs.k9s;
|
||||
in {
|
||||
in
|
||||
{
|
||||
options.${namespace}.programs.k9s = {
|
||||
enable = lib.mkEnableOption "k9s";
|
||||
};
|
||||
|
|
|
@ -4,11 +4,13 @@
|
|||
pkgs,
|
||||
namespace,
|
||||
...
|
||||
}: let
|
||||
}:
|
||||
let
|
||||
inherit (lib) mkEnableOption mkIf;
|
||||
|
||||
cfg = config.${namespace}.programs.kitty;
|
||||
in {
|
||||
in
|
||||
{
|
||||
options.${namespace}.programs.kitty = {
|
||||
enable = mkEnableOption "kitty";
|
||||
};
|
||||
|
|
|
@ -4,9 +4,11 @@
|
|||
pkgs,
|
||||
namespace,
|
||||
...
|
||||
}: let
|
||||
}:
|
||||
let
|
||||
cfg = config.${namespace}.programs.neovim;
|
||||
in {
|
||||
in
|
||||
{
|
||||
options.${namespace}.programs.neovim = {
|
||||
enable = lib.mkEnableOption "neovim";
|
||||
lazygit.enable = lib.mkOption {
|
||||
|
@ -21,19 +23,21 @@ in {
|
|||
};
|
||||
};
|
||||
|
||||
config = lib.mkIf cfg.enable (lib.mkMerge [
|
||||
{home.packages = [pkgs.neovim];}
|
||||
(lib.mkIf cfg.lazygit.enable {
|
||||
programs.zsh.shellAliases = {
|
||||
nvim = "${pkgs.neovim}/bin/nvim --listen /tmp/nvim-server.pipe";
|
||||
};
|
||||
config = lib.mkIf cfg.enable (
|
||||
lib.mkMerge [
|
||||
{ home.packages = [ pkgs.neovim ]; }
|
||||
(lib.mkIf cfg.lazygit.enable {
|
||||
programs.zsh.shellAliases = {
|
||||
nvim = "${pkgs.neovim}/bin/nvim --listen /tmp/nvim-server.pipe";
|
||||
};
|
||||
|
||||
programs.lazygit.settings.os = {
|
||||
editCommand = "nvim";
|
||||
editCommandTemplate = ''
|
||||
{{editor}} --server /tmp/nvim-server.pipe --remote-tab {{filename}}
|
||||
'';
|
||||
};
|
||||
})
|
||||
]);
|
||||
programs.lazygit.settings.os = {
|
||||
editCommand = "nvim";
|
||||
editCommandTemplate = ''
|
||||
{{editor}} --server /tmp/nvim-server.pipe --remote-tab {{filename}}
|
||||
'';
|
||||
};
|
||||
})
|
||||
]
|
||||
);
|
||||
}
|
||||
|
|
|
@ -4,11 +4,13 @@
|
|||
pkgs,
|
||||
namespace,
|
||||
...
|
||||
}: let
|
||||
}:
|
||||
let
|
||||
inherit (lib) mkEnableOption mkIf;
|
||||
|
||||
cfg = config.${namespace}.programs.rofi;
|
||||
in {
|
||||
in
|
||||
{
|
||||
options.${namespace}.programs.rofi = {
|
||||
enable = mkEnableOption "rofi";
|
||||
};
|
||||
|
@ -19,7 +21,7 @@ in {
|
|||
# TODO: How to ensure this font is installed?
|
||||
font = "Hack Nerd Font 10";
|
||||
catppuccin.enable = true;
|
||||
plugins = [pkgs.rofi-emoji];
|
||||
plugins = [ pkgs.rofi-emoji ];
|
||||
extraConfig = {
|
||||
show-icons = true;
|
||||
modi = "window,run,ssh,emoji";
|
||||
|
|
|
@ -3,11 +3,13 @@
|
|||
lib,
|
||||
namespace,
|
||||
...
|
||||
}: let
|
||||
}:
|
||||
let
|
||||
inherit (lib) mkEnableOption mkIf;
|
||||
|
||||
cfg = config.${namespace}.programs.swaylock;
|
||||
in {
|
||||
in
|
||||
{
|
||||
options.${namespace}.programs.swaylock = {
|
||||
enable = mkEnableOption "swaylock";
|
||||
};
|
||||
|
|
|
@ -4,11 +4,18 @@
|
|||
lib,
|
||||
namespace,
|
||||
...
|
||||
}: let
|
||||
inherit (lib) mkIf mkEnableOption mkOption types;
|
||||
}:
|
||||
let
|
||||
inherit (lib)
|
||||
mkIf
|
||||
mkEnableOption
|
||||
mkOption
|
||||
types
|
||||
;
|
||||
|
||||
cfg = config.${namespace}.programs.waybar;
|
||||
in {
|
||||
in
|
||||
{
|
||||
options.aa.programs.waybar = {
|
||||
enable = mkEnableOption "waybar";
|
||||
|
||||
|
@ -33,8 +40,8 @@ in {
|
|||
layer = "top";
|
||||
position = "bottom";
|
||||
height = 20;
|
||||
modules-left = ["sway/workspaces"];
|
||||
modules-center = ["clock"];
|
||||
modules-left = [ "sway/workspaces" ];
|
||||
modules-center = [ "clock" ];
|
||||
modules-right = [
|
||||
"idle_inhibitor"
|
||||
"temperature"
|
||||
|
@ -76,7 +83,11 @@ in {
|
|||
temperature = {
|
||||
critical-threshold = 80;
|
||||
format = "{icon}{temperatureC}°C";
|
||||
format-icons = [" " " " " "];
|
||||
format-icons = [
|
||||
" "
|
||||
" "
|
||||
" "
|
||||
];
|
||||
thermal-zone = cfg.thermal-zone;
|
||||
};
|
||||
|
||||
|
@ -99,7 +110,11 @@ in {
|
|||
phone = " ";
|
||||
portable = " ";
|
||||
car = " ";
|
||||
default = [" " " " " "];
|
||||
default = [
|
||||
" "
|
||||
" "
|
||||
" "
|
||||
];
|
||||
};
|
||||
tooltip-format = "{desc}, {volume}%";
|
||||
# TODO: Figure out how to get pactl binary?
|
||||
|
@ -118,7 +133,13 @@ in {
|
|||
format-charging = " {capacity}%";
|
||||
format-plugged = " ";
|
||||
format-alt = "{time} {icon}";
|
||||
format-icons = [" " " " " " " " " "];
|
||||
format-icons = [
|
||||
" "
|
||||
" "
|
||||
" "
|
||||
" "
|
||||
" "
|
||||
];
|
||||
};
|
||||
|
||||
memory = {
|
||||
|
@ -127,7 +148,10 @@ in {
|
|||
|
||||
backlight = {
|
||||
format = "{icon} {percent}%";
|
||||
format-icons = ["`" ""];
|
||||
format-icons = [
|
||||
"`"
|
||||
""
|
||||
];
|
||||
on-scroll-up = "light -A 1";
|
||||
on-scroll-down = "light -U 1";
|
||||
};
|
||||
|
@ -168,6 +192,6 @@ in {
|
|||
];
|
||||
};
|
||||
|
||||
wayland.windowManager.sway.config.bars = [];
|
||||
wayland.windowManager.sway.config.bars = [ ];
|
||||
};
|
||||
}
|
||||
|
|
|
@ -3,9 +3,11 @@
|
|||
lib,
|
||||
namespace,
|
||||
...
|
||||
}: let
|
||||
}:
|
||||
let
|
||||
cfg = config.${namespace}.programs.yazi;
|
||||
in {
|
||||
in
|
||||
{
|
||||
options.${namespace}.programs.yazi = {
|
||||
enable = lib.mkEnableOption "yazi";
|
||||
};
|
||||
|
|
|
@ -4,19 +4,21 @@
|
|||
lib,
|
||||
namespace,
|
||||
...
|
||||
}: let
|
||||
}:
|
||||
let
|
||||
cfg = config.${namespace}.programs.zoxide;
|
||||
in {
|
||||
in
|
||||
{
|
||||
options.${namespace}.programs.zoxide = {
|
||||
enable = lib.mkEnableOption "zoxide";
|
||||
};
|
||||
|
||||
config = lib.mkIf cfg.enable {
|
||||
home.packages = [pkgs.zoxide];
|
||||
home.packages = [ pkgs.zoxide ];
|
||||
|
||||
programs.zoxide = {
|
||||
enable = true;
|
||||
options = ["--cmd cd"];
|
||||
options = [ "--cmd cd" ];
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
|
@ -3,11 +3,13 @@
|
|||
lib,
|
||||
namespace,
|
||||
...
|
||||
}: let
|
||||
}:
|
||||
let
|
||||
inherit (lib) mkIf mkEnableOption;
|
||||
|
||||
cfg = config.${namespace}.services.gammastep;
|
||||
in {
|
||||
in
|
||||
{
|
||||
options.${namespace}.services.gammastep = {
|
||||
enable = mkEnableOption "gammastep";
|
||||
};
|
||||
|
|
|
@ -4,17 +4,19 @@
|
|||
pkgs,
|
||||
namespace,
|
||||
...
|
||||
}: let
|
||||
}:
|
||||
let
|
||||
inherit (lib) mkEnableOption mkIf;
|
||||
|
||||
cfg = config.${namespace}.services.playerctld;
|
||||
in {
|
||||
in
|
||||
{
|
||||
options.${namespace}.services.playerctld = {
|
||||
enable = mkEnableOption "playerctl";
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
home.packages = [pkgs.playerctl];
|
||||
home.packages = [ pkgs.playerctl ];
|
||||
services.playerctld.enable = true;
|
||||
};
|
||||
}
|
||||
|
|
|
@ -4,17 +4,19 @@
|
|||
lib,
|
||||
namespace,
|
||||
...
|
||||
}: let
|
||||
}:
|
||||
let
|
||||
inherit (lib) mkIf mkEnableOption;
|
||||
|
||||
cfg = config.${namespace}.services.swayidle;
|
||||
in {
|
||||
in
|
||||
{
|
||||
options.${namespace}.services.swayidle = {
|
||||
enable = mkEnableOption "swayidle";
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
home.packages = [pkgs.swayidle];
|
||||
home.packages = [ pkgs.swayidle ];
|
||||
|
||||
services.swayidle = {
|
||||
enable = true;
|
||||
|
|
|
@ -4,22 +4,29 @@
|
|||
pkgs,
|
||||
namespace,
|
||||
...
|
||||
}: let
|
||||
}:
|
||||
let
|
||||
inherit (lib) mkEnableOption mkIf;
|
||||
|
||||
cfg = config.${namespace}.services.swaync;
|
||||
in {
|
||||
in
|
||||
{
|
||||
options.${namespace}.services.swaync = {
|
||||
enable = mkEnableOption "sway notification center";
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
home.packages = [pkgs.libnotify];
|
||||
home.packages = [ pkgs.libnotify ];
|
||||
|
||||
services.swaync = {
|
||||
enable = true;
|
||||
settings = {
|
||||
widgets = ["title" "dnd" "notifications" "mpris"];
|
||||
widgets = [
|
||||
"title"
|
||||
"dnd"
|
||||
"notifications"
|
||||
"mpris"
|
||||
];
|
||||
};
|
||||
};
|
||||
|
||||
|
|
|
@ -3,11 +3,13 @@
|
|||
lib,
|
||||
namespace,
|
||||
...
|
||||
}: let
|
||||
}:
|
||||
let
|
||||
inherit (lib) mkEnableOption mkIf;
|
||||
|
||||
cfg = config.${namespace}.tools.direnv;
|
||||
in {
|
||||
in
|
||||
{
|
||||
options.${namespace}.tools.direnv = {
|
||||
enable = mkEnableOption "direnv";
|
||||
};
|
||||
|
|
|
@ -3,11 +3,13 @@
|
|||
lib,
|
||||
namespace,
|
||||
...
|
||||
}: let
|
||||
}:
|
||||
let
|
||||
inherit (lib) mkIf mkEnableOption;
|
||||
|
||||
cfg = config.${namespace}.tools.eza;
|
||||
in {
|
||||
in
|
||||
{
|
||||
options.${namespace}.tools.eza = {
|
||||
enable = mkEnableOption "eza";
|
||||
};
|
||||
|
|
|
@ -4,11 +4,13 @@
|
|||
lib,
|
||||
namespace,
|
||||
...
|
||||
}: let
|
||||
}:
|
||||
let
|
||||
inherit (lib) mkIf mkEnableOption mkDefault;
|
||||
|
||||
cfg = config.${namespace}.tools.git;
|
||||
in {
|
||||
in
|
||||
{
|
||||
options.${namespace}.tools.git = {
|
||||
enable = mkEnableOption "git";
|
||||
userName = lib.options.mkOption {
|
||||
|
|
|
@ -5,11 +5,13 @@
|
|||
pkgs,
|
||||
namespace,
|
||||
...
|
||||
}: let
|
||||
}:
|
||||
let
|
||||
inherit (lib) mkEnableOption mkIf;
|
||||
|
||||
cfg = config.${namespace}.tools.zsh;
|
||||
in {
|
||||
in
|
||||
{
|
||||
options.${namespace}.tools.zsh = {
|
||||
enable = mkEnableOption "zsh";
|
||||
};
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue