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,
|
||||
scheme,
|
||||
...
|
||||
}: {
|
||||
}:
|
||||
|
||||
let
|
||||
desktop = (host == "oganesson");
|
||||
in
|
||||
{
|
||||
wayland.windowManager.hyprland = {
|
||||
settings = {
|
||||
monitor =
|
||||
@@ -28,7 +33,7 @@
|
||||
];
|
||||
|
||||
workspace =
|
||||
if (host == "oganesson")
|
||||
if desktop
|
||||
then [
|
||||
"1,persistent=true,monitor:HDMI-A-1"
|
||||
"2,persistent=true,monitor:HDMI-A-1"
|
||||
|
||||
@@ -3,12 +3,13 @@
|
||||
host,
|
||||
...
|
||||
}:
|
||||
let
|
||||
let
|
||||
desktop = (host == "oganesson");
|
||||
extraFigletFonts = pkgs.fetchFromGitHub {
|
||||
owner = "xero";
|
||||
repo = "figlet-fonts";
|
||||
rev = "master";
|
||||
sha256 = "sha256-dAs7N66D2Fpy4/UB5Za1r2qb1iSAJR6TMmau1asxgtY=";
|
||||
rev = "master";
|
||||
sha256 = "sha256-dAs7N66D2Fpy4/UB5Za1r2qb1iSAJR6TMmau1asxgtY=";
|
||||
};
|
||||
toilet-extrafonts = pkgs.toilet.overrideAttrs (oldAttrs: {
|
||||
buildInputs = oldAttrs.buildInputs or [] ++ [extraFigletFonts];
|
||||
@@ -19,9 +20,9 @@
|
||||
cp -r ${extraFigletFonts}/* $out/share/figlet
|
||||
'';
|
||||
});
|
||||
|
||||
|
||||
desktop_pkgs =
|
||||
if (host == "oganesson")
|
||||
if desktop
|
||||
then
|
||||
with pkgs; [
|
||||
uhk-agent
|
||||
|
||||
@@ -13,6 +13,7 @@
|
||||
VISUAL = "nvim";
|
||||
LANG = "en_US.UTF-8";
|
||||
BROWSER = "firefox";
|
||||
FLAKEPATH = "$HOME/.sysflake";
|
||||
};
|
||||
|
||||
oh-my-zsh = {
|
||||
@@ -48,15 +49,15 @@
|
||||
psg = "ps aux | grep -v grep | grep -i -e VSZ -e";
|
||||
mkdir = "mkdir -p";
|
||||
pk = "pkill -9 -f";
|
||||
zrc = "nvim ${self}/modules/home/environment/zshell.nix";
|
||||
zrc = "nvim $FLAKEPATH/modules/home/environment/zshell.nix";
|
||||
svcu = "systemctl --user";
|
||||
svc = "sudo systemctl";
|
||||
viflake = "nvim flake.nix";
|
||||
hyprconf = "yazi ${self}/modules/home/hyprland && popd &> /dev/null";
|
||||
hmconf = "yazi ${self}/modules/home/ && popd &> /dev/null";
|
||||
nixconf = "yazi ${self}/modules/sys/ && popd &> /dev/null";
|
||||
hostconf = "yazi ${self}/hosts && popd &> /dev/null";
|
||||
nvimcfg = "yazi ${self}/pkgs/nixvim/config && popd &> /dev/null";
|
||||
hyprconf = "yazi $FLAKEPATH/modules/home/hyprland && popd &> /dev/null";
|
||||
hmconf = "yazi $FLAKEPATH/modules/home/ && popd &> /dev/null";
|
||||
nixconf = "yazi $FLAKEPATH/modules/sys/ && popd &> /dev/null";
|
||||
hostconf = "yazi $FLAKEPATH/hosts && popd &> /dev/null";
|
||||
nvimcfg = "yazi $FLAKEPATH/pkgs/nixvim/config && popd &> /dev/null";
|
||||
};
|
||||
initExtra = ''
|
||||
|
||||
@@ -127,6 +128,7 @@
|
||||
clear
|
||||
splash
|
||||
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,
|
||||
...
|
||||
}: let
|
||||
desktop = (host == "onagesson");
|
||||
desktop_modules =
|
||||
if (host == "onagesson")
|
||||
if desktop
|
||||
then [(import ./gaming)]
|
||||
else [];
|
||||
in {
|
||||
|
||||
@@ -1,8 +1,12 @@
|
||||
{host, ...}: {
|
||||
{host, ...}:
|
||||
let
|
||||
desktop = (host == "oganesson");
|
||||
in
|
||||
{
|
||||
networking = {
|
||||
networkmanager.enable = true;
|
||||
hostName =
|
||||
if (host == "oganesson")
|
||||
if desktop
|
||||
then "oganesson"
|
||||
else "mercury";
|
||||
hosts = {
|
||||
|
||||
@@ -1,4 +1,3 @@
|
||||
|
||||
{
|
||||
inputs,
|
||||
nixpkgs,
|
||||
@@ -7,18 +6,18 @@
|
||||
username,
|
||||
host,
|
||||
...
|
||||
}:
|
||||
}:
|
||||
let
|
||||
desktop_modules = if (host == "oganesson") then
|
||||
desktop = (host == "oganesson");
|
||||
desktop_modules = if desktop then
|
||||
[(import ./virtualization.nix)] ++ [(import ./gaming)]
|
||||
else [];
|
||||
in
|
||||
{
|
||||
imports =
|
||||
imports =
|
||||
[(import ./packages.nix)]
|
||||
++ [(import ./programs.nix)]
|
||||
++ [(import ./services.nix)]
|
||||
++ [(import ./nixvim)]
|
||||
++ desktop_modules;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user