entirely vibed refactor
This commit is contained in:
parent
cea12431ff
commit
c343c52ab7
78 changed files with 884 additions and 1099 deletions
199
flake.nix
199
flake.nix
|
|
@ -23,128 +23,133 @@
|
|||
nix-minecraft.url = "github:Infinidoge/nix-minecraft";
|
||||
};
|
||||
|
||||
outputs = inputs @ { self, nixpkgs, nixpkgs-unstable, nur, nur-unstable, home-manager, stylix, nix-minecraft, ... }:
|
||||
outputs = inputs @ {
|
||||
self,
|
||||
nixpkgs,
|
||||
nixpkgs-unstable,
|
||||
nur,
|
||||
nur-unstable,
|
||||
home-manager,
|
||||
stylix,
|
||||
nix-minecraft,
|
||||
...
|
||||
}:
|
||||
let
|
||||
system = "x86_64-linux";
|
||||
repoLocalPath = "/home/alisceon/.nixos_config";
|
||||
|
||||
pkgs = import nixpkgs {
|
||||
inherit system;
|
||||
config.allowUnfree = true;
|
||||
flake.setFlakeRegistry = true;
|
||||
overlays = [ nur.overlays.default ];
|
||||
};
|
||||
|
||||
pkgs-unstable = import nixpkgs-unstable {
|
||||
inherit system;
|
||||
config.allowUnfree = true;
|
||||
flake.setFlakeRegistry = true;
|
||||
overlays = [ nur-unstable.overlays.default ];
|
||||
};
|
||||
|
||||
sharedSpecialArgs = {
|
||||
inherit pkgs-unstable;
|
||||
inherit inputs;
|
||||
inherit inputs pkgs-unstable repoLocalPath;
|
||||
repoRoot = self;
|
||||
};
|
||||
|
||||
sharedModules = [
|
||||
./hosts/base.nix
|
||||
./nixos/modules/base.nix
|
||||
stylix.nixosModules.stylix
|
||||
home-manager.nixosModules.home-manager
|
||||
({ config, ...}: {
|
||||
({ ... }: {
|
||||
home-manager.useGlobalPkgs = true;
|
||||
home-manager.useUserPackages = true;
|
||||
home-manager.extraSpecialArgs = {
|
||||
inherit (config.networking) hostName;
|
||||
inherit pkgs pkgs-unstable;
|
||||
}; # end extraSpecialArgs
|
||||
inherit pkgs pkgs-unstable repoLocalPath;
|
||||
repoRoot = self;
|
||||
};
|
||||
home-manager.backupFileExtension = "backup";
|
||||
}) # end home manager
|
||||
]; # end sharedModules
|
||||
})
|
||||
];
|
||||
|
||||
mkHost = {
|
||||
hostName,
|
||||
nixosModules ? [ ],
|
||||
hmModules ? [ ],
|
||||
extraModules ? [ ],
|
||||
}:
|
||||
nixpkgs.lib.nixosSystem {
|
||||
inherit system pkgs;
|
||||
specialArgs = sharedSpecialArgs;
|
||||
modules =
|
||||
sharedModules
|
||||
++ [ (./nixos/hosts + "/${hostName}/configuration.nix") ]
|
||||
++ nixosModules
|
||||
++ extraModules
|
||||
++ [
|
||||
{
|
||||
home-manager.users.alisceon.imports =
|
||||
[ ./home/profiles/base.nix ]
|
||||
++ hmModules;
|
||||
home-manager.users.root.imports = [
|
||||
./home/users/root/default.nix
|
||||
];
|
||||
}
|
||||
];
|
||||
};
|
||||
|
||||
workstationModules = [
|
||||
./nixos/modules/profiles/workstation.nix
|
||||
./nixos/modules/wm/sway.nix
|
||||
./nixos/modules/theme/stylix.nix
|
||||
];
|
||||
|
||||
workstationHomeModules = [
|
||||
./home/profiles/workstation.nix
|
||||
./home/modules/wm/sway/default.nix
|
||||
];
|
||||
|
||||
serverModules = [
|
||||
./nixos/modules/profiles/server.nix
|
||||
];
|
||||
|
||||
serverHomeModules = [
|
||||
./home/profiles/server.nix
|
||||
];
|
||||
in
|
||||
{
|
||||
nixosConfigurations = {
|
||||
electra = nixpkgs.lib.nixosSystem {
|
||||
inherit system;
|
||||
inherit pkgs;
|
||||
specialArgs = sharedSpecialArgs // {};
|
||||
modules = sharedModules ++ [
|
||||
./hosts/hosts/electra.nix
|
||||
./hosts/workstation.nix
|
||||
./hosts/modules/wm/sway/default.nix
|
||||
./hosts/modules/stylix.nix
|
||||
home-manager.nixosModules.home-manager
|
||||
({ config, ...}: {
|
||||
home-manager.users.alisceon.imports = [
|
||||
./home/alisceon/base.nix
|
||||
./home/alisceon/workstation.nix
|
||||
./home/wm/sway.nix
|
||||
./home/alisceon/hosts/electra.nix
|
||||
];
|
||||
home-manager.users.root.imports = [
|
||||
./home/root/base.nix
|
||||
];
|
||||
}) # end home-manager
|
||||
]; # end modules
|
||||
}; # end electra
|
||||
tower = nixpkgs.lib.nixosSystem {
|
||||
inherit system;
|
||||
inherit pkgs;
|
||||
specialArgs = sharedSpecialArgs // {};
|
||||
modules = sharedModules ++ [
|
||||
./hosts/hosts/tower.nix
|
||||
./hosts/workstation.nix
|
||||
./hosts/modules/wm/sway/default.nix
|
||||
./hosts/modules/stylix.nix
|
||||
home-manager.nixosModules.home-manager
|
||||
({ config, ...}: {
|
||||
home-manager.users.alisceon.imports = [
|
||||
./home/alisceon/base.nix
|
||||
./home/alisceon/workstation.nix
|
||||
./home/wm/sway.nix
|
||||
./home/alisceon/hosts/tower.nix
|
||||
];
|
||||
home-manager.users.root.imports = [
|
||||
./home/root/base.nix
|
||||
];
|
||||
}) # end home-manager
|
||||
]; # end modules
|
||||
}; # end tower
|
||||
tesla-nixos = nixpkgs.lib.nixosSystem {
|
||||
inherit system;
|
||||
inherit pkgs;
|
||||
specialArgs = sharedSpecialArgs // {};
|
||||
modules = sharedModules ++ [
|
||||
./hosts/server.nix
|
||||
./hosts/hosts/tesla-nixos.nix
|
||||
electra = mkHost {
|
||||
hostName = "electra";
|
||||
nixosModules = workstationModules;
|
||||
hmModules = workstationHomeModules ++ [
|
||||
./home/hosts/alisceon/electra.nix
|
||||
];
|
||||
};
|
||||
|
||||
tower = mkHost {
|
||||
hostName = "tower";
|
||||
nixosModules = workstationModules;
|
||||
hmModules = workstationHomeModules ++ [
|
||||
./home/hosts/alisceon/tower.nix
|
||||
];
|
||||
};
|
||||
|
||||
tesla-nixos = mkHost {
|
||||
hostName = "tesla-nixos";
|
||||
nixosModules = serverModules;
|
||||
hmModules = serverHomeModules;
|
||||
extraModules = [
|
||||
nix-minecraft.nixosModules.minecraft-servers
|
||||
{ nixpkgs.overlays = [ inputs.nix-minecraft.overlay ]; }
|
||||
home-manager.nixosModules.home-manager
|
||||
({ config, ...}: {
|
||||
home-manager.users.alisceon.imports = [
|
||||
./home/alisceon/base.nix
|
||||
./home/alisceon/server.nix
|
||||
];
|
||||
home-manager.users.root.imports = [
|
||||
./home/root/base.nix
|
||||
];
|
||||
}) # end home-manager
|
||||
]; # end modules
|
||||
}; # end tesla-nixos
|
||||
nuc = nixpkgs.lib.nixosSystem {
|
||||
inherit system;
|
||||
inherit pkgs;
|
||||
specialArgs = sharedSpecialArgs // {};
|
||||
modules = sharedModules ++ [
|
||||
./hosts/server.nix
|
||||
./hosts/hosts/nuc.nix
|
||||
home-manager.nixosModules.home-manager
|
||||
({ config, ...}: {
|
||||
home-manager.users.alisceon.imports = [
|
||||
./home/alisceon/base.nix
|
||||
./home/alisceon/server.nix
|
||||
];
|
||||
home-manager.users.root.imports = [
|
||||
./home/root/base.nix
|
||||
];
|
||||
}) # end home-manager
|
||||
]; # end modules
|
||||
}; # end tesla-nixos
|
||||
}; # end nixos conf
|
||||
}; # end "in"
|
||||
} # end file
|
||||
];
|
||||
};
|
||||
|
||||
nuc = mkHost {
|
||||
hostName = "nuc";
|
||||
nixosModules = serverModules;
|
||||
hmModules = serverHomeModules;
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,6 +0,0 @@
|
|||
{ ... }:
|
||||
{
|
||||
imports = [
|
||||
./default.nix
|
||||
];
|
||||
} # end file
|
||||
|
|
@ -1,21 +0,0 @@
|
|||
{ pkgs, config, hostName, lib, ... }:
|
||||
{
|
||||
imports = [
|
||||
./modules/programs/direnv.nix
|
||||
./modules/programs/git.nix
|
||||
./modules/programs/ssh.nix
|
||||
];
|
||||
|
||||
home.username = "alisceon";
|
||||
home.homeDirectory = "/home/alisceon";
|
||||
home.stateVersion = "24.05";
|
||||
manual.manpages.enable = true;
|
||||
# nixpkgs config
|
||||
xdg.configFile."nixpkgs/config.nix".source = ../conf/config.nix;
|
||||
|
||||
# xonsh extras
|
||||
xdg.configFile."xonsh/theo.py".source = ../conf/xonsh/theo.py;
|
||||
xdg.configFile."xonsh/kittycatsay.py".source = ../conf/xonsh/kittycatsay.py;
|
||||
# Ensure fish exists for the completer backend
|
||||
home.packages = [ pkgs.fish ];
|
||||
} # end file
|
||||
|
|
@ -1,17 +0,0 @@
|
|||
{ pkgs, config, hostName, lib, ... }: {
|
||||
programs.chromium = {
|
||||
enable = true;
|
||||
commandLineArgs = [
|
||||
"--enable-features=TouchpadOverscrollHistoryNavigation,VaapiVideoDecoder"
|
||||
];
|
||||
extensions = [
|
||||
{ id = "ddkjiahejlhfcafbddmgiahcphecmpfh"; } # ublock origin lite
|
||||
{ id = "nngceckbapebfimnlniiiahkandclblb"; } # bitwarden
|
||||
{ id = "mdjildafknihdffpkfmmpnpoiajfjnjd"; } # consent-o-matic
|
||||
{ id = "mnjggcdmjocbbbhaepdhchncahnbgone"; } # sponsorblock
|
||||
{ id = "ijcpiojgefnkmcadacmacogglhjdjphj"; } # shinigami eyes
|
||||
{ id = "kbmfpngjjgdllneeigpgjifpgocmfgmb"; } # reddit enhancement suite
|
||||
{ id = "einpaelgookohagofgnnkcfjbkkgepnp"; } # Random User-Agent
|
||||
];
|
||||
}; # end programs.chromium
|
||||
} # end file
|
||||
|
|
@ -1,8 +0,0 @@
|
|||
{ pkgs, config, hostName, lib, ... }:
|
||||
{
|
||||
programs.direnv = {
|
||||
enable = true;
|
||||
silent = true;
|
||||
nix-direnv.enable = true;
|
||||
}; # end programs.direnv
|
||||
} # end file
|
||||
|
|
@ -1,6 +0,0 @@
|
|||
{ pkgs, config, hostName, lib, ... }:
|
||||
{
|
||||
programs.discord = {
|
||||
enable = true;
|
||||
}; # end programs.discord
|
||||
} # end file
|
||||
|
|
@ -1,21 +0,0 @@
|
|||
{ pkgs, config, hostName, lib, ... }:
|
||||
{
|
||||
programs = {
|
||||
foot = {
|
||||
enable = true;
|
||||
server.enable = true;
|
||||
settings = {
|
||||
main = {
|
||||
app-id = "footclient";
|
||||
workers = 32;
|
||||
};
|
||||
bell = {
|
||||
system = "no";
|
||||
};
|
||||
scrollback = {
|
||||
lines = 100000;
|
||||
};
|
||||
};
|
||||
}; # end foot
|
||||
}; # end programs
|
||||
} # end file
|
||||
|
|
@ -1,7 +0,0 @@
|
|||
{ pkgs, config, hostName, lib, ... }:
|
||||
{
|
||||
programs.nushell = {
|
||||
enable = false;
|
||||
configFile.source = ../conf/config.nu;
|
||||
}; # end programs.nushell
|
||||
} # end file
|
||||
|
|
@ -1,12 +0,0 @@
|
|||
{ pkgs, config, hostName, lib, ... }:
|
||||
let
|
||||
commands = import ../../lib/commands.nix { inherit pkgs; };
|
||||
inherit (commands) term;
|
||||
in
|
||||
{
|
||||
programs.rofi = {
|
||||
enable = true;
|
||||
package = pkgs.rofi-unwrapped;
|
||||
terminal = term;
|
||||
}; # end programs.rofi
|
||||
} # end file
|
||||
|
|
@ -1,48 +0,0 @@
|
|||
{ pkgs, config, hostName, lib, ... }:
|
||||
{
|
||||
programs.vscode = {
|
||||
enable = true;
|
||||
package = pkgs.vscodium.fhsWithPackages (
|
||||
ps: with ps; [
|
||||
git
|
||||
]
|
||||
);
|
||||
profiles = {
|
||||
"default" = {
|
||||
userSettings = {
|
||||
"python.languageServer" = "None";
|
||||
"python.pyrefly.displayTypeErrors" = "force-on";
|
||||
"explorer.confirmDelete" = false;
|
||||
"explorer.confirmDragAndDrop" = false;
|
||||
"explorer.confirmPasteNative" = false;
|
||||
"git.confirmSync" = false;
|
||||
};
|
||||
extensions = [
|
||||
pkgs.vscode-extensions.ms-python.python
|
||||
pkgs.vscode-extensions.ms-python.debugpy
|
||||
pkgs.vscode-extensions.ms-vscode.cpptools
|
||||
pkgs.vscode-extensions.jnoortheen.nix-ide
|
||||
] ++ pkgs.vscode-utils.extensionsFromVscodeMarketplace [
|
||||
{
|
||||
name = "xonsh";
|
||||
publisher = "jnoortheen";
|
||||
version = "0.3.3";
|
||||
hash = "sha256-EdAjVzqvbiSm/hL/SeJIlfY1QocpQPyzv4RV84t4bbg=";
|
||||
}
|
||||
{
|
||||
name = "pyrefly";
|
||||
publisher = "meta";
|
||||
version = "0.52.0";
|
||||
hash = "sha256-vheW8D2jy3aTpAR/jsgw8Khj1z08GGmRaeYvL+UOXSI=";
|
||||
}
|
||||
{
|
||||
name = "chatgpt";
|
||||
publisher = "openai";
|
||||
version = "0.5.74";
|
||||
hash = "sha256-yR9oR3w4AkoWaQDPwSaQtrKL6IcXANaMfFiw6K/b5o0=";
|
||||
}
|
||||
]; # end extensions
|
||||
}; # end default
|
||||
}; # end profiles
|
||||
}; # end programs.vscode
|
||||
} # end file
|
||||
|
|
@ -1,112 +0,0 @@
|
|||
{ pkgs, config, hostName, lib, ... }:
|
||||
let
|
||||
commands = import ../../lib/commands.nix { inherit pkgs; };
|
||||
inherit (commands) uwsm term;
|
||||
in
|
||||
{
|
||||
programs.waybar = {
|
||||
enable = true;
|
||||
systemd = {
|
||||
enable = true;
|
||||
target = "graphical-session.target";
|
||||
};
|
||||
settings = {
|
||||
mainBar = {
|
||||
layer = "bottom";
|
||||
position = "top";
|
||||
height = 28;
|
||||
spacing = 0;
|
||||
modules-left = [
|
||||
"sway/workspaces"
|
||||
];
|
||||
modules-center = [
|
||||
"sway/window"
|
||||
];
|
||||
modules-right = [
|
||||
"tray"
|
||||
"idle_inhibitor"
|
||||
"network"
|
||||
"bluetooth"
|
||||
"pulseaudio"
|
||||
"battery"
|
||||
"sway/language"
|
||||
"clock"
|
||||
];
|
||||
"sway/workspaces" = {
|
||||
on-click = "activate";
|
||||
sort-by-number = true;
|
||||
format = "{value}";
|
||||
};
|
||||
"sway/window" = {
|
||||
max-length = 64;
|
||||
};
|
||||
"tray" = {
|
||||
icon-size = 24;
|
||||
spacing = 8;
|
||||
};
|
||||
"idle_inhibitor" = {
|
||||
format = "| {icon}";
|
||||
start-activated = true;
|
||||
format-icons = {
|
||||
activated = "🫨";
|
||||
deactivated = "😴";
|
||||
};
|
||||
};
|
||||
"sway/language" = {
|
||||
format = "| {flag}";
|
||||
tooltip-format = "{long}";
|
||||
};
|
||||
"clock" = {
|
||||
interval = 60;
|
||||
tooltip = true;
|
||||
format = "| {:%H:%M} ";
|
||||
tooltip-format = "{:%Y-%m-%d}";
|
||||
};
|
||||
"battery" = {
|
||||
interval = 60;
|
||||
format = "| {icon}{capacity}%";
|
||||
format-charging = "| {icon}⚡{capacity}%";
|
||||
format-plugged = "| {icon}🔌{capacity}%";
|
||||
states = {
|
||||
critical = 10;
|
||||
warning = 20;
|
||||
good = 100;
|
||||
full = 100;
|
||||
over = 101;
|
||||
};
|
||||
format-icons = [ "🪫" "🪫" "🔋" "🔋" "🔋"];
|
||||
};
|
||||
"network" = {
|
||||
tooltip-format = "{ifname} = {ipaddr}/{cidr}";
|
||||
format-wifi = "| ᯤ";
|
||||
format-ethernet = "| ⇄";
|
||||
format-linked = "| 🔗";
|
||||
format-disconnected = "| ⛓️💥";
|
||||
interval = 15;
|
||||
on-click = "${uwsm} ${term} -e nmtui";
|
||||
};
|
||||
"bluetooth" = {
|
||||
format-connected = "| ᛒ";
|
||||
format-on = "| ᚧ";
|
||||
format-disabled = "";
|
||||
format-no-controller = "";
|
||||
interval = 15;
|
||||
on-click = "${uwsm} ${term} -e bluetui";
|
||||
};
|
||||
"pulseaudio" = {
|
||||
format = "| 🔊{volume}%";
|
||||
format-muted = "| 🔈0%";
|
||||
format-bluetooth = "| 🎧{volume}%";
|
||||
on-click = "${uwsm} pavucontrol";
|
||||
};
|
||||
}; # end mainbar
|
||||
}; # end settings
|
||||
style = ''
|
||||
button {
|
||||
box-shadow: inset 0 -8px transparent;
|
||||
border: none;
|
||||
border-radius: 0;
|
||||
}
|
||||
''; # end style
|
||||
}; # end programs.waybar
|
||||
} # end file
|
||||
|
|
@ -1,66 +0,0 @@
|
|||
{ pkgs, config, hostName, lib, ... }:
|
||||
{
|
||||
services.espanso = {
|
||||
enable = true;
|
||||
waylandSupport = true;
|
||||
configs = {
|
||||
default = {
|
||||
toggle_key = "OFF";
|
||||
preserve_clipboard = true;
|
||||
show_notifications = true;
|
||||
keyboard_layout = { layout = "se"; };
|
||||
};
|
||||
};
|
||||
matches = {
|
||||
base = {
|
||||
matches = [
|
||||
{
|
||||
trigger = ":ip ";
|
||||
replace = "{{pubip}} ";
|
||||
}
|
||||
{
|
||||
trigger = ":gw2hs ";
|
||||
replace = "Full Homestead ^w^ ";
|
||||
}
|
||||
{
|
||||
regex = ":format (?P<alphabet>\\S+) (?P<text>\\S+) ";
|
||||
replace = "{{format_text}} ";
|
||||
vars = [
|
||||
{
|
||||
name = "format_text";
|
||||
type = "shell";
|
||||
params = {
|
||||
cmd = "${pkgs.python3}/bin/python3 /home/alisceon/.nixos_config/util/format_text.py $ESPANSO_ALPHABET $ESPANSO_TEXT";
|
||||
};
|
||||
}
|
||||
];
|
||||
}
|
||||
{
|
||||
regex = ";;(?P<emname>\\S+) ";
|
||||
replace = "{{emoji}} ";
|
||||
vars = [
|
||||
{
|
||||
name = "emoji";
|
||||
type = "shell";
|
||||
params = {
|
||||
cmd = "${pkgs.python3}/bin/python3 /home/alisceon/.nixos_config/util/get_emoji.py $ESPANSO_EMNAME";
|
||||
};
|
||||
}
|
||||
];
|
||||
}
|
||||
];
|
||||
};
|
||||
global_vars = {
|
||||
global_vars = [
|
||||
{
|
||||
name = "pubip";
|
||||
type = "shell";
|
||||
params = {
|
||||
cmd = "curl -s https://ifconfig.me";
|
||||
};
|
||||
}
|
||||
];
|
||||
};
|
||||
}; # end matches
|
||||
}; # end services.espanso
|
||||
} # end file
|
||||
|
|
@ -1,6 +0,0 @@
|
|||
{ pkgs, config, hostName, lib, ... }:
|
||||
{
|
||||
services.syncthing = {
|
||||
enable = true;
|
||||
};
|
||||
} # end file
|
||||
|
|
@ -1,5 +0,0 @@
|
|||
{ pkgs, config, hostName, lib, ... }: {
|
||||
imports = [
|
||||
"./dconf.nix"
|
||||
]
|
||||
} # end file
|
||||
|
|
@ -1,3 +0,0 @@
|
|||
{ ... }:
|
||||
{
|
||||
} # end file
|
||||
|
|
@ -1,9 +1,5 @@
|
|||
{ pkgs, config, hostName, lib, ... }:
|
||||
{ ... }:
|
||||
{
|
||||
imports = [
|
||||
../modules/services/swayidle.nix
|
||||
];
|
||||
|
||||
wayland.windowManager.sway.config = {
|
||||
output = {
|
||||
eDP-1 = {
|
||||
|
|
@ -16,7 +12,7 @@
|
|||
};
|
||||
};
|
||||
|
||||
workspaceOutputAssign = [];
|
||||
workspaceOutputAssign = [ ];
|
||||
|
||||
input."*" = {
|
||||
xkb_layout = "se,us";
|
||||
|
|
@ -25,4 +21,4 @@
|
|||
};
|
||||
|
||||
services.espanso.configs.default.keyboard_layout.layout = "se";
|
||||
} # end file
|
||||
}
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
{ pkgs, config, hostName, lib, ... }:
|
||||
{ ... }:
|
||||
{
|
||||
wayland.windowManager.sway.config = {
|
||||
output = {
|
||||
|
|
@ -36,4 +36,4 @@
|
|||
};
|
||||
|
||||
services.espanso.configs.default.keyboard_layout.layout = "us";
|
||||
} # end file
|
||||
}
|
||||
18
home/modules/programs/chromium.nix
Normal file
18
home/modules/programs/chromium.nix
Normal file
|
|
@ -0,0 +1,18 @@
|
|||
{ ... }:
|
||||
{
|
||||
programs.chromium = {
|
||||
enable = true;
|
||||
commandLineArgs = [
|
||||
"--enable-features=TouchpadOverscrollHistoryNavigation,VaapiVideoDecoder"
|
||||
];
|
||||
extensions = [
|
||||
{ id = "ddkjiahejlhfcafbddmgiahcphecmpfh"; }
|
||||
{ id = "nngceckbapebfimnlniiiahkandclblb"; }
|
||||
{ id = "mdjildafknihdffpkfmmpnpoiajfjnjd"; }
|
||||
{ id = "mnjggcdmjocbbbhaepdhchncahnbgone"; }
|
||||
{ id = "ijcpiojgefnkmcadacmacogglhjdjphj"; }
|
||||
{ id = "kbmfpngjjgdllneeigpgjifpgocmfgmb"; }
|
||||
{ id = "einpaelgookohagofgnnkcfjbkkgepnp"; }
|
||||
];
|
||||
};
|
||||
}
|
||||
8
home/modules/programs/direnv.nix
Normal file
8
home/modules/programs/direnv.nix
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
{ ... }:
|
||||
{
|
||||
programs.direnv = {
|
||||
enable = true;
|
||||
silent = true;
|
||||
nix-direnv.enable = true;
|
||||
};
|
||||
}
|
||||
4
home/modules/programs/discord.nix
Normal file
4
home/modules/programs/discord.nix
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
{ ... }:
|
||||
{
|
||||
programs.discord.enable = true;
|
||||
}
|
||||
|
|
@ -1,11 +1,10 @@
|
|||
{ pkgs, config, hostName, lib, ... }:
|
||||
{ ... }:
|
||||
{
|
||||
programs.fish = {
|
||||
enable = false;
|
||||
# Disable greeting
|
||||
interactiveShellInit = ''
|
||||
set fish_greeting
|
||||
'';
|
||||
preferAbbrs = true;
|
||||
}; # end programs.fish
|
||||
} # end file
|
||||
};
|
||||
}
|
||||
15
home/modules/programs/foot.nix
Normal file
15
home/modules/programs/foot.nix
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
{ ... }:
|
||||
{
|
||||
programs.foot = {
|
||||
enable = true;
|
||||
server.enable = true;
|
||||
settings = {
|
||||
main = {
|
||||
app-id = "footclient";
|
||||
workers = 32;
|
||||
};
|
||||
bell.system = "no";
|
||||
scrollback.lines = 100000;
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
{ pkgs, config, hostName, lib, ... }:
|
||||
{ ... }:
|
||||
{
|
||||
programs.git = {
|
||||
enable = true;
|
||||
|
|
@ -7,8 +7,8 @@
|
|||
name = "alisceon";
|
||||
email = "alisceon@protonmail.com";
|
||||
};
|
||||
push = { autoSetupRemote = true; };
|
||||
push.autoSetupRemote = true;
|
||||
init.defaultBranch = "main";
|
||||
};
|
||||
}; # end programs.git
|
||||
} # end file
|
||||
};
|
||||
}
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
{ pkgs, config, hostName, lib, ... }:
|
||||
{ ... }:
|
||||
{
|
||||
programs.kitty = {
|
||||
enable = true;
|
||||
|
|
@ -7,5 +7,5 @@
|
|||
enable_audio_bell = false;
|
||||
window_padding_width = 2;
|
||||
};
|
||||
}; # end programs.kitty
|
||||
} # end file
|
||||
};
|
||||
}
|
||||
7
home/modules/programs/nushell.nix
Normal file
7
home/modules/programs/nushell.nix
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
{ ... }:
|
||||
{
|
||||
programs.nushell = {
|
||||
enable = false;
|
||||
configFile.source = ../../conf/config.nu;
|
||||
};
|
||||
}
|
||||
12
home/modules/programs/rofi.nix
Normal file
12
home/modules/programs/rofi.nix
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
{ pkgs, ... }:
|
||||
let
|
||||
commands = import ../../../lib/commands.nix { inherit pkgs; };
|
||||
inherit (commands) term;
|
||||
in
|
||||
{
|
||||
programs.rofi = {
|
||||
enable = true;
|
||||
package = pkgs.rofi-unwrapped;
|
||||
terminal = term;
|
||||
};
|
||||
}
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
{ pkgs, config, hostName, lib, ... }:
|
||||
{ ... }:
|
||||
{
|
||||
programs.ssh = {
|
||||
enable = true;
|
||||
|
|
@ -38,9 +38,7 @@
|
|||
hostname = "10.40.0.2";
|
||||
user = "pi";
|
||||
};
|
||||
"nuc" = {
|
||||
hostname = "nuc.home.the.malice.zone";
|
||||
};
|
||||
"nuc".hostname = "nuc.home.the.malice.zone";
|
||||
"tsla-exporter-bridge" = {
|
||||
hostname = "alma02.lab.the.malice.zone";
|
||||
user = "root";
|
||||
|
|
@ -49,9 +47,7 @@
|
|||
hostname = "alma03.lab.the.malice.zone";
|
||||
user = "root";
|
||||
};
|
||||
"tsla-nixos" = {
|
||||
hostname = "tesla-nixos.lab.the.malice.zone";
|
||||
};
|
||||
"tsla-nixos".hostname = "tesla-nixos.lab.the.malice.zone";
|
||||
"tsla-backups" = {
|
||||
hostname = "backups.lab.the.malice.zone";
|
||||
user = "root";
|
||||
|
|
@ -70,6 +66,6 @@
|
|||
addKeysToAgent = "yes";
|
||||
hostname = "electra.home.the.malice.zone";
|
||||
};
|
||||
}; # end matchBlocks
|
||||
}; # end programs.ssh
|
||||
} # end file
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
@ -1,10 +1,10 @@
|
|||
{ pkgs, config, hostName, lib, ... }:
|
||||
{ ... }:
|
||||
{
|
||||
programs.swaylock = {
|
||||
enable = true;
|
||||
settings = {
|
||||
ignore-empty-password = true;
|
||||
indicator-caps-lock = true;
|
||||
}; # end settings
|
||||
}; # end programs.swaylock
|
||||
} # end file
|
||||
};
|
||||
};
|
||||
}
|
||||
44
home/modules/programs/vscode.nix
Normal file
44
home/modules/programs/vscode.nix
Normal file
|
|
@ -0,0 +1,44 @@
|
|||
{ pkgs, ... }:
|
||||
{
|
||||
programs.vscode = {
|
||||
enable = true;
|
||||
package = pkgs.vscodium.fhsWithPackages (
|
||||
ps: with ps; [ git ]
|
||||
);
|
||||
profiles.default = {
|
||||
userSettings = {
|
||||
"python.languageServer" = "None";
|
||||
"python.pyrefly.displayTypeErrors" = "force-on";
|
||||
"explorer.confirmDelete" = false;
|
||||
"explorer.confirmDragAndDrop" = false;
|
||||
"explorer.confirmPasteNative" = false;
|
||||
"git.confirmSync" = false;
|
||||
};
|
||||
extensions = [
|
||||
pkgs.vscode-extensions.ms-python.python
|
||||
pkgs.vscode-extensions.ms-python.debugpy
|
||||
pkgs.vscode-extensions.ms-vscode.cpptools
|
||||
pkgs.vscode-extensions.jnoortheen.nix-ide
|
||||
] ++ pkgs.vscode-utils.extensionsFromVscodeMarketplace [
|
||||
{
|
||||
name = "xonsh";
|
||||
publisher = "jnoortheen";
|
||||
version = "0.3.3";
|
||||
hash = "sha256-EdAjVzqvbiSm/hL/SeJIlfY1QocpQPyzv4RV84t4bbg=";
|
||||
}
|
||||
{
|
||||
name = "pyrefly";
|
||||
publisher = "meta";
|
||||
version = "0.52.0";
|
||||
hash = "sha256-vheW8D2jy3aTpAR/jsgw8Khj1z08GGmRaeYvL+UOXSI=";
|
||||
}
|
||||
{
|
||||
name = "chatgpt";
|
||||
publisher = "openai";
|
||||
version = "0.5.74";
|
||||
hash = "sha256-yR9oR3w4AkoWaQDPwSaQtrKL6IcXANaMfFiw6K/b5o0=";
|
||||
}
|
||||
];
|
||||
};
|
||||
};
|
||||
}
|
||||
104
home/modules/programs/waybar.nix
Normal file
104
home/modules/programs/waybar.nix
Normal file
|
|
@ -0,0 +1,104 @@
|
|||
{ pkgs, ... }:
|
||||
let
|
||||
commands = import ../../../lib/commands.nix { inherit pkgs; };
|
||||
inherit (commands) uwsm term;
|
||||
in
|
||||
{
|
||||
programs.waybar = {
|
||||
enable = true;
|
||||
systemd = {
|
||||
enable = true;
|
||||
target = "graphical-session.target";
|
||||
};
|
||||
settings.mainBar = {
|
||||
layer = "bottom";
|
||||
position = "top";
|
||||
height = 28;
|
||||
spacing = 0;
|
||||
modules-left = [ "sway/workspaces" ];
|
||||
modules-center = [ "sway/window" ];
|
||||
modules-right = [
|
||||
"tray"
|
||||
"idle_inhibitor"
|
||||
"network"
|
||||
"bluetooth"
|
||||
"pulseaudio"
|
||||
"battery"
|
||||
"sway/language"
|
||||
"clock"
|
||||
];
|
||||
"sway/workspaces" = {
|
||||
on-click = "activate";
|
||||
sort-by-number = true;
|
||||
format = "{value}";
|
||||
};
|
||||
"sway/window".max-length = 64;
|
||||
tray = {
|
||||
icon-size = 24;
|
||||
spacing = 8;
|
||||
};
|
||||
idle_inhibitor = {
|
||||
format = "| {icon}";
|
||||
start-activated = true;
|
||||
format-icons = {
|
||||
activated = "🫨";
|
||||
deactivated = "😴";
|
||||
};
|
||||
};
|
||||
"sway/language" = {
|
||||
format = "| {flag}";
|
||||
tooltip-format = "{long}";
|
||||
};
|
||||
clock = {
|
||||
interval = 60;
|
||||
tooltip = true;
|
||||
format = "| {:%H:%M} ";
|
||||
tooltip-format = "{:%Y-%m-%d}";
|
||||
};
|
||||
battery = {
|
||||
interval = 60;
|
||||
format = "| {icon}{capacity}%";
|
||||
format-charging = "| {icon}⚡{capacity}%";
|
||||
format-plugged = "| {icon}🔌{capacity}%";
|
||||
states = {
|
||||
critical = 10;
|
||||
warning = 20;
|
||||
good = 100;
|
||||
full = 100;
|
||||
over = 101;
|
||||
};
|
||||
format-icons = [ "🪫" "🪫" "🔋" "🔋" "🔋" ];
|
||||
};
|
||||
network = {
|
||||
tooltip-format = "{ifname} = {ipaddr}/{cidr}";
|
||||
format-wifi = "| ᯤ";
|
||||
format-ethernet = "| ⇄";
|
||||
format-linked = "| 🔗";
|
||||
format-disconnected = "| ⛓️💥";
|
||||
interval = 15;
|
||||
on-click = "${uwsm} ${term} -e nmtui";
|
||||
};
|
||||
bluetooth = {
|
||||
format-connected = "| ᛒ";
|
||||
format-on = "| ᚧ";
|
||||
format-disabled = "";
|
||||
format-no-controller = "";
|
||||
interval = 15;
|
||||
on-click = "${uwsm} ${term} -e bluetui";
|
||||
};
|
||||
pulseaudio = {
|
||||
format = "| 🔊{volume}%";
|
||||
format-muted = "| 🔈0%";
|
||||
format-bluetooth = "| 🎧{volume}%";
|
||||
on-click = "${uwsm} pavucontrol";
|
||||
};
|
||||
};
|
||||
style = ''
|
||||
button {
|
||||
box-shadow: inset 0 -8px transparent;
|
||||
border: none;
|
||||
border-radius: 0;
|
||||
}
|
||||
'';
|
||||
};
|
||||
}
|
||||
54
home/modules/services/espanso.nix
Normal file
54
home/modules/services/espanso.nix
Normal file
|
|
@ -0,0 +1,54 @@
|
|||
{ pkgs, repoRoot, ... }:
|
||||
{
|
||||
services.espanso = {
|
||||
enable = true;
|
||||
waylandSupport = true;
|
||||
configs.default = {
|
||||
toggle_key = "OFF";
|
||||
preserve_clipboard = true;
|
||||
show_notifications = true;
|
||||
keyboard_layout.layout = "se";
|
||||
};
|
||||
matches = {
|
||||
base.matches = [
|
||||
{
|
||||
trigger = ":ip ";
|
||||
replace = "{{pubip}} ";
|
||||
}
|
||||
{
|
||||
trigger = ":gw2hs ";
|
||||
replace = "Full Homestead ^w^ ";
|
||||
}
|
||||
{
|
||||
regex = ":format (?P<alphabet>\\S+) (?P<text>\\S+) ";
|
||||
replace = "{{format_text}} ";
|
||||
vars = [
|
||||
{
|
||||
name = "format_text";
|
||||
type = "shell";
|
||||
params.cmd = "${pkgs.python3}/bin/python3 ${repoRoot}/util/format_text.py $ESPANSO_ALPHABET $ESPANSO_TEXT";
|
||||
}
|
||||
];
|
||||
}
|
||||
{
|
||||
regex = ";;(?P<emname>\\S+) ";
|
||||
replace = "{{emoji}} ";
|
||||
vars = [
|
||||
{
|
||||
name = "emoji";
|
||||
type = "shell";
|
||||
params.cmd = "${pkgs.python3}/bin/python3 ${repoRoot}/util/get_emoji.py $ESPANSO_EMNAME";
|
||||
}
|
||||
];
|
||||
}
|
||||
];
|
||||
global_vars.global_vars = [
|
||||
{
|
||||
name = "pubip";
|
||||
type = "shell";
|
||||
params.cmd = "curl -s https://ifconfig.me";
|
||||
}
|
||||
];
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
{ pkgs, config, hostName, lib, ... }:
|
||||
{ ... }:
|
||||
{
|
||||
services.gnome-keyring = {
|
||||
enable = true;
|
||||
|
|
@ -8,4 +8,4 @@
|
|||
"secrets"
|
||||
];
|
||||
};
|
||||
} # end file
|
||||
}
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
{ pkgs, config, hostName, lib, ... }:
|
||||
{ ... }:
|
||||
{
|
||||
services.mako = {
|
||||
enable = true;
|
||||
|
|
@ -14,6 +14,6 @@
|
|||
layer = "overlay";
|
||||
margin = 10;
|
||||
markup = true;
|
||||
}; #end settings
|
||||
}; # end services.mako
|
||||
} # end file
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
@ -1,6 +1,6 @@
|
|||
{ pkgs, config, hostName, lib, ... }:
|
||||
{ pkgs, ... }:
|
||||
let
|
||||
commands = import ../../lib/commands.nix { inherit pkgs; };
|
||||
commands = import ../../../lib/commands.nix { inherit pkgs; };
|
||||
inherit (commands) notify lock display;
|
||||
in
|
||||
{
|
||||
|
|
@ -24,7 +24,7 @@ in
|
|||
timeout = 600;
|
||||
command = "${pkgs.systemd}/bin/systemctl suspend";
|
||||
}
|
||||
]; # end timeouts
|
||||
];
|
||||
events = [
|
||||
{
|
||||
event = "before-sleep";
|
||||
|
|
@ -42,6 +42,6 @@ in
|
|||
event = "unlock";
|
||||
command = display "on";
|
||||
}
|
||||
]; # end events
|
||||
}; # end services.swayidle
|
||||
} # end file
|
||||
];
|
||||
};
|
||||
}
|
||||
4
home/modules/services/syncthing.nix
Normal file
4
home/modules/services/syncthing.nix
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
{ ... }:
|
||||
{
|
||||
services.syncthing.enable = true;
|
||||
}
|
||||
|
|
@ -1,4 +1,5 @@
|
|||
{ pkgs, config, hostName, lib, ... }: {
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
dconf = {
|
||||
enable = true;
|
||||
settings = {
|
||||
|
|
@ -10,9 +11,7 @@
|
|||
picture-uri = "file:///home/alisceon/Pictures/system/bg.png";
|
||||
picture-uri-dark = "file:///home/alisceon/Pictures/system/bg.png";
|
||||
};
|
||||
"org/gnome/mutter" = {
|
||||
auto-maximize = true;
|
||||
};
|
||||
"org/gnome/mutter".auto-maximize = true;
|
||||
"org/gnome/desktop/interface" = {
|
||||
accent-color = "red";
|
||||
color-scheme = "prefer-dark";
|
||||
|
|
@ -31,7 +30,6 @@
|
|||
};
|
||||
"org/gnome/shell/keybindings" = {
|
||||
show-screenshot-ui = [ "<Shift><Super>s" ];
|
||||
|
||||
};
|
||||
"org/gnome/desktop/wm/keybindings" = {
|
||||
switch-to-workspace-1 = [ "<Super>1" ];
|
||||
|
|
@ -82,6 +80,6 @@
|
|||
use-system-font = false;
|
||||
use-theme-colors = true;
|
||||
};
|
||||
}; # end settings
|
||||
}; # end dconf
|
||||
} # end file
|
||||
};
|
||||
};
|
||||
}
|
||||
6
home/modules/wm/gnome/default.nix
Normal file
6
home/modules/wm/gnome/default.nix
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
{ ... }:
|
||||
{
|
||||
imports = [
|
||||
./dconf.nix
|
||||
];
|
||||
}
|
||||
|
|
@ -1,44 +1,42 @@
|
|||
{ pkgs, config, hostName, lib, ... }:
|
||||
let
|
||||
# shared command aliases
|
||||
commands = import ../../../lib/commands.nix { inherit pkgs; };
|
||||
inherit (commands) uwsm lock term notify nag dmenu espanso;
|
||||
{ pkgs, repoRoot, ... }:
|
||||
let
|
||||
commands = import ../../../../lib/commands.nix { inherit pkgs; };
|
||||
inherit (commands) uwsm lock term notify nag dmenu espanso;
|
||||
|
||||
# keybinds
|
||||
key_mod = "Mod4";
|
||||
key_mod_misc = "Alt";
|
||||
key_left = "Left";
|
||||
key_right = "Right";
|
||||
key_up = "Up";
|
||||
key_down = "Down";
|
||||
|
||||
in
|
||||
key_mod = "Mod4";
|
||||
key_mod_misc = "Alt";
|
||||
key_left = "Left";
|
||||
key_right = "Right";
|
||||
key_up = "Up";
|
||||
key_down = "Down";
|
||||
in
|
||||
{
|
||||
imports = [
|
||||
"./gtk.nix"
|
||||
"./xdg.nix"
|
||||
"../../modules/programs/foot.nix"
|
||||
"../../modules/programs/rofi.nix"
|
||||
"../../modules/programs/swaylock.nix"
|
||||
"../../modules/programs/waybar.nix"
|
||||
"../../modules/services/espanso.nix"
|
||||
"../../modules/services/gnome-keyring.nix"
|
||||
"../../modules/services/mako.nix"
|
||||
"../../modules/services/swayidle.nix"
|
||||
./gtk.nix
|
||||
./xdg.nix
|
||||
../../programs/foot.nix
|
||||
../../programs/rofi.nix
|
||||
../../programs/swaylock.nix
|
||||
../../programs/waybar.nix
|
||||
../../services/espanso.nix
|
||||
../../services/gnome-keyring.nix
|
||||
../../services/mako.nix
|
||||
../../services/swayidle.nix
|
||||
];
|
||||
|
||||
wayland.windowManager.sway = {
|
||||
enable = true;
|
||||
wrapperFeatures.gtk = true;
|
||||
config = {
|
||||
modifier = "${key_mod}";
|
||||
modifier = key_mod;
|
||||
startup = [
|
||||
{ command = "systemctl --user start libinput-gestures"; }
|
||||
{ command = ''${uwsm} swaybg -m fill -i /home/alisceon/Pictures/system/bg.png'';}
|
||||
{ command = "${uwsm} swaybg -m fill -i /home/alisceon/Pictures/system/bg.png"; }
|
||||
];
|
||||
bars = [ ];
|
||||
input = {
|
||||
"type:keyboard" = {
|
||||
xkb_options = "fkeys:basic_13-24";
|
||||
xkb_options = "fkeys:basic_13-24";
|
||||
};
|
||||
"type:touchpad" = {
|
||||
dwt = "enabled";
|
||||
|
|
@ -58,12 +56,10 @@
|
|||
xkb_layout = "se,us";
|
||||
xkb_options = "grp:win_space_toggle";
|
||||
};
|
||||
}; # end input
|
||||
};
|
||||
keybindings = {
|
||||
# Outputs
|
||||
"F13" = ''exec ${notify} -t 2000 "$(xonsh ~/.nixos_config/util/toggle_mon.xsh)"'';
|
||||
"F13" = "exec ${notify} -t 2000 \"$(${pkgs.xonsh}/bin/xonsh ${repoRoot}/util/toggle_mon.xsh)\"";
|
||||
|
||||
# Workspaces
|
||||
"${key_mod}+f" = "fullscreen";
|
||||
"${key_mod}+Shift+f" = "floating toggle";
|
||||
|
||||
|
|
@ -100,7 +96,6 @@
|
|||
"${key_mod}+Ctrl+9" = "move container to workspace number 9";
|
||||
"${key_mod}+Ctrl+0" = "move container to scratchpad";
|
||||
|
||||
# Layout
|
||||
"${key_mod}+b" = "splith";
|
||||
"${key_mod}+v" = "splitv";
|
||||
|
||||
|
|
@ -108,19 +103,16 @@
|
|||
"${key_mod}+w" = "layout tabbed";
|
||||
"${key_mod}+e" = "layout toggle split";
|
||||
|
||||
# Focus
|
||||
"${key_mod}+Ctrl+${key_left}" = "focus left";
|
||||
"${key_mod}+Ctrl+${key_right}" = "focus right";
|
||||
"${key_mod}+Ctrl+${key_down}" = "focus down";
|
||||
"${key_mod}+Ctrl+${key_up}" = "focus up";
|
||||
|
||||
# Move
|
||||
"${key_mod}+Shift+${key_left}" = "move left";
|
||||
"${key_mod}+Shift+${key_down}" = "move down";
|
||||
"${key_mod}+Shift+${key_up}" = "move up";
|
||||
"${key_mod}+Shift+${key_right}" = "move right";
|
||||
|
||||
# Sparkly alt-tab
|
||||
"${key_mod}+Tab" = "focus right";
|
||||
"${key_mod}+Shift+Tab" = "focus left";
|
||||
"${key_mod}+Ctrl+Tab" = "move right";
|
||||
|
|
@ -128,55 +120,49 @@
|
|||
"${key_mod}+${key_mod_misc}+Tab" = "workspace next";
|
||||
"${key_mod}+${key_mod_misc}+Shift+Tab" = "workspace prev";
|
||||
|
||||
# System
|
||||
"Mod4+space" = ''exec ${notify} -t 2000 "$(xonsh ~/.nixos_config/util/get_xkb.xsh)"'';
|
||||
"Mod4+space" = "exec ${notify} -t 2000 \"$(${pkgs.xonsh}/bin/xonsh ${repoRoot}/util/get_xkb.xsh)\"";
|
||||
"${key_mod}+Shift+r" = "reload";
|
||||
"${key_mod}+Ctrl+r" = "restart";
|
||||
"${key_mod}+Shift+Backspace" = "exec ${nag} -m 'TuneD profiles:' -Z 'Performance' 'tuned-adm profile accelerator-performance' -Z 'Balanced' 'tuned-adm profile balanced' -Z 'Power Save' 'tuned-adm profile powersave'";
|
||||
"${key_mod}+Shift+q" = "kill";
|
||||
"Alt+F4" = "kill";
|
||||
|
||||
# Locking and idle
|
||||
"${key_mod}+L" = "exec ${lock}";
|
||||
"${key_mod}+Escape" = "exec ${nag} -m 'Shutdown options:' -Z 'Power Off' 'systemctl poweroff' -Z 'Reboot' 'systemctl reboot' -Z 'Logout' 'swaymsg exit'";
|
||||
|
||||
# Apps
|
||||
"${key_mod}+Return" = ''exec "${uwsm} ${term}"'';
|
||||
"${key_mod}+d" = ''exec "${uwsm} ${dmenu} -show drun"'';
|
||||
"${key_mod}+s" = ''exec "${uwsm} ${espanso} search"'';
|
||||
"${key_mod}+Shift+e" = ''exec "${uwsm} ${espanso} toggle"'';
|
||||
|
||||
"${key_mod}+Return" = "exec ${uwsm} ${term}";
|
||||
"${key_mod}+d" = "exec ${uwsm} ${dmenu} -show drun";
|
||||
"${key_mod}+s" = "exec ${uwsm} ${espanso} search";
|
||||
"${key_mod}+Shift+e" = "exec ${uwsm} ${espanso} toggle";
|
||||
|
||||
# Screenshot region
|
||||
"${key_mod}+Shift+s" = "exec grimshot savecopy area";
|
||||
"${key_mod}+Ctrl+s" = "exec grimshot savecopy output";
|
||||
|
||||
# media keys
|
||||
"XF86AudioRaiseVolume" = "exec 'pactl set-sink-volume @DEFAULT_SINK@ +3%'";
|
||||
"XF86AudioLowerVolume" = "exec 'pactl set-sink-volume @DEFAULT_SINK@ -3%'";
|
||||
"XF86AudioMute" = "exec 'pactl set-sink-mute @DEFAULT_SINK@ toggle'";
|
||||
"XF86AudioPlay" = "exec 'playerctl play-pause'";
|
||||
"${key_mod}+XF86AudioPlay" = ''exec ${notify} -t 2000 "$(xonsh ~/.nixos_config/util/swap_sound_device.xsh)"'';
|
||||
"XF86AudioRaiseVolume" = "exec pactl set-sink-volume @DEFAULT_SINK@ +3%";
|
||||
"XF86AudioLowerVolume" = "exec pactl set-sink-volume @DEFAULT_SINK@ -3%";
|
||||
"XF86AudioMute" = "exec pactl set-sink-mute @DEFAULT_SINK@ toggle";
|
||||
"XF86AudioPlay" = "exec playerctl play-pause";
|
||||
"${key_mod}+XF86AudioPlay" = "exec ${notify} -t 2000 \"$(${pkgs.xonsh}/bin/xonsh ${repoRoot}/util/swap_sound_device.xsh)\"";
|
||||
"XF86MonBrightnessUp" = "exec ${pkgs.light}/bin/light -A 9";
|
||||
"XF86MonBrightnessDown" = "exec ${pkgs.light}/bin/light -U 3";
|
||||
}; # end keybindings
|
||||
};
|
||||
window = {
|
||||
titlebar = false;
|
||||
commands = [
|
||||
{ criteria = { all = true; }; command = "inhibit_idle fullscreen"; }
|
||||
];
|
||||
}; # end window
|
||||
assigns = {
|
||||
"1" = [{app_id = "chromium";}];
|
||||
"2" = [{class = "steam";}];
|
||||
"3" = [];
|
||||
"4" = [{class = "VSCodium";}];
|
||||
"5" = [{app_id = "obsidian";}];
|
||||
"6" = [];
|
||||
"7" = [];
|
||||
"8" = [{app_id = "discord";}];
|
||||
"9" = [{app_id = "signal";}];
|
||||
};
|
||||
}; # end config
|
||||
}; # end wayland.windowManager.sway
|
||||
} # end file
|
||||
assigns = {
|
||||
"1" = [ { app_id = "chromium"; } ];
|
||||
"2" = [ { class = "steam"; } ];
|
||||
"3" = [ ];
|
||||
"4" = [ { class = "VSCodium"; } ];
|
||||
"5" = [ { app_id = "obsidian"; } ];
|
||||
"6" = [ ];
|
||||
"7" = [ ];
|
||||
"8" = [ { app_id = "discord"; } ];
|
||||
"9" = [ { app_id = "signal"; } ];
|
||||
};
|
||||
};
|
||||
};
|
||||
}
|
||||
|
|
@ -1,4 +1,4 @@
|
|||
{ pkgs, config, hostName, lib, ... }:
|
||||
{ ... }:
|
||||
{
|
||||
gtk = {
|
||||
enable = true;
|
||||
|
|
@ -6,4 +6,4 @@
|
|||
gtk3.enable = true;
|
||||
gtk4.enable = true;
|
||||
};
|
||||
} # end file
|
||||
}
|
||||
|
|
@ -1,6 +1,6 @@
|
|||
{ pkgs, config, hostName, lib, ... }:
|
||||
{ pkgs, ... }:
|
||||
let
|
||||
commands = import ../../../lib/commands.nix { inherit pkgs; };
|
||||
commands = import ../../../../lib/commands.nix { inherit pkgs; };
|
||||
inherit (commands) swaymsg lock;
|
||||
in
|
||||
{
|
||||
|
|
@ -44,7 +44,7 @@ in
|
|||
"application/x-web-app-manifest+json" = [ "${pkgs.chromium}/share/applications/chromium.desktop" ];
|
||||
"application/xml-dtd" = [ "${pkgs.chromium}/share/applications/chromium.desktop" ];
|
||||
|
||||
"image/*" = [ "${pkgs.loupe}/share/applications/org.gnome.Loupe.desktop.desktop" ];
|
||||
"image/*" = [ "${pkgs.loupe}/share/applications/org.gnome.Loupe.desktop" ];
|
||||
};
|
||||
};
|
||||
};
|
||||
|
|
@ -53,4 +53,4 @@ in
|
|||
GNOME_DESKTOP_SESSION_ID = "999";
|
||||
SHELL_THICCNESS = "LOW";
|
||||
};
|
||||
} # end file
|
||||
}
|
||||
6
home/profiles/base.nix
Normal file
6
home/profiles/base.nix
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
{ ... }:
|
||||
{
|
||||
imports = [
|
||||
../users/alisceon/default.nix
|
||||
];
|
||||
}
|
||||
3
home/profiles/server.nix
Normal file
3
home/profiles/server.nix
Normal file
|
|
@ -0,0 +1,3 @@
|
|||
{ ... }:
|
||||
{
|
||||
}
|
||||
|
|
@ -1,19 +1,16 @@
|
|||
{ pkgs, config, hostName, lib, ... }: {
|
||||
{ pkgs, lib, repoRoot, ... }:
|
||||
{
|
||||
imports = [
|
||||
./modules/programs/chromium.nix
|
||||
./modules/programs/discord.nix
|
||||
./modules/programs/vscode.nix
|
||||
./modules/services/syncthing.nix
|
||||
../modules/programs/chromium.nix
|
||||
../modules/programs/discord.nix
|
||||
../modules/programs/vscode.nix
|
||||
../modules/services/syncthing.nix
|
||||
];
|
||||
|
||||
stylix.enableReleaseChecks = false;
|
||||
# obsidian special case
|
||||
# programs.obsidian.enable = true;
|
||||
# overide broken config
|
||||
xdg.configFile."obsidian/obsidian.json".source = lib.mkForce ../conf/obsidian.json;
|
||||
|
||||
# nixpkgs config
|
||||
xdg.configFile."nixpkgs/config.nix".source = ../conf/config.nix;
|
||||
xdg.configFile."obsidian/obsidian.json".source = lib.mkForce ../conf/obsidian.json;
|
||||
xdg.configFile."nixpkgs/config.nix".source = ../conf/config.nix;
|
||||
|
||||
xdg = {
|
||||
enable = true;
|
||||
|
|
@ -33,9 +30,9 @@
|
|||
chromium-dailies = {
|
||||
name = "Chromium Dailies";
|
||||
genericName = "Web Browser (with dailies)";
|
||||
exec = "xonsh /home/alisceon/.nixos_config/util/open_dailies.xsh";
|
||||
exec = "${pkgs.xonsh}/bin/xonsh ${repoRoot}/util/open_dailies.xsh";
|
||||
terminal = false;
|
||||
};
|
||||
};
|
||||
};
|
||||
} # end file
|
||||
}
|
||||
|
|
@ -1,6 +0,0 @@
|
|||
{ ... }:
|
||||
{
|
||||
imports = [
|
||||
./default.nix
|
||||
];
|
||||
} # end file
|
||||
|
|
@ -1,12 +0,0 @@
|
|||
{ pkgs, config, hostName, lib, ... }:
|
||||
{
|
||||
home.username = "root";
|
||||
home.homeDirectory = "/root";
|
||||
home.stateVersion = "24.05";
|
||||
programs = {
|
||||
git = {
|
||||
enable = true;
|
||||
extraConfig.safe.directory = "/home/alisceon/.nixos_config";
|
||||
}; # end git
|
||||
}; # end programs
|
||||
} # end file
|
||||
20
home/users/alisceon/default.nix
Normal file
20
home/users/alisceon/default.nix
Normal file
|
|
@ -0,0 +1,20 @@
|
|||
{ pkgs, ... }:
|
||||
{
|
||||
imports = [
|
||||
../../modules/programs/direnv.nix
|
||||
../../modules/programs/git.nix
|
||||
../../modules/programs/ssh.nix
|
||||
];
|
||||
|
||||
home.username = "alisceon";
|
||||
home.homeDirectory = "/home/alisceon";
|
||||
home.stateVersion = "24.05";
|
||||
manual.manpages.enable = true;
|
||||
|
||||
xdg.configFile."nixpkgs/config.nix".source = ../../conf/config.nix;
|
||||
xdg.configFile."xonsh/theo.py".source = ../../conf/xonsh/theo.py;
|
||||
xdg.configFile."xonsh/kittycatsay.py".source = ../../conf/xonsh/kittycatsay.py;
|
||||
|
||||
# Ensure fish exists for the completer backend.
|
||||
home.packages = [ pkgs.fish ];
|
||||
}
|
||||
11
home/users/root/default.nix
Normal file
11
home/users/root/default.nix
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
{ repoLocalPath, ... }:
|
||||
{
|
||||
home.username = "root";
|
||||
home.homeDirectory = "/root";
|
||||
home.stateVersion = "24.05";
|
||||
|
||||
programs.git = {
|
||||
enable = true;
|
||||
extraConfig.safe.directory = repoLocalPath;
|
||||
};
|
||||
}
|
||||
|
|
@ -1,18 +0,0 @@
|
|||
{ ... }:
|
||||
{
|
||||
imports = [
|
||||
../alisceon/modules/wm/sway/default.nix
|
||||
../alisceon/modules/wm/sway/gtk.nix
|
||||
../alisceon/modules/wm/sway/xdg.nix
|
||||
|
||||
../alisceon/modules/programs/foot.nix
|
||||
../alisceon/modules/programs/kitty.nix
|
||||
../alisceon/modules/programs/rofi.nix
|
||||
../alisceon/modules/programs/swaylock.nix
|
||||
../alisceon/modules/programs/waybar.nix
|
||||
|
||||
../alisceon/modules/services/espanso.nix
|
||||
../alisceon/modules/services/gnome-keyring.nix
|
||||
../alisceon/modules/services/mako.nix
|
||||
];
|
||||
} # end file
|
||||
|
|
@ -1,6 +0,0 @@
|
|||
{ ... }:
|
||||
{
|
||||
imports = [
|
||||
./default.nix
|
||||
];
|
||||
} # end file
|
||||
|
|
@ -1,20 +0,0 @@
|
|||
{ config, pkgs, ... }:
|
||||
|
||||
{
|
||||
system.autoUpgrade = {
|
||||
allowReboot = true;
|
||||
}; # end system.autoUpgrade
|
||||
services = {
|
||||
openssh = {
|
||||
enable = true;
|
||||
permitRootLogin = "no";
|
||||
}; # end openssh
|
||||
}; # end services
|
||||
|
||||
environment = {
|
||||
systemPackages = with pkgs; [
|
||||
devenv
|
||||
direnv
|
||||
]; # end systemPackages
|
||||
}; # end environment
|
||||
} # end file
|
||||
|
|
@ -1,108 +0,0 @@
|
|||
{ config, pkgs, lib, hostName, ... }:
|
||||
{
|
||||
environment.systemPackages = with pkgs; [
|
||||
pavucontrol
|
||||
libinput
|
||||
libinput-gestures
|
||||
libnotify
|
||||
wmctrl
|
||||
playerctl
|
||||
|
||||
# MIME utilities
|
||||
xdg-utils
|
||||
shared-mime-info
|
||||
|
||||
# GNOME utilities
|
||||
libsecret # Keyring backend
|
||||
gnome-text-editor
|
||||
loupe
|
||||
evince
|
||||
seahorse
|
||||
nautilus
|
||||
];
|
||||
|
||||
# enable Sway window manager
|
||||
programs = {
|
||||
sway = {
|
||||
enable = true;
|
||||
wrapperFeatures.base = true;
|
||||
wrapperFeatures.gtk = true;
|
||||
extraOptions = [
|
||||
"--unsupported-gpu"
|
||||
];
|
||||
extraPackages = with pkgs; [
|
||||
swayidle # idle management
|
||||
swaylock # screen locker
|
||||
swaybg # wallpaper setting tool
|
||||
grim # screenshot tool
|
||||
slurp # selection tool for screenshots
|
||||
wl-clipboard # clipboard support (mostly for grim/slurp)
|
||||
pulseaudio # pulseaudio support
|
||||
sway-contrib.grimshot # screenshot tool
|
||||
foot # fast and lightweight terminal emulator
|
||||
kitty # sparkly terminal emulator
|
||||
dotool # tool to send keyboard/mouse input to wayland apps
|
||||
mako # notification system developed by swaywm maintainer
|
||||
espanso-wayland # text expander
|
||||
];
|
||||
}; # end sway
|
||||
uwsm = { # responsible for creating xdg-portal and systemd insteraction for sway
|
||||
enable = true;
|
||||
waylandCompositors = {
|
||||
sway = {
|
||||
prettyName = "Sway";
|
||||
comment = "Sway compositor managed by UWSM";
|
||||
binPath = "${pkgs.sway}/bin/sway";
|
||||
extraArgs = [ "--unsupported-gpu" ];
|
||||
};
|
||||
};
|
||||
}; # end uwsm
|
||||
light = {
|
||||
enable = true;
|
||||
}; # end light
|
||||
dconf.enable = true;
|
||||
seahorse.enable = true;
|
||||
}; # end programs
|
||||
security = {
|
||||
polkit.enable = true;
|
||||
pam.services = {
|
||||
greetd.enableGnomeKeyring = true;
|
||||
#greetd-password.enableGnomeKeyring = true;
|
||||
login.enableGnomeKeyring = true;
|
||||
swaylock = {
|
||||
text = ''
|
||||
auth sufficient pam_unix.so try_first_pass likeauth nullok
|
||||
auth sufficient pam_fprintd.so
|
||||
auth include login
|
||||
'';
|
||||
}; # end swaylock
|
||||
}; # end pam.services
|
||||
}; # end security
|
||||
services = {
|
||||
greetd = {
|
||||
enable = true;
|
||||
settings = {
|
||||
initial_session = {
|
||||
command = "uwsm start -- sway-uwsm.desktop";
|
||||
user = "alisceon";
|
||||
}; # end initial_session
|
||||
default_session = {
|
||||
command = "${pkgs.tuigreet}/bin/tuigreet --time --cmd 'uwsm start -- sway-uwsm.desktop' --remember --asterisks''";
|
||||
user = "greeter";
|
||||
}; # end initial_session
|
||||
}; # end settings
|
||||
}; # end greetd
|
||||
logind = {
|
||||
settings = {
|
||||
Login = {
|
||||
HandleLidSwitch = "suspend";
|
||||
HandleLidSwitchExternalPower = "suspend";
|
||||
};
|
||||
};
|
||||
}; # end logind
|
||||
dbus.packages = [ pkgs.seahorse pkgs.gnome-keyring pkgs.gcr ];
|
||||
gnome.gcr-ssh-agent.enable = true; # SSH key management via gnome keyring
|
||||
gvfs.enable = true; # some support for nautilus operations
|
||||
}; # end services
|
||||
users.users.alisceon.extraGroups = [ "video" "input" ]; # input group required for libinput-gestures
|
||||
}
|
||||
|
|
@ -1,6 +0,0 @@
|
|||
{ ... }:
|
||||
{
|
||||
imports = [
|
||||
./common/default.nix
|
||||
];
|
||||
} # end file
|
||||
|
|
@ -1,43 +0,0 @@
|
|||
{ config, pkgs, ... }:
|
||||
|
||||
{
|
||||
imports =
|
||||
[ ./hardware-configuration.nix ];
|
||||
networking.hostName = "electra";
|
||||
boot = {
|
||||
loader.systemd-boot.enable = true;
|
||||
loader.efi.canTouchEfiVariables = true;
|
||||
initrd = {
|
||||
enable = true;
|
||||
luks.devices."luks-654125f4-7b26-408d-b1b5-d31648ec8770".device = "/dev/disk/by-uuid/654125f4-7b26-408d-b1b5-d31648ec8770";
|
||||
verbose = false;
|
||||
};
|
||||
#resumeDevice = "/dev/disk/by-uuid/c49249b9-0d68-44af-97e0-e399c8409408";
|
||||
}; # end boot
|
||||
environment.systemPackages = [
|
||||
pkgs.bluetui
|
||||
pkgs.wakeonlan
|
||||
];
|
||||
systemd.services = {
|
||||
fprintd = {
|
||||
wantedBy = [ "multi-user.target" ];
|
||||
serviceConfig.Type = "simple";
|
||||
};
|
||||
}; # end systemd.services
|
||||
services = {
|
||||
fprintd = {
|
||||
enable = true;
|
||||
tod.enable = true;
|
||||
tod.driver = pkgs.libfprint-2-tod1-goodix;
|
||||
}; # end fprintd
|
||||
tuned = {
|
||||
enable = true;
|
||||
}; # end tuned
|
||||
}; # end services
|
||||
hardware = {
|
||||
bluetooth = {
|
||||
enable = true;
|
||||
powerOnBoot = true;
|
||||
}; # end bluetooth
|
||||
}; # end hardware
|
||||
} # end file
|
||||
|
|
@ -1,6 +0,0 @@
|
|||
{ ... }:
|
||||
{
|
||||
imports = [
|
||||
../electra/configuration.nix
|
||||
];
|
||||
} # end file
|
||||
|
|
@ -1,6 +0,0 @@
|
|||
{ ... }:
|
||||
{
|
||||
imports = [
|
||||
../nuc/configuration.nix
|
||||
];
|
||||
} # end file
|
||||
|
|
@ -1,6 +0,0 @@
|
|||
{ ... }:
|
||||
{
|
||||
imports = [
|
||||
../tesla-nixos/configuration.nix
|
||||
];
|
||||
} # end file
|
||||
|
|
@ -1,6 +0,0 @@
|
|||
{ ... }:
|
||||
{
|
||||
imports = [
|
||||
../tower/configuration.nix
|
||||
];
|
||||
} # end file
|
||||
|
|
@ -1,6 +0,0 @@
|
|||
{ ... }:
|
||||
{
|
||||
imports = [
|
||||
../common/stylix.nix
|
||||
];
|
||||
} # end file
|
||||
|
|
@ -1,6 +0,0 @@
|
|||
{ ... }:
|
||||
{
|
||||
imports = [
|
||||
../../../common/wm/gnome.nix
|
||||
];
|
||||
} # end file
|
||||
|
|
@ -1,6 +0,0 @@
|
|||
{ ... }:
|
||||
{
|
||||
imports = [
|
||||
../../../common/wm/sway.nix
|
||||
];
|
||||
} # end file
|
||||
|
|
@ -1,65 +0,0 @@
|
|||
{ config, pkgs, lib, ... }:
|
||||
|
||||
{
|
||||
environment.systemPackages = with pkgs; [
|
||||
wakeonlan
|
||||
];
|
||||
security.sudo.wheelNeedsPassword = false;
|
||||
imports =
|
||||
[ ./hardware-configuration.nix ];
|
||||
networking.hostName = "nuc";
|
||||
boot.initrd.enable = true;
|
||||
boot.loader = {
|
||||
systemd-boot = {
|
||||
enable = true;
|
||||
}; # end loader.systemd-boot
|
||||
}; # end boot
|
||||
virtualisation = {
|
||||
oci-containers = {
|
||||
containers = {
|
||||
}; # end containers
|
||||
}; # end oci-containers
|
||||
}; # end virtualisation
|
||||
networking.firewall.allowedTCPPorts = [
|
||||
53
|
||||
80
|
||||
443
|
||||
];
|
||||
networking.firewall.allowedUDPPorts = [
|
||||
53
|
||||
];
|
||||
systemd = {
|
||||
timers = {
|
||||
"autowin" = {
|
||||
wantedBy = [ "timers.target" ];
|
||||
timerConfig = {
|
||||
OnCalendar = "Wed *-*-21..28 02:00:00";
|
||||
Unit = "autowin.service";
|
||||
};
|
||||
};
|
||||
}; # end timers
|
||||
|
||||
services = {
|
||||
"autowin" = {
|
||||
script = ''
|
||||
${pkgs.python3Packages.python}/bin/python /home/alisceon/.nixos_config/util/wol_man.py autowin
|
||||
'';
|
||||
serviceConfig = {
|
||||
Type = "oneshot";
|
||||
TimeoutStartSec = "3600";
|
||||
User = "alisceon";
|
||||
};
|
||||
}; # end "hello-world"
|
||||
}; # end services
|
||||
}; # end systemd
|
||||
virtualisation.oci-containers.containers = {
|
||||
isponsorblocktv = {
|
||||
image = "ghcr.io/dmunozv04/isponsorblocktv:latest";
|
||||
autoStart = true;
|
||||
volumes = [
|
||||
"/home/alisceon/isponsorblocktv:/app/data"
|
||||
];
|
||||
}; # end isponsorblocktv
|
||||
};
|
||||
} # end file
|
||||
|
||||
|
|
@ -1,6 +0,0 @@
|
|||
{ ... }:
|
||||
{
|
||||
imports = [
|
||||
./common/server.nix
|
||||
];
|
||||
} # end file
|
||||
|
|
@ -1,6 +0,0 @@
|
|||
{ ... }:
|
||||
{
|
||||
imports = [
|
||||
./common/workstation.nix
|
||||
];
|
||||
} # end file
|
||||
40
nixos/hosts/electra/configuration.nix
Normal file
40
nixos/hosts/electra/configuration.nix
Normal file
|
|
@ -0,0 +1,40 @@
|
|||
{ pkgs, ... }:
|
||||
{
|
||||
imports = [ ./hardware-configuration.nix ];
|
||||
|
||||
networking.hostName = "electra";
|
||||
|
||||
boot = {
|
||||
loader.systemd-boot.enable = true;
|
||||
loader.efi.canTouchEfiVariables = true;
|
||||
initrd = {
|
||||
enable = true;
|
||||
luks.devices."luks-654125f4-7b26-408d-b1b5-d31648ec8770".device = "/dev/disk/by-uuid/654125f4-7b26-408d-b1b5-d31648ec8770";
|
||||
verbose = false;
|
||||
};
|
||||
};
|
||||
|
||||
environment.systemPackages = [
|
||||
pkgs.bluetui
|
||||
pkgs.wakeonlan
|
||||
];
|
||||
|
||||
systemd.services.fprintd = {
|
||||
wantedBy = [ "multi-user.target" ];
|
||||
serviceConfig.Type = "simple";
|
||||
};
|
||||
|
||||
services = {
|
||||
fprintd = {
|
||||
enable = true;
|
||||
tod.enable = true;
|
||||
tod.driver = pkgs.libfprint-2-tod1-goodix;
|
||||
};
|
||||
tuned.enable = true;
|
||||
};
|
||||
|
||||
hardware.bluetooth = {
|
||||
enable = true;
|
||||
powerOnBoot = true;
|
||||
};
|
||||
}
|
||||
48
nixos/hosts/nuc/configuration.nix
Normal file
48
nixos/hosts/nuc/configuration.nix
Normal file
|
|
@ -0,0 +1,48 @@
|
|||
{ pkgs, repoRoot, ... }:
|
||||
{
|
||||
imports = [ ./hardware-configuration.nix ];
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
wakeonlan
|
||||
];
|
||||
|
||||
security.sudo.wheelNeedsPassword = false;
|
||||
networking.hostName = "nuc";
|
||||
|
||||
boot.initrd.enable = true;
|
||||
boot.loader.systemd-boot.enable = true;
|
||||
|
||||
networking.firewall.allowedTCPPorts = [
|
||||
53
|
||||
80
|
||||
443
|
||||
];
|
||||
networking.firewall.allowedUDPPorts = [ 53 ];
|
||||
|
||||
systemd.timers.autowin = {
|
||||
wantedBy = [ "timers.target" ];
|
||||
timerConfig = {
|
||||
OnCalendar = "Wed *-*-21..28 02:00:00";
|
||||
Unit = "autowin.service";
|
||||
};
|
||||
};
|
||||
|
||||
systemd.services.autowin = {
|
||||
script = ''
|
||||
${pkgs.python3Packages.python}/bin/python ${repoRoot}/util/wol_man.py autowin
|
||||
'';
|
||||
serviceConfig = {
|
||||
Type = "oneshot";
|
||||
TimeoutStartSec = "3600";
|
||||
User = "alisceon";
|
||||
};
|
||||
};
|
||||
|
||||
virtualisation.oci-containers.containers.isponsorblocktv = {
|
||||
image = "ghcr.io/dmunozv04/isponsorblocktv:latest";
|
||||
autoStart = true;
|
||||
volumes = [
|
||||
"/home/alisceon/isponsorblocktv:/app/data"
|
||||
];
|
||||
};
|
||||
}
|
||||
|
|
@ -1,5 +1,4 @@
|
|||
{ config, pkgs, lib, ... }:
|
||||
|
||||
{ pkgs, ... }:
|
||||
let
|
||||
modpack = pkgs.fetchPackwizModpack {
|
||||
url = "https://git.malice.zone/alisceon/tfcpack/-/raw/main/pack.toml";
|
||||
|
|
@ -7,19 +6,18 @@ let
|
|||
};
|
||||
in
|
||||
{
|
||||
imports = [ ./hardware-configuration.nix ];
|
||||
|
||||
security.sudo.wheelNeedsPassword = false;
|
||||
imports =
|
||||
[ ./hardware-configuration.nix ];
|
||||
networking.hostName = "tesla-nixos";
|
||||
boot.initrd.enable = true;
|
||||
boot.loader = {
|
||||
systemd-boot = {
|
||||
enable = true;
|
||||
}; # end loader.systemd-boot
|
||||
}; # end boot
|
||||
environment.systemPackages = with pkgs; [
|
||||
tmux
|
||||
]; # end environment.systemPackages
|
||||
|
||||
boot = {
|
||||
initrd.enable = true;
|
||||
loader.systemd-boot.enable = true;
|
||||
};
|
||||
|
||||
environment.systemPackages = with pkgs; [ tmux ];
|
||||
|
||||
virtualisation.podman.dockerCompat = false;
|
||||
virtualisation.docker = {
|
||||
enable = true;
|
||||
|
|
@ -28,19 +26,17 @@ in
|
|||
dates = "daily";
|
||||
};
|
||||
daemon.settings = {
|
||||
"runtimes" = {
|
||||
crun = { path = "${pkgs.crun}/bin/crun"; };
|
||||
};
|
||||
"default-runtime" = "crun";
|
||||
runtimes.crun.path = "${pkgs.crun}/bin/crun";
|
||||
default-runtime = "crun";
|
||||
};
|
||||
};
|
||||
|
||||
networking.firewall.allowedTCPPorts = [
|
||||
8100 #bluemap
|
||||
8100
|
||||
];
|
||||
|
||||
|
||||
services.minecraft-servers = {
|
||||
enable = true;
|
||||
#managementSystem.systemd-socket.enable = true;
|
||||
eula = true;
|
||||
openFirewall = true;
|
||||
servers.tfcpack = {
|
||||
|
|
@ -48,27 +44,23 @@ in
|
|||
package = pkgs.neoforgeServers.neoforge-1_21_1-21_1_219;
|
||||
autoStart = true;
|
||||
serverProperties = {
|
||||
"motd" = "TFC Pack - Tesla Nixos";
|
||||
"max-players" = "20";
|
||||
"view-distance" = "32";
|
||||
"level-type" = "tfc\:overworld";
|
||||
"spawn-protection" = "0";
|
||||
"max-tick-time" = "-1";
|
||||
motd = "TFC Pack - Tesla Nixos";
|
||||
max-players = "20";
|
||||
view-distance = "32";
|
||||
level-type = "tfc\\:overworld";
|
||||
spawn-protection = "0";
|
||||
max-tick-time = "-1";
|
||||
};
|
||||
jvmOpts = [
|
||||
jvmOpts = [
|
||||
"-Xmx24G"
|
||||
"-Xms24G"
|
||||
"-XX:+UseZGC"
|
||||
"-XX:+ZGenerational"
|
||||
];
|
||||
symlinks = {
|
||||
"mods" = "${modpack}/mods";
|
||||
}; # end symlinks
|
||||
files = {
|
||||
"config/bluemap/core.conf" = "${modpack}/config/bluemap/core.conf";
|
||||
};# end symlinks
|
||||
}; # end servers.tfcpack
|
||||
}; # end services.minecraft-servers
|
||||
symlinks.mods = "${modpack}/mods";
|
||||
files."config/bluemap/core.conf" = "${modpack}/config/bluemap/core.conf";
|
||||
};
|
||||
};
|
||||
|
||||
users.users.gitlab-runner = {
|
||||
isNormalUser = true;
|
||||
|
|
@ -78,9 +70,11 @@ in
|
|||
extraGroups = [ "docker" "wheel" ];
|
||||
group = "gitlab-runner";
|
||||
};
|
||||
|
||||
users.groups.gitlab-runner = { };
|
||||
users.groups.docker = { };
|
||||
systemd.services."enable-linger-gitlab-runner" = {
|
||||
|
||||
systemd.services.enable-linger-gitlab-runner = {
|
||||
description = "Enable linger for gitlab-runner";
|
||||
wantedBy = [ "multi-user.target" ];
|
||||
serviceConfig = {
|
||||
|
|
@ -90,20 +84,16 @@ in
|
|||
};
|
||||
};
|
||||
|
||||
# GitLab Runner configured to use the local Docker daemon
|
||||
services.gitlab-runner = {
|
||||
enable = true;
|
||||
services = {
|
||||
ci-nspawn-docker = {
|
||||
authenticationTokenConfigFile = "/var/lib/gitlab-runner/token-env";
|
||||
executor = "docker";
|
||||
dockerImage = "alpine:3";
|
||||
dockerPrivileged = true;
|
||||
dockerVolumes = [
|
||||
"/var/lib/gitlab-runner/cache:/cache"
|
||||
];
|
||||
};
|
||||
services.ci-nspawn-docker = {
|
||||
authenticationTokenConfigFile = "/var/lib/gitlab-runner/token-env";
|
||||
executor = "docker";
|
||||
dockerImage = "alpine:3";
|
||||
dockerPrivileged = true;
|
||||
dockerVolumes = [
|
||||
"/var/lib/gitlab-runner/cache:/cache"
|
||||
];
|
||||
};
|
||||
};
|
||||
} # end file
|
||||
|
||||
}
|
||||
|
|
@ -1,18 +1,15 @@
|
|||
{ config, pkgs, pkgs-unstable, ... }:
|
||||
|
||||
{ config, pkgs, ... }:
|
||||
{
|
||||
imports =
|
||||
[ ./hardware-configuration.nix ];
|
||||
imports = [ ./hardware-configuration.nix ];
|
||||
|
||||
networking = {
|
||||
hostName = "tower";
|
||||
interfaces.enp10s0.wakeOnLan = {
|
||||
enable = true;
|
||||
};
|
||||
firewall = {
|
||||
allowedUDPPorts = [ 9 ];
|
||||
};
|
||||
interfaces.enp10s0.wakeOnLan.enable = true;
|
||||
firewall.allowedUDPPorts = [ 9 ];
|
||||
};
|
||||
|
||||
time.hardwareClockInLocalTime = true;
|
||||
|
||||
boot = {
|
||||
initrd.enable = true;
|
||||
loader = {
|
||||
|
|
@ -25,20 +22,21 @@
|
|||
efiDeviceHandle = "FS0";
|
||||
sortKey = "1";
|
||||
};
|
||||
}; #end windows
|
||||
};
|
||||
edk2-uefi-shell = {
|
||||
enable = true;
|
||||
sortKey = "0";
|
||||
}; # end edk2-uefi-shell
|
||||
}; # end systemd-boot
|
||||
}; # end loader
|
||||
};
|
||||
};
|
||||
};
|
||||
kernelPackages = pkgs.linuxPackages_6_18;
|
||||
}; # end boot
|
||||
};
|
||||
|
||||
hardware = {
|
||||
graphics.enable = true;
|
||||
graphics.extraPackages = with pkgs; [
|
||||
nvidia-vaapi-driver
|
||||
]; # end graphics.extraPackages
|
||||
graphics = {
|
||||
enable = true;
|
||||
extraPackages = with pkgs; [ nvidia-vaapi-driver ];
|
||||
};
|
||||
nvidia = {
|
||||
modesetting.enable = true;
|
||||
powerManagement.enable = false;
|
||||
|
|
@ -46,17 +44,19 @@
|
|||
open = true;
|
||||
nvidiaSettings = true;
|
||||
package = config.boot.kernelPackages.nvidiaPackages.stable;
|
||||
}; # end nvidia
|
||||
}; # end hardware
|
||||
};
|
||||
};
|
||||
|
||||
services = {
|
||||
xserver.videoDrivers = [ "nvidia" ];
|
||||
openssh.enable = true;
|
||||
}; # end services
|
||||
};
|
||||
|
||||
environment = {
|
||||
variables = {
|
||||
GBM_BACKEND = "nvidia-drm";
|
||||
__GLX_VENDOR_LIBRARY_NAME = "nvidia";
|
||||
MOZ_DISABLE_RDD_SANDBOX= "1" ;
|
||||
MOZ_DISABLE_RDD_SANDBOX = "1";
|
||||
LIBVA_DRIVER_NAME = "nvidia";
|
||||
};
|
||||
systemPackages = [
|
||||
|
|
@ -66,6 +66,7 @@
|
|||
pkgs.gamescope
|
||||
];
|
||||
};
|
||||
|
||||
programs = {
|
||||
gamemode.enable = true;
|
||||
steam = {
|
||||
|
|
@ -73,10 +74,8 @@
|
|||
remotePlay.openFirewall = true;
|
||||
extraCompatPackages = [ pkgs.proton-ge-bin ];
|
||||
package = pkgs.steam.override {
|
||||
extraPkgs = (pkgs: [
|
||||
pkgs.gamemode
|
||||
]);
|
||||
extraPkgs = _pkgs: [ pkgs.gamemode ];
|
||||
};
|
||||
};
|
||||
};
|
||||
} # end file
|
||||
}
|
||||
|
|
@ -1,59 +1,62 @@
|
|||
{ config, pkgs, pkgs-unstable, lib, ... }: {
|
||||
{ config, pkgs, lib, repoLocalPath, ... }:
|
||||
{
|
||||
boot = {
|
||||
kernelPackages = lib.mkDefault pkgs.linuxPackages_latest;
|
||||
kernel.sysctl = {
|
||||
"net.ipv4.ip_unprivileged_port_start" = 0;
|
||||
};
|
||||
initrd = {
|
||||
network ={
|
||||
initrd = {
|
||||
network = {
|
||||
ssh.shell = pkgs.bash;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
security.sudo-rs.enable = true;
|
||||
system.stateVersion = "24.05";
|
||||
|
||||
system.autoUpgrade = {
|
||||
enable = true;
|
||||
persistent = true;
|
||||
flake = "/home/alisceon/.nixos_config";
|
||||
flake = repoLocalPath;
|
||||
flags = [
|
||||
"--print-build-logs"
|
||||
"--no-write-lock-file"
|
||||
];
|
||||
dates = "daily";
|
||||
}; # end system.autoUpgrade
|
||||
};
|
||||
|
||||
nix = {
|
||||
settings = {
|
||||
experimental-features = [ "nix-command" "flakes" ];
|
||||
auto-optimise-store = true;
|
||||
trusted-users = [ "root" "alisceon" ];
|
||||
}; # end settings
|
||||
};
|
||||
gc = {
|
||||
automatic = true;
|
||||
persistent = true;
|
||||
dates = "daily";
|
||||
options = "--delete-older-than 7d";
|
||||
}; # end gc
|
||||
};
|
||||
registry = {
|
||||
templates.to = {
|
||||
type = "git";
|
||||
url = "git+ssh://git@git.malice.zone/alisceon/devenv_templates.git";
|
||||
}; # end templates.to
|
||||
};
|
||||
nixpkgs.to = {
|
||||
type = "github";
|
||||
owner = "NixOS";
|
||||
repo = "nixpkgs";
|
||||
ref = "nixos-unstable";
|
||||
}; # end nixpkgs.to
|
||||
};
|
||||
nixpkgs-stable.to = {
|
||||
type = "github";
|
||||
owner = "NixOS";
|
||||
repo = "nixpkgs";
|
||||
ref = "nixos-25.05";
|
||||
}; # end nixpkgs.to
|
||||
}; #end registry
|
||||
}; #end nix
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
console.keyMap = "sv-latin1";
|
||||
networking.networkmanager.enable = true;
|
||||
|
|
@ -73,93 +76,79 @@
|
|||
|
||||
environment = {
|
||||
systemPackages = with pkgs; [
|
||||
# Libraries
|
||||
libressl
|
||||
|
||||
# CLI tools
|
||||
git
|
||||
wget
|
||||
curl
|
||||
btop # system monitor
|
||||
ripgrep # grep replacement
|
||||
fd # find replacement
|
||||
nh # nix helper
|
||||
jq # JSON processor
|
||||
btop
|
||||
ripgrep
|
||||
fd
|
||||
nh
|
||||
jq
|
||||
ncdu
|
||||
pciutils
|
||||
usbutils
|
||||
tree
|
||||
fzf # fuzzy finder
|
||||
fzf
|
||||
psmisc
|
||||
pv
|
||||
file
|
||||
nix-tree
|
||||
unzip
|
||||
lsd
|
||||
|
||||
# Shells
|
||||
lsd
|
||||
bash
|
||||
nushell
|
||||
fish
|
||||
powershell
|
||||
|
||||
# Languages
|
||||
python3
|
||||
python3Packages.python-lsp-server
|
||||
podman
|
||||
];
|
||||
|
||||
# Virtualization
|
||||
podman
|
||||
]; # end systemPackages
|
||||
|
||||
shells = with pkgs; [
|
||||
shells = with pkgs; [
|
||||
bash
|
||||
nushell
|
||||
fish
|
||||
powershell
|
||||
xonsh
|
||||
];
|
||||
|
||||
etc."current-system-packages".text =
|
||||
let
|
||||
packages = builtins.map (p: "${p.name}:\t${p}") config.environment.systemPackages;
|
||||
sortedUnique = builtins.sort builtins.lessThan (pkgs.lib.lists.unique packages);
|
||||
formatted = pkgs.lib.strings.concatLines sortedUnique;
|
||||
in
|
||||
formatted;
|
||||
}; # end environment
|
||||
let
|
||||
packages = builtins.map (p: "${p.name}:\t${p}") config.environment.systemPackages;
|
||||
sortedUnique = builtins.sort builtins.lessThan (pkgs.lib.lists.unique packages);
|
||||
in
|
||||
pkgs.lib.strings.concatLines sortedUnique;
|
||||
};
|
||||
|
||||
virtualisation = {
|
||||
#spiceUSBRedirection.enable = true;
|
||||
libvirtd = {
|
||||
enable = true;
|
||||
qemu = {
|
||||
swtpm.enable = true;
|
||||
};
|
||||
qemu.swtpm.enable = true;
|
||||
};
|
||||
containers.enable = true;
|
||||
docker = {
|
||||
enable = true;
|
||||
};
|
||||
docker.enable = true;
|
||||
podman = {
|
||||
enable = true;
|
||||
dockerCompat = false;
|
||||
defaultNetwork.settings.dns_enabled = true;
|
||||
}; # end podman
|
||||
};
|
||||
oci-containers.backend = "podman";
|
||||
}; # end virtualisation
|
||||
};
|
||||
|
||||
users = {
|
||||
defaultUserShell = pkgs.bash;
|
||||
groups.docker = {};
|
||||
groups.docker = { };
|
||||
users.alisceon = {
|
||||
isNormalUser = true;
|
||||
extraGroups = [ "wheel" "networkmanager" "podman" "docker" "libvirtd"];
|
||||
extraGroups = [ "wheel" "networkmanager" "podman" "docker" "libvirtd" ];
|
||||
shell = pkgs.xonsh;
|
||||
openssh.authorizedKeys.keys = [
|
||||
"ecdsa-sha2-nistp256 AAAAE2VjZHNhLXNoYTItbmlzdHAyNTYAAAAIbmlzdHAyNTYAAABBBPN1Cd2UlHo03Jqgi5Yb4io/3gh/X4wCb8LcmKlpAovQa271CKDBtYOUKn+Fts03g6dBMfaWMty6VGPMGDMONmc= alisceon@electra"
|
||||
"ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAACAQCvRYyYjN8z0yoPrHtaTQXY0iEtPl79K6/uXVceuS+31JGjRnqJjuDYg6KxAykGSfhercNdAJ2BTYJRGpMsW0Xn7+iq07TItcjJjERm7rjQZko4vauS62NdnV6BEG+6ktasb9CcepzwoRkLEXQOad3XbLbo0V2sj6uI5Rgq2Cfh6f9x1E1DJ87o6Ngkm+vQzdv4NYeya/O4vuoAw6BNhp4vyr9k+0K+TRLjflYPUwtb8U/agoYI5RoLZMa6eBKdPbLVYyahpMlYjHwr90H4c9veHliILcDSA8h6upcXSDwZiCPyu6cI4zRbzGQVg84iLmIs5ocMWsnuDQbqn5iM3BTV37atnTPI3O2C9WBxuOaGpk4C338V0CAfTo6GG/OSaFzfLBFE29nY6uXcCPH7KiDpig0naVWlpHZhED5OQRoSXBeyu4BgadV6eZ43HOcdbOAqbLcB1nvkKPi52Vj+JqwS8zIjQpipX22Trx2u4ike99ijeK6/XeoTnEAcUS0fcYQ0FDqqfLmr/HuxkEQ2NZF0sFFqVGUlpVJMFblNOH4L8A2kApnsrmlxnlVE+r0tTnnnK5tfCpyou/LPDM+4TzGw2nV2cwsZKbGaHvMM/qIvVva90mTcYfuDvGB10eQ2P9tN1TIjseONVLDVKNjNGzDBFY4RMeMJOWWQy0aBh0FP5Q== user@hannah.afk"
|
||||
];
|
||||
};
|
||||
}; # end users
|
||||
};
|
||||
};
|
||||
|
||||
programs = {
|
||||
command-not-found.enable = true;
|
||||
|
|
@ -173,30 +162,30 @@
|
|||
pkgs.nur.repos.xonsh-xontribs.xontrib-abbrevs
|
||||
pkgs.nur.repos.xonsh-xontribs.xontrib-clp
|
||||
pkgs.nur.repos.xonsh-xontribs.xontrib-bashisms
|
||||
(
|
||||
ps.buildPythonPackage
|
||||
rec {
|
||||
name = "xontrib-fzf-completions";
|
||||
version = "v0.0.2";
|
||||
format = "pyproject";
|
||||
(
|
||||
ps.buildPythonPackage
|
||||
rec {
|
||||
name = "xontrib-fzf-completions";
|
||||
version = "v0.0.2";
|
||||
format = "pyproject";
|
||||
nativeBuildInputs = [ ps.setuptools ps.setuptools-scm ps.wheel ];
|
||||
propagatedBuildInputs = [ ps.xonsh ];
|
||||
src = pkgs.fetchFromGitHub {
|
||||
owner = "doronz88";
|
||||
repo = "${name}";
|
||||
rev = "${version}";
|
||||
sha256 = "sha256-1z5xHX4Psevn8686QkwIzv/LOJ5IMJc2nQ5Hg/2svTc=";
|
||||
};
|
||||
meta = {
|
||||
homepage = "https://github.com/doronz88/xontrib-fzf-completions";
|
||||
description = "fuzzy completions for xonsh";
|
||||
license = pkgs.lib.licenses.mit;
|
||||
maintainers = [ ];
|
||||
}; # end meta
|
||||
} # end buildPythonPackage
|
||||
)
|
||||
]; # end extraPackages
|
||||
config = (builtins.readFile ../../home/conf/xonsh/xonshrc);
|
||||
}; # end xonsh
|
||||
}; # end programs
|
||||
} #end file
|
||||
propagatedBuildInputs = [ ps.xonsh ];
|
||||
src = pkgs.fetchFromGitHub {
|
||||
owner = "doronz88";
|
||||
repo = "${name}";
|
||||
rev = "${version}";
|
||||
sha256 = "sha256-1z5xHX4Psevn8686QkwIzv/LOJ5IMJc2nQ5Hg/2svTc=";
|
||||
};
|
||||
meta = {
|
||||
homepage = "https://github.com/doronz88/xontrib-fzf-completions";
|
||||
description = "fuzzy completions for xonsh";
|
||||
license = pkgs.lib.licenses.mit;
|
||||
maintainers = [ ];
|
||||
};
|
||||
}
|
||||
)
|
||||
];
|
||||
config = builtins.readFile ../../home/conf/xonsh/xonshrc;
|
||||
};
|
||||
};
|
||||
}
|
||||
14
nixos/modules/profiles/server.nix
Normal file
14
nixos/modules/profiles/server.nix
Normal file
|
|
@ -0,0 +1,14 @@
|
|||
{ pkgs, ... }:
|
||||
{
|
||||
system.autoUpgrade.allowReboot = true;
|
||||
|
||||
services.openssh = {
|
||||
enable = true;
|
||||
permitRootLogin = "no";
|
||||
};
|
||||
|
||||
environment.systemPackages = with pkgs; [
|
||||
devenv
|
||||
direnv
|
||||
];
|
||||
}
|
||||
|
|
@ -1,5 +1,4 @@
|
|||
{ config, pkgs, pkgs-unstable, ... }:
|
||||
|
||||
{ pkgs, pkgs-unstable, ... }:
|
||||
{
|
||||
boot = {
|
||||
plymouth.enable = true;
|
||||
|
|
@ -9,6 +8,7 @@
|
|||
"systemd.show_status=auto"
|
||||
];
|
||||
};
|
||||
|
||||
security.sudo.wheelNeedsPassword = false;
|
||||
|
||||
services = {
|
||||
|
|
@ -25,7 +25,6 @@
|
|||
gnome-keyring.enable = true;
|
||||
gnome-initial-setup.enable = false;
|
||||
};
|
||||
# For keychron
|
||||
udev.packages = [
|
||||
pkgs.via
|
||||
pkgs.qmk
|
||||
|
|
@ -34,11 +33,9 @@
|
|||
];
|
||||
fwupd.enable = true;
|
||||
openssh.settings.PasswordAuthentication = false;
|
||||
}; # end services
|
||||
};
|
||||
|
||||
programs = {
|
||||
dconf.enable = true;
|
||||
}; # end programs
|
||||
programs.dconf.enable = true;
|
||||
|
||||
networking.firewall.allowedTCPPorts = [
|
||||
1312
|
||||
|
|
@ -46,25 +43,18 @@
|
|||
8080
|
||||
8888
|
||||
];
|
||||
|
||||
|
||||
environment = {
|
||||
systemPackages = [
|
||||
# Chat
|
||||
pkgs.discord
|
||||
pkgs.signal-desktop
|
||||
pkgs.mumble
|
||||
|
||||
# Browser
|
||||
(pkgs.chromium.override { enableWideVine = true; })
|
||||
pkgs.google-chrome
|
||||
|
||||
# Development
|
||||
pkgs.vscodium
|
||||
pkgs.codex
|
||||
pkgs.devenv
|
||||
pkgs.direnv
|
||||
|
||||
# Other
|
||||
pkgs.syncthing
|
||||
pkgs.steam
|
||||
pkgs.krita
|
||||
|
|
@ -75,8 +65,8 @@
|
|||
pkgs.via
|
||||
pkgs.plymouth
|
||||
pkgs.xorg.xhost
|
||||
(pkgs.bottles.override { removeWarningPopup = true;})
|
||||
]; # end systemPackages
|
||||
sessionVariables.NIXOS_OZONE_WL = "1";
|
||||
}; # end environment
|
||||
} #end file
|
||||
(pkgs.bottles.override { removeWarningPopup = true; })
|
||||
];
|
||||
sessionVariables.NIXOS_OZONE_WL = "1";
|
||||
};
|
||||
}
|
||||
|
|
@ -1,10 +1,10 @@
|
|||
{ config, pkgs, lib, ... }:
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
stylix = {
|
||||
stylix = {
|
||||
enable = true;
|
||||
autoEnable = true;
|
||||
enableReleaseChecks = false;
|
||||
base16Scheme = { # based on https://github.com/tinted-theming/schemes/blob/spec-0.11/base16/selenized-black.yaml
|
||||
base16Scheme = {
|
||||
base00 = "#181818";
|
||||
base01 = "#252525";
|
||||
base02 = "#3b3b3b";
|
||||
|
|
@ -21,7 +21,7 @@ stylix = {
|
|||
base0D = "#a580e2";
|
||||
base0E = "#368aeb";
|
||||
base0F = "#eb6eb7";
|
||||
};
|
||||
};
|
||||
|
||||
polarity = "dark";
|
||||
fonts = {
|
||||
|
|
@ -48,16 +48,18 @@ stylix = {
|
|||
popups = 14;
|
||||
};
|
||||
};
|
||||
|
||||
cursor = {
|
||||
package = pkgs.whitesur-cursors;
|
||||
name = "WhiteSur-cursors";
|
||||
size = 20;
|
||||
};
|
||||
|
||||
icons = {
|
||||
enable = true;
|
||||
package = pkgs.whitesur-icon-theme;
|
||||
light = "WhiteSur-light";
|
||||
dark = "WhiteSur-dark";
|
||||
};
|
||||
}; # end stylix
|
||||
};
|
||||
}
|
||||
|
|
@ -1,10 +1,8 @@
|
|||
{ config, pkgs, ... }:
|
||||
|
||||
{ pkgs, ... }:
|
||||
{
|
||||
security.sudo.wheelNeedsPassword = false;
|
||||
|
||||
services = {
|
||||
# Remove xserver. when the patch comes
|
||||
xserver.displayManager = {
|
||||
gdm.enable = true;
|
||||
gdm.wayland = true;
|
||||
|
|
@ -14,7 +12,7 @@
|
|||
gnome-keyring.enable = true;
|
||||
gnome-initial-setup.enable = false;
|
||||
};
|
||||
}; # end services
|
||||
};
|
||||
|
||||
environment = {
|
||||
gnome.excludePackages = with pkgs; [
|
||||
|
|
@ -29,13 +27,12 @@
|
|||
gnome-calendar
|
||||
gnome-initial-setup
|
||||
gnome-clocks
|
||||
]; # end gnome.excludePackages
|
||||
];
|
||||
|
||||
systemPackages = [
|
||||
# GNOME tweaks and extensions
|
||||
pkgs.gnome-tweaks
|
||||
pkgs.dconf-editor
|
||||
pkgs.gnomeExtensions.ddterm
|
||||
]; # end systemPackages
|
||||
}; # end environment
|
||||
} #end file
|
||||
];
|
||||
};
|
||||
}
|
||||
99
nixos/modules/wm/sway.nix
Normal file
99
nixos/modules/wm/sway.nix
Normal file
|
|
@ -0,0 +1,99 @@
|
|||
{ pkgs, ... }:
|
||||
{
|
||||
environment.systemPackages = with pkgs; [
|
||||
pavucontrol
|
||||
libinput
|
||||
libinput-gestures
|
||||
libnotify
|
||||
wmctrl
|
||||
playerctl
|
||||
xdg-utils
|
||||
shared-mime-info
|
||||
libsecret
|
||||
gnome-text-editor
|
||||
loupe
|
||||
evince
|
||||
seahorse
|
||||
nautilus
|
||||
];
|
||||
|
||||
programs = {
|
||||
sway = {
|
||||
enable = true;
|
||||
wrapperFeatures.base = true;
|
||||
wrapperFeatures.gtk = true;
|
||||
extraOptions = [ "--unsupported-gpu" ];
|
||||
extraPackages = with pkgs; [
|
||||
swayidle
|
||||
swaylock
|
||||
swaybg
|
||||
grim
|
||||
slurp
|
||||
wl-clipboard
|
||||
pulseaudio
|
||||
sway-contrib.grimshot
|
||||
foot
|
||||
kitty
|
||||
dotool
|
||||
mako
|
||||
espanso-wayland
|
||||
];
|
||||
};
|
||||
|
||||
uwsm = {
|
||||
enable = true;
|
||||
waylandCompositors = {
|
||||
sway = {
|
||||
prettyName = "Sway";
|
||||
comment = "Sway compositor managed by UWSM";
|
||||
binPath = "${pkgs.sway}/bin/sway";
|
||||
extraArgs = [ "--unsupported-gpu" ];
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
light.enable = true;
|
||||
dconf.enable = true;
|
||||
seahorse.enable = true;
|
||||
};
|
||||
|
||||
security = {
|
||||
polkit.enable = true;
|
||||
pam.services = {
|
||||
greetd.enableGnomeKeyring = true;
|
||||
login.enableGnomeKeyring = true;
|
||||
swaylock.text = ''
|
||||
auth sufficient pam_unix.so try_first_pass likeauth nullok
|
||||
auth sufficient pam_fprintd.so
|
||||
auth include login
|
||||
'';
|
||||
};
|
||||
};
|
||||
|
||||
services = {
|
||||
greetd = {
|
||||
enable = true;
|
||||
settings = {
|
||||
initial_session = {
|
||||
command = "uwsm start -- sway-uwsm.desktop";
|
||||
user = "alisceon";
|
||||
};
|
||||
default_session = {
|
||||
command = "${pkgs.tuigreet}/bin/tuigreet --time --cmd 'uwsm start -- sway-uwsm.desktop' --remember --asterisks''";
|
||||
user = "greeter";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
logind.settings.Login = {
|
||||
HandleLidSwitch = "suspend";
|
||||
HandleLidSwitchExternalPower = "suspend";
|
||||
};
|
||||
|
||||
dbus.packages = [ pkgs.seahorse pkgs.gnome-keyring pkgs.gcr ];
|
||||
gnome.gcr-ssh-agent.enable = true;
|
||||
gvfs.enable = true;
|
||||
};
|
||||
|
||||
users.users.alisceon.extraGroups = [ "video" "input" ];
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue