fixed zshell config editing aliases, rewrote the 'if (host == 'oganesson')' statements to be more readable
This commit is contained in:
@@ -3,7 +3,12 @@
|
|||||||
host,
|
host,
|
||||||
scheme,
|
scheme,
|
||||||
...
|
...
|
||||||
}: {
|
}:
|
||||||
|
|
||||||
|
let
|
||||||
|
desktop = (host == "oganesson");
|
||||||
|
in
|
||||||
|
{
|
||||||
wayland.windowManager.hyprland = {
|
wayland.windowManager.hyprland = {
|
||||||
settings = {
|
settings = {
|
||||||
monitor =
|
monitor =
|
||||||
@@ -28,7 +33,7 @@
|
|||||||
];
|
];
|
||||||
|
|
||||||
workspace =
|
workspace =
|
||||||
if (host == "oganesson")
|
if desktop
|
||||||
then [
|
then [
|
||||||
"1,persistent=true,monitor:HDMI-A-1"
|
"1,persistent=true,monitor:HDMI-A-1"
|
||||||
"2,persistent=true,monitor:HDMI-A-1"
|
"2,persistent=true,monitor:HDMI-A-1"
|
||||||
|
|||||||
@@ -4,6 +4,7 @@
|
|||||||
...
|
...
|
||||||
}:
|
}:
|
||||||
let
|
let
|
||||||
|
desktop = (host == "oganesson");
|
||||||
extraFigletFonts = pkgs.fetchFromGitHub {
|
extraFigletFonts = pkgs.fetchFromGitHub {
|
||||||
owner = "xero";
|
owner = "xero";
|
||||||
repo = "figlet-fonts";
|
repo = "figlet-fonts";
|
||||||
@@ -21,7 +22,7 @@
|
|||||||
});
|
});
|
||||||
|
|
||||||
desktop_pkgs =
|
desktop_pkgs =
|
||||||
if (host == "oganesson")
|
if desktop
|
||||||
then
|
then
|
||||||
with pkgs; [
|
with pkgs; [
|
||||||
uhk-agent
|
uhk-agent
|
||||||
|
|||||||
@@ -13,6 +13,7 @@
|
|||||||
VISUAL = "nvim";
|
VISUAL = "nvim";
|
||||||
LANG = "en_US.UTF-8";
|
LANG = "en_US.UTF-8";
|
||||||
BROWSER = "firefox";
|
BROWSER = "firefox";
|
||||||
|
FLAKEPATH = "$HOME/.sysflake";
|
||||||
};
|
};
|
||||||
|
|
||||||
oh-my-zsh = {
|
oh-my-zsh = {
|
||||||
@@ -48,15 +49,15 @@
|
|||||||
psg = "ps aux | grep -v grep | grep -i -e VSZ -e";
|
psg = "ps aux | grep -v grep | grep -i -e VSZ -e";
|
||||||
mkdir = "mkdir -p";
|
mkdir = "mkdir -p";
|
||||||
pk = "pkill -9 -f";
|
pk = "pkill -9 -f";
|
||||||
zrc = "nvim ${self}/modules/home/environment/zshell.nix";
|
zrc = "nvim $FLAKEPATH/modules/home/environment/zshell.nix";
|
||||||
svcu = "systemctl --user";
|
svcu = "systemctl --user";
|
||||||
svc = "sudo systemctl";
|
svc = "sudo systemctl";
|
||||||
viflake = "nvim flake.nix";
|
viflake = "nvim flake.nix";
|
||||||
hyprconf = "yazi ${self}/modules/home/hyprland && popd &> /dev/null";
|
hyprconf = "yazi $FLAKEPATH/modules/home/hyprland && popd &> /dev/null";
|
||||||
hmconf = "yazi ${self}/modules/home/ && popd &> /dev/null";
|
hmconf = "yazi $FLAKEPATH/modules/home/ && popd &> /dev/null";
|
||||||
nixconf = "yazi ${self}/modules/sys/ && popd &> /dev/null";
|
nixconf = "yazi $FLAKEPATH/modules/sys/ && popd &> /dev/null";
|
||||||
hostconf = "yazi ${self}/hosts && popd &> /dev/null";
|
hostconf = "yazi $FLAKEPATH/hosts && popd &> /dev/null";
|
||||||
nvimcfg = "yazi ${self}/pkgs/nixvim/config && popd &> /dev/null";
|
nvimcfg = "yazi $FLAKEPATH/pkgs/nixvim/config && popd &> /dev/null";
|
||||||
};
|
};
|
||||||
initExtra = ''
|
initExtra = ''
|
||||||
|
|
||||||
@@ -127,6 +128,7 @@
|
|||||||
clear
|
clear
|
||||||
splash
|
splash
|
||||||
scheck && runbg aplay ${self}/assets/sound/sh-source.wav
|
scheck && runbg aplay ${self}/assets/sound/sh-source.wav
|
||||||
|
[ ! -f $FLAKEPATH/flake.nix ] && echo "WARNING: flake.nix not found at \$FLAKEPATH. Shell aliases for editing config files won't work correctly!" && echo "Edit the FLAKEPATH session variable in zshell.nix to point to the path where you saved the system configuration flake."
|
||||||
'';
|
'';
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -9,8 +9,9 @@
|
|||||||
home-manager,
|
home-manager,
|
||||||
...
|
...
|
||||||
}: let
|
}: let
|
||||||
|
desktop = (host == "onagesson");
|
||||||
desktop_modules =
|
desktop_modules =
|
||||||
if (host == "onagesson")
|
if desktop
|
||||||
then [(import ./gaming)]
|
then [(import ./gaming)]
|
||||||
else [];
|
else [];
|
||||||
in {
|
in {
|
||||||
|
|||||||
@@ -1,8 +1,12 @@
|
|||||||
{host, ...}: {
|
{host, ...}:
|
||||||
|
let
|
||||||
|
desktop = (host == "oganesson");
|
||||||
|
in
|
||||||
|
{
|
||||||
networking = {
|
networking = {
|
||||||
networkmanager.enable = true;
|
networkmanager.enable = true;
|
||||||
hostName =
|
hostName =
|
||||||
if (host == "oganesson")
|
if desktop
|
||||||
then "oganesson"
|
then "oganesson"
|
||||||
else "mercury";
|
else "mercury";
|
||||||
hosts = {
|
hosts = {
|
||||||
|
|||||||
@@ -1,4 +1,3 @@
|
|||||||
|
|
||||||
{
|
{
|
||||||
inputs,
|
inputs,
|
||||||
nixpkgs,
|
nixpkgs,
|
||||||
@@ -9,7 +8,8 @@
|
|||||||
...
|
...
|
||||||
}:
|
}:
|
||||||
let
|
let
|
||||||
desktop_modules = if (host == "oganesson") then
|
desktop = (host == "oganesson");
|
||||||
|
desktop_modules = if desktop then
|
||||||
[(import ./virtualization.nix)] ++ [(import ./gaming)]
|
[(import ./virtualization.nix)] ++ [(import ./gaming)]
|
||||||
else [];
|
else [];
|
||||||
in
|
in
|
||||||
@@ -21,4 +21,3 @@ in
|
|||||||
++ [(import ./nixvim)]
|
++ [(import ./nixvim)]
|
||||||
++ desktop_modules;
|
++ desktop_modules;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user