again
This commit is contained in:
@@ -8,12 +8,12 @@ let
|
||||
;
|
||||
inherit (lib.${namespace}) mkBoolOpt mkOpt;
|
||||
|
||||
cfg = config.${namespace}.programs.browsers.firefox;
|
||||
cfg = config.${namespace}.programs.graphical.browsers.firefox;
|
||||
in
|
||||
{
|
||||
imports = lib.snowfall.fs.get-non-default-nix-files ./.;
|
||||
|
||||
options.${namespace}.programs.browsers.firefox = with types; {
|
||||
options.${namespace}.programs.graphical.browsers.firefox = with types; {
|
||||
enable = lib.mkEnableOption "Firefox";
|
||||
|
||||
extraConfig = mkOpt str "" "Extra configuration for the user profile JS file.";
|
||||
@@ -1,11 +1,12 @@
|
||||
{ pkgs, lib, config, namespace, ... }:
|
||||
let
|
||||
inherit (lib) mkIf;
|
||||
cfg = config.${namespace}.programs.ghostty;
|
||||
inherit (pkgs.stdenv) isLinux;
|
||||
inherit (lib) mkIf mkEnableOption optionals;
|
||||
cfg = config.${namespace}.programs.graphical.ghostty;
|
||||
in
|
||||
{
|
||||
options.${namespace}.programs.ghostty = {
|
||||
enable = lib.mkEnableOption "Ghostty";
|
||||
options.${namespace}.programs.graphical.ghostty = {
|
||||
enable = mkEnableOption "Ghostty";
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
@@ -53,12 +54,13 @@ in
|
||||
};
|
||||
|
||||
home.packages = with pkgs; [
|
||||
# Pending Darwin @ https://github.com/NixOS/nixpkgs/pull/369788
|
||||
# ghostty
|
||||
thefuck
|
||||
fastfetch
|
||||
bashInteractive
|
||||
(nerdfonts.override { fonts = [ "Meslo" ]; })
|
||||
] ++ optionals isLinux [
|
||||
# Pending Darwin @ https://github.com/NixOS/nixpkgs/pull/369788
|
||||
ghostty
|
||||
];
|
||||
|
||||
home.file.".config/fastfetch/config.jsonc".text = builtins.readFile ./config/fastfetch.jsonc;
|
||||
@@ -49,7 +49,7 @@ env = HYPRCURSOR_SIZE,24
|
||||
# https://wiki.hyprland.org/Configuring/Variables/#general
|
||||
general {
|
||||
gaps_in = 5
|
||||
gaps_out = 20
|
||||
gaps_out = 12
|
||||
|
||||
border_size = 2
|
||||
|
||||
@@ -38,32 +38,31 @@
|
||||
color: @text;
|
||||
}
|
||||
|
||||
/* Icon Only Sizes */
|
||||
#network,
|
||||
#backlight,
|
||||
#battery {
|
||||
font-size: 18px;
|
||||
}
|
||||
|
||||
/* Node Styles */
|
||||
#workspaces,
|
||||
#window,
|
||||
#cpu,
|
||||
#memory,
|
||||
#battery,
|
||||
#backlight,
|
||||
#pulseaudio,
|
||||
#network,
|
||||
#backlight,
|
||||
#battery,
|
||||
#clock {
|
||||
margin-top: 0.75rem;
|
||||
padding: 0px 0.5rem;
|
||||
margin-top: 1rem;
|
||||
padding: 0.2px 1rem;
|
||||
background-color: @surface0;
|
||||
}
|
||||
|
||||
#workspaces {
|
||||
margin-left: 1rem;
|
||||
border-radius: 1rem;
|
||||
padding: 0px;
|
||||
background-color: @surface0;
|
||||
}
|
||||
|
||||
#window {
|
||||
background: transparent;
|
||||
margin-left: 0.5rem;
|
||||
margin-right: 8rem; /* Notch */
|
||||
margin-left: 1rem;
|
||||
}
|
||||
|
||||
#workspaces button {
|
||||
@@ -74,30 +73,38 @@
|
||||
#workspaces button.active {
|
||||
color: @sky;
|
||||
background-color: @surface2;
|
||||
border-radius: 1rem;
|
||||
}
|
||||
|
||||
#workspaces button:hover {
|
||||
color: @sapphire;
|
||||
border-radius: 1rem;
|
||||
}
|
||||
|
||||
#clock {
|
||||
color: @blue;
|
||||
border-radius: 0px 1rem 1rem 0px;
|
||||
margin-right: 1rem;
|
||||
#window {
|
||||
background: transparent;
|
||||
margin-left: 0.5rem;
|
||||
margin-right: 8rem; /* Notch */
|
||||
}
|
||||
|
||||
#memory {
|
||||
color: @blue;
|
||||
border-radius: 0px 1rem 1rem 0px;
|
||||
margin-right: 0.5rem;
|
||||
}
|
||||
|
||||
#pulseaudio {
|
||||
color: @maroon;
|
||||
}
|
||||
|
||||
#network {
|
||||
color: @mauve;
|
||||
}
|
||||
|
||||
#cpu {
|
||||
color: @peach;
|
||||
}
|
||||
|
||||
#backlight {
|
||||
color: @yellow;
|
||||
}
|
||||
|
||||
#battery {
|
||||
color: @green;
|
||||
}
|
||||
@@ -110,13 +117,25 @@
|
||||
color: @red;
|
||||
}
|
||||
|
||||
#backlight {
|
||||
color: @yellow;
|
||||
#clock {
|
||||
color: @blue;
|
||||
margin-right: 1rem;
|
||||
}
|
||||
|
||||
#pulseaudio,
|
||||
#cpu {
|
||||
color: @maroon;
|
||||
border-radius: 1rem 0px 0px 1rem;
|
||||
margin-left: 0.5rem;
|
||||
/* Left Border Radius */
|
||||
#clock,
|
||||
#network,
|
||||
#cpu,
|
||||
#workspaces {
|
||||
border-top-left-radius: 1rem;
|
||||
border-bottom-left-radius: 1rem;
|
||||
}
|
||||
|
||||
/* Right Border Radius */
|
||||
#pulseaudio,
|
||||
#clock,
|
||||
#battery,
|
||||
#workspaces {
|
||||
border-top-right-radius: 1rem;
|
||||
border-bottom-right-radius: 1rem;
|
||||
}
|
||||
@@ -1,17 +1,16 @@
|
||||
{ lib, pkgs, config, namespace, ... }:
|
||||
let
|
||||
inherit (lib) mkIf;
|
||||
cfg = config.${namespace}.programs.hyprland;
|
||||
cfg = config.${namespace}.programs.graphical.wms.hyprland;
|
||||
in
|
||||
{
|
||||
options.${namespace}.programs.hyprland = {
|
||||
options.${namespace}.programs.graphical.wms.hyprland = {
|
||||
enable = lib.mkEnableOption "Hyprland";
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
wayland.windowManager.hyprland = {
|
||||
enable = true;
|
||||
# systemd.enable = false;
|
||||
extraConfig = builtins.readFile ./config/hyprland.conf;
|
||||
};
|
||||
|
||||
@@ -36,9 +35,9 @@ in
|
||||
"memory"
|
||||
"tray"
|
||||
"pulseaudio"
|
||||
"network"
|
||||
"backlight"
|
||||
"battery"
|
||||
"network"
|
||||
"clock"
|
||||
];
|
||||
"hyprland/window" = { format = "{}"; };
|
||||
@@ -48,10 +47,33 @@ in
|
||||
all-outputs = true;
|
||||
on-click = "activate";
|
||||
};
|
||||
battery = { format = " {}%"; };
|
||||
battery = {
|
||||
states = {
|
||||
warning = 30;
|
||||
critical = 15;
|
||||
};
|
||||
format = "{icon}";
|
||||
format-charging = "";
|
||||
format-plugged = "";
|
||||
format-alt = "{icon}";
|
||||
format-icons = [
|
||||
""
|
||||
""
|
||||
""
|
||||
""
|
||||
""
|
||||
""
|
||||
""
|
||||
""
|
||||
""
|
||||
""
|
||||
""
|
||||
""
|
||||
];
|
||||
};
|
||||
cpu = {
|
||||
interval = 10;
|
||||
format = " {}%";
|
||||
format = " {}%";
|
||||
max-length = 10;
|
||||
on-click = "";
|
||||
};
|
||||
@@ -61,9 +83,24 @@ in
|
||||
format-alt = " {used:0.1f}G";
|
||||
max-length = 10;
|
||||
};
|
||||
# backlight = {
|
||||
# format = " {}%";
|
||||
# device = "acpi_video0";
|
||||
# };
|
||||
|
||||
backlight = {
|
||||
format = " {}%";
|
||||
device = "acpi_video0";
|
||||
format = "{icon}";
|
||||
format-icons = [
|
||||
""
|
||||
""
|
||||
""
|
||||
""
|
||||
""
|
||||
""
|
||||
""
|
||||
];
|
||||
on-scroll-up = "brightnessctl s 1%-";
|
||||
on-scroll-down = "brightnessctl s +1%";
|
||||
};
|
||||
tray = {
|
||||
icon-size = 13;
|
||||
@@ -71,8 +108,29 @@ in
|
||||
spacing = 10;
|
||||
};
|
||||
network = {
|
||||
format = " {essid}";
|
||||
format-disconnected = " disconnected";
|
||||
interval = 1;
|
||||
format-wifi = "";
|
||||
format-ethernet = "";
|
||||
format-linked = "";
|
||||
format-disconnected = "";
|
||||
on-click-right = "${pkgs.networkmanagerapplet}/bin/nm-connection-editor";
|
||||
# tooltip-format = ''
|
||||
# <big>Network Details</big>
|
||||
# <tt><small>Interface: {ifname}</small></tt>
|
||||
# <tt><small>IP: {ipaddr}/{cidr}</small></tt>
|
||||
# <tt><small>Gateway: {gwaddr}</small></tt>
|
||||
# <tt><small> {bandwidthUpBytes}\n {bandwidthDownBytes}</small></tt>'';
|
||||
tooltip-format = ''
|
||||
<big>Network Details</big>
|
||||
<small>
|
||||
Interface: {ifname}
|
||||
SSID: {essid}
|
||||
IP Address: {ipaddr}/{cidr}
|
||||
Gateway: {gwaddr}
|
||||
|
||||
{bandwidthUpBytes} / {bandwidthDownBytes}
|
||||
</small>'';
|
||||
|
||||
};
|
||||
clock = {
|
||||
format = " {:%Y-%m-%d %H:%M:%S}";
|
||||
@@ -1,10 +1,10 @@
|
||||
{ lib, pkgs, config, namespace, ... }:
|
||||
let
|
||||
inherit (lib) mkIf;
|
||||
cfg = config.${namespace}.programs.aws;
|
||||
cfg = config.${namespace}.programs.terminal.aws;
|
||||
in
|
||||
{
|
||||
options.${namespace}.programs.aws = {
|
||||
options.${namespace}.programs.terminal.aws = {
|
||||
enable = lib.mkEnableOption "AWS";
|
||||
};
|
||||
|
||||
@@ -1,10 +1,10 @@
|
||||
{ lib, config, namespace, ... }:
|
||||
let
|
||||
inherit (lib) mkIf;
|
||||
cfg = config.${namespace}.programs.btop;
|
||||
cfg = config.${namespace}.programs.terminal.btop;
|
||||
in
|
||||
{
|
||||
options.${namespace}.programs.btop = {
|
||||
options.${namespace}.programs.terminal.btop = {
|
||||
enable = lib.mkEnableOption "btop";
|
||||
};
|
||||
|
||||
@@ -1,10 +1,10 @@
|
||||
{ lib, config, namespace, ... }:
|
||||
let
|
||||
inherit (lib) mkIf;
|
||||
cfg = config.${namespace}.programs.direnv;
|
||||
cfg = config.${namespace}.programs.terminal.direnv;
|
||||
in
|
||||
{
|
||||
options.${namespace}.programs.direnv = {
|
||||
options.${namespace}.programs.terminal.direnv = {
|
||||
enable = lib.mkEnableOption "direnv";
|
||||
};
|
||||
|
||||
@@ -1,10 +1,10 @@
|
||||
{ pkgs, lib, config, namespace, ... }:
|
||||
let
|
||||
inherit (lib) mkIf;
|
||||
cfg = config.${namespace}.programs.git;
|
||||
cfg = config.${namespace}.programs.terminal.git;
|
||||
in
|
||||
{
|
||||
options.${namespace}.programs.git = {
|
||||
options.${namespace}.programs.terminal.git = {
|
||||
enable = lib.mkEnableOption "Git";
|
||||
};
|
||||
|
||||
@@ -1,10 +1,10 @@
|
||||
{ lib, pkgs, config, namespace, ... }:
|
||||
let
|
||||
inherit (lib) mkIf;
|
||||
cfg = config.${namespace}.programs.k9s;
|
||||
cfg = config.${namespace}.programs.terminal.k9s;
|
||||
in
|
||||
{
|
||||
options.${namespace}.programs.k9s = {
|
||||
options.${namespace}.programs.terminal.k9s = {
|
||||
enable = lib.mkEnableOption "k9s";
|
||||
};
|
||||
|
||||
@@ -1,10 +1,10 @@
|
||||
{ pkgs, lib, config, namespace, ... }:
|
||||
let
|
||||
inherit (lib) mkIf;
|
||||
cfg = config.${namespace}.programs.nvim;
|
||||
cfg = config.${namespace}.programs.terminal.nvim;
|
||||
in
|
||||
{
|
||||
options.${namespace}.programs.nvim = {
|
||||
options.${namespace}.programs.terminal.nvim = {
|
||||
enable = lib.mkEnableOption "NeoVim";
|
||||
};
|
||||
|
||||
41
modules/home/services/sops/default.nix
Normal file
41
modules/home/services/sops/default.nix
Normal file
@@ -0,0 +1,41 @@
|
||||
{ config, lib, namespace, pkgs, ... }:
|
||||
let
|
||||
inherit (lib) mkIf types;
|
||||
inherit (lib.${namespace}) mkOpt;
|
||||
|
||||
cfg = config.${namespace}.services.sops;
|
||||
in
|
||||
{
|
||||
options.${namespace}.services.sops = with types; {
|
||||
enable = lib.mkEnableOption "sops";
|
||||
defaultSopsFile = mkOpt path null "Default sops file.";
|
||||
sshKeyPaths = mkOpt (listOf path) [ ] "SSH Key paths to use.";
|
||||
};
|
||||
|
||||
config = mkIf cfg.enable {
|
||||
home.packages = with pkgs; [
|
||||
age
|
||||
sops
|
||||
ssh-to-age
|
||||
];
|
||||
|
||||
sops = {
|
||||
inherit (cfg) defaultSopsFile;
|
||||
defaultSopsFormat = "yaml";
|
||||
|
||||
age = {
|
||||
generateKey = true;
|
||||
keyFile = "${config.home.homeDirectory}/.config/sops/age/keys.txt";
|
||||
sshKeyPaths = [ "${config.home.homeDirectory}/.ssh/id_ed25519" ] ++ cfg.sshKeyPaths;
|
||||
};
|
||||
|
||||
# TODO
|
||||
# secrets = {
|
||||
# nix = {
|
||||
# sopsFile = lib.snowfall.fs.get-file "secrets/default.yaml";
|
||||
# path = "${config.home.homeDirectory}/.config/nix/nix.conf";
|
||||
# };
|
||||
# };
|
||||
};
|
||||
};
|
||||
}
|
||||
15
modules/home/services/ssh-agent/default.nix
Normal file
15
modules/home/services/ssh-agent/default.nix
Normal file
@@ -0,0 +1,15 @@
|
||||
{ config, lib, namespace, ... }:
|
||||
let
|
||||
cfg = config.${namespace}.services.ssh-agent;
|
||||
in
|
||||
{
|
||||
options.${namespace}.services.ssh-agent = {
|
||||
enable = lib.mkEnableOption "ssh-agent service";
|
||||
};
|
||||
|
||||
config = lib.mkIf cfg.enable {
|
||||
services.ssh-agent = {
|
||||
enable = true;
|
||||
};
|
||||
};
|
||||
}
|
||||
Reference in New Issue
Block a user