Compare commits
2 Commits
4ea9437bb0
...
boxy-app-l
| Author | SHA1 | Date | |
|---|---|---|---|
| f8ee011d27 | |||
| 4a4ea6316d |
71
flake.lock
generated
71
flake.lock
generated
@@ -3,11 +3,11 @@
|
|||||||
"flake-compat": {
|
"flake-compat": {
|
||||||
"flake": false,
|
"flake": false,
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1761588595,
|
"lastModified": 1747046372,
|
||||||
"narHash": "sha256-XKUZz9zewJNUj46b4AJdiRZJAvSZ0Dqj2BNfXvFlJC4=",
|
"narHash": "sha256-CIVLLkVgvHYbgI2UpXvIIBJ12HWgX+fjA8Xf8PUmqCY=",
|
||||||
"owner": "edolstra",
|
"owner": "edolstra",
|
||||||
"repo": "flake-compat",
|
"repo": "flake-compat",
|
||||||
"rev": "f387cd2afec9419c8ee37694406ca490c3f34ee5",
|
"rev": "9100a0f413b0c601e0533d1d94ffd501ce2e7885",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -23,11 +23,11 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1761423376,
|
"lastModified": 1752428473,
|
||||||
"narHash": "sha256-pMy3cnUFfue4vz/y0jx71BfcPGxZf+hk/DtnzWvfU0c=",
|
"narHash": "sha256-IsE7fdAYbRlZuc0H5FtPfhhuHvlxnDGoAxdlnjpVNCU=",
|
||||||
"ref": "refs/heads/main",
|
"ref": "refs/heads/main",
|
||||||
"rev": "a1f695665771841a988afc965526cbf99160cd77",
|
"rev": "1fad66b55144ab6beaecd900172a21ac3c34dc52",
|
||||||
"revCount": 11,
|
"revCount": 10,
|
||||||
"type": "git",
|
"type": "git",
|
||||||
"url": "https://git.johnogle.info/johno/google-cookie-retrieval.git"
|
"url": "https://git.johnogle.info/johno/google-cookie-retrieval.git"
|
||||||
},
|
},
|
||||||
@@ -43,16 +43,15 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1758463745,
|
"lastModified": 1759172751,
|
||||||
"narHash": "sha256-uhzsV0Q0I9j2y/rfweWeGif5AWe0MGrgZ/3TjpDYdGA=",
|
"narHash": "sha256-E8W8sRXfrvkFW26GuuiWq6QfReU7m5+cngwHuRo/3jc=",
|
||||||
"owner": "nix-community",
|
"owner": "nix-community",
|
||||||
"repo": "home-manager",
|
"repo": "home-manager",
|
||||||
"rev": "3b955f5f0a942f9f60cdc9cacb7844335d0f21c3",
|
"rev": "12fa8548feefa9a10266ba65152fd1a787cdde8f",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
"owner": "nix-community",
|
"owner": "nix-community",
|
||||||
"ref": "release-25.05",
|
|
||||||
"repo": "home-manager",
|
"repo": "home-manager",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
@@ -64,16 +63,15 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1759509947,
|
"lastModified": 1758805352,
|
||||||
"narHash": "sha256-4XifSIHfpJKcCf5bZZRhj8C4aCpjNBaE3kXr02s4rHU=",
|
"narHash": "sha256-BHdc43Lkayd+72W/NXRKHzX5AZ+28F3xaUs3a88/Uew=",
|
||||||
"owner": "nix-darwin",
|
"owner": "nix-darwin",
|
||||||
"repo": "nix-darwin",
|
"repo": "nix-darwin",
|
||||||
"rev": "000eadb231812ad6ea6aebd7526974aaf4e79355",
|
"rev": "c48e963a5558eb1c3827d59d21c5193622a1477c",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
"owner": "nix-darwin",
|
"owner": "nix-darwin",
|
||||||
"ref": "nix-darwin-25.05",
|
|
||||||
"repo": "nix-darwin",
|
"repo": "nix-darwin",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
@@ -84,11 +82,11 @@
|
|||||||
"nixpkgs": "nixpkgs"
|
"nixpkgs": "nixpkgs"
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1762251193,
|
"lastModified": 1758785683,
|
||||||
"narHash": "sha256-CmSddz8e2kM+ITbYutluhKZyXXwI9Sg2lf7XXSvc8oY=",
|
"narHash": "sha256-mRn51IeEBXeNh5a6xNLylk4PKBX0s/QQxgkEbYoPq/w=",
|
||||||
"owner": "nix-community",
|
"owner": "nix-community",
|
||||||
"repo": "NixOS-WSL",
|
"repo": "NixOS-WSL",
|
||||||
"rev": "e001844d4553aef268f97b32d3a825b6370eed91",
|
"rev": "1bfb978f2f6261b6086e04af17f9418e1fe36d70",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -100,11 +98,11 @@
|
|||||||
},
|
},
|
||||||
"nixpkgs": {
|
"nixpkgs": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1761907660,
|
"lastModified": 1758277210,
|
||||||
"narHash": "sha256-kJ8lIZsiPOmbkJypG+B5sReDXSD1KGu2VEPNqhRa/ew=",
|
"narHash": "sha256-iCGWf/LTy+aY0zFu8q12lK8KuZp7yvdhStehhyX1v8w=",
|
||||||
"owner": "NixOS",
|
"owner": "NixOS",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "2fb006b87f04c4d3bdf08cfdbc7fab9c13d94a15",
|
"rev": "8eaee110344796db060382e15d3af0a9fc396e0e",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -114,34 +112,18 @@
|
|||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"nixpkgs-unstable": {
|
|
||||||
"locked": {
|
|
||||||
"lastModified": 1762596750,
|
|
||||||
"narHash": "sha256-rXXuz51Bq7DHBlfIjN7jO8Bu3du5TV+3DSADBX7/9YQ=",
|
|
||||||
"owner": "nixos",
|
|
||||||
"repo": "nixpkgs",
|
|
||||||
"rev": "b6a8526db03f735b89dd5ff348f53f752e7ddc8e",
|
|
||||||
"type": "github"
|
|
||||||
},
|
|
||||||
"original": {
|
|
||||||
"owner": "nixos",
|
|
||||||
"ref": "nixos-unstable",
|
|
||||||
"repo": "nixpkgs",
|
|
||||||
"type": "github"
|
|
||||||
}
|
|
||||||
},
|
|
||||||
"nixpkgs_2": {
|
"nixpkgs_2": {
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1762498405,
|
"lastModified": 1759036355,
|
||||||
"narHash": "sha256-Zg/SCgCaAioc0/SVZQJxuECGPJy+OAeBcGeA5okdYDc=",
|
"narHash": "sha256-0m27AKv6ka+q270dw48KflE0LwQYrO7Fm4/2//KCVWg=",
|
||||||
"owner": "nixos",
|
"owner": "nixos",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"rev": "6faeb062ee4cf4f105989d490831713cc5a43ee1",
|
"rev": "e9f00bd893984bc8ce46c895c3bf7cac95331127",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
"owner": "nixos",
|
"owner": "nixos",
|
||||||
"ref": "nixos-25.05",
|
"ref": "nixos-unstable",
|
||||||
"repo": "nixpkgs",
|
"repo": "nixpkgs",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
}
|
}
|
||||||
@@ -156,11 +138,11 @@
|
|||||||
]
|
]
|
||||||
},
|
},
|
||||||
"locked": {
|
"locked": {
|
||||||
"lastModified": 1762784320,
|
"lastModified": 1759157415,
|
||||||
"narHash": "sha256-odsk96Erywk5hs0dhArF38zb7Oe0q6LZ70gXbxAPKno=",
|
"narHash": "sha256-Fg8cOnVoIe0uQ38UpR6XZzRCwDsjjozVwfevW9yCLI0=",
|
||||||
"owner": "nix-community",
|
"owner": "nix-community",
|
||||||
"repo": "plasma-manager",
|
"repo": "plasma-manager",
|
||||||
"rev": "7911a0f8a44c7e8b29d031be3149ee8943144321",
|
"rev": "df5b3e6da631f732c26c6044c7cccb8706b4f479",
|
||||||
"type": "github"
|
"type": "github"
|
||||||
},
|
},
|
||||||
"original": {
|
"original": {
|
||||||
@@ -176,7 +158,6 @@
|
|||||||
"nix-darwin": "nix-darwin",
|
"nix-darwin": "nix-darwin",
|
||||||
"nixos-wsl": "nixos-wsl",
|
"nixos-wsl": "nixos-wsl",
|
||||||
"nixpkgs": "nixpkgs_2",
|
"nixpkgs": "nixpkgs_2",
|
||||||
"nixpkgs-unstable": "nixpkgs-unstable",
|
|
||||||
"plasma-manager": "plasma-manager"
|
"plasma-manager": "plasma-manager"
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
29
flake.nix
29
flake.nix
@@ -2,17 +2,16 @@
|
|||||||
description = "A very basic flake";
|
description = "A very basic flake";
|
||||||
|
|
||||||
inputs = {
|
inputs = {
|
||||||
nixpkgs.url = "github:nixos/nixpkgs/nixos-25.05";
|
nixpkgs.url = "github:nixos/nixpkgs/nixos-unstable";
|
||||||
nixpkgs-unstable.url = "github:nixos/nixpkgs/nixos-unstable";
|
|
||||||
nixos-wsl.url = "github:nix-community/NixOS-WSL/main";
|
nixos-wsl.url = "github:nix-community/NixOS-WSL/main";
|
||||||
|
|
||||||
nix-darwin = {
|
nix-darwin = {
|
||||||
url = "github:nix-darwin/nix-darwin/nix-darwin-25.05";
|
url = "github:nix-darwin/nix-darwin";
|
||||||
inputs.nixpkgs.follows = "nixpkgs";
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
};
|
};
|
||||||
|
|
||||||
home-manager = {
|
home-manager = {
|
||||||
url = "github:nix-community/home-manager/release-25.05";
|
url = "github:nix-community/home-manager";
|
||||||
inputs.nixpkgs.follows = "nixpkgs";
|
inputs.nixpkgs.follows = "nixpkgs";
|
||||||
};
|
};
|
||||||
|
|
||||||
@@ -28,25 +27,16 @@
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
outputs = { self, nixpkgs, nixpkgs-unstable, nixos-wsl, ... } @ inputs: let
|
outputs = { self, nixpkgs, nixos-wsl, ... } @ inputs: let
|
||||||
nixosModules = [
|
nixosModules = [
|
||||||
./roles
|
./roles
|
||||||
] ++ [
|
] ++ [
|
||||||
inputs.home-manager.nixosModules.home-manager
|
inputs.home-manager.nixosModules.home-manager
|
||||||
{
|
{
|
||||||
nixpkgs.overlays = [
|
|
||||||
(final: prev: {
|
|
||||||
unstable = import nixpkgs-unstable {
|
|
||||||
system = prev.system;
|
|
||||||
config.allowUnfree = true;
|
|
||||||
};
|
|
||||||
custom = prev.callPackage ./packages {};
|
|
||||||
})
|
|
||||||
];
|
|
||||||
home-manager.useGlobalPkgs = true;
|
home-manager.useGlobalPkgs = true;
|
||||||
home-manager.useUserPackages = true;
|
home-manager.useUserPackages = true;
|
||||||
home-manager.sharedModules = [
|
home-manager.sharedModules = [
|
||||||
inputs.plasma-manager.homeModules.plasma-manager
|
inputs.plasma-manager.homeManagerModules.plasma-manager
|
||||||
];
|
];
|
||||||
home-manager.extraSpecialArgs = {
|
home-manager.extraSpecialArgs = {
|
||||||
globalInputs = inputs;
|
globalInputs = inputs;
|
||||||
@@ -58,15 +48,6 @@
|
|||||||
] ++ [
|
] ++ [
|
||||||
inputs.home-manager.darwinModules.home-manager
|
inputs.home-manager.darwinModules.home-manager
|
||||||
{
|
{
|
||||||
nixpkgs.overlays = [
|
|
||||||
(final: prev: {
|
|
||||||
unstable = import nixpkgs-unstable {
|
|
||||||
system = prev.system;
|
|
||||||
config.allowUnfree = true;
|
|
||||||
};
|
|
||||||
custom = prev.callPackage ./packages {};
|
|
||||||
})
|
|
||||||
];
|
|
||||||
home-manager.useGlobalPkgs = true;
|
home-manager.useGlobalPkgs = true;
|
||||||
home-manager.useUserPackages = true;
|
home-manager.useUserPackages = true;
|
||||||
home-manager.extraSpecialArgs = {
|
home-manager.extraSpecialArgs = {
|
||||||
|
|||||||
@@ -1,9 +1,11 @@
|
|||||||
{ config, lib, pkgs, globalInputs, system, ... }:
|
{ config, lib, pkgs, globalInputs, system, ... }:
|
||||||
|
|
||||||
let
|
let
|
||||||
leader = "cmd"; # Change this to experiment with different leader keys (e.g., "cmd", "ctrl")
|
customPkgs = pkgs.callPackage ../packages {};
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
|
# Provide arguments to role modules
|
||||||
|
_module.args = { inherit customPkgs; };
|
||||||
# Home Manager configuration for Darwin work laptop
|
# Home Manager configuration for Darwin work laptop
|
||||||
# Corporate-friendly setup with essential development tools
|
# Corporate-friendly setup with essential development tools
|
||||||
|
|
||||||
@@ -11,114 +13,28 @@ in
|
|||||||
home.homeDirectory = lib.mkForce "/Users/johno";
|
home.homeDirectory = lib.mkForce "/Users/johno";
|
||||||
home.stateVersion = "24.05";
|
home.stateVersion = "24.05";
|
||||||
|
|
||||||
# System packages
|
|
||||||
home.packages = with pkgs; [
|
|
||||||
autoraise
|
|
||||||
];
|
|
||||||
|
|
||||||
# Note: ghostty installed via Homebrew (managed outside of nix)
|
|
||||||
|
|
||||||
# Auto-start autoraise on login
|
|
||||||
launchd.agents.autoraise = {
|
|
||||||
enable = true;
|
|
||||||
config = {
|
|
||||||
ProgramArguments = [
|
|
||||||
"${pkgs.autoraise}/bin/AutoRaise"
|
|
||||||
"-pollMillis" "50"
|
|
||||||
"-delay" "2"
|
|
||||||
"-focusDelay" "2"
|
|
||||||
];
|
|
||||||
RunAtLoad = true;
|
|
||||||
KeepAlive = true;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
# Auto-start aerospace on login
|
|
||||||
# NOTE: In 25.11+, this can be simplified to `programs.aerospace.launchd.enable = true`
|
|
||||||
launchd.agents.aerospace = {
|
|
||||||
enable = true;
|
|
||||||
config = {
|
|
||||||
Program = "${pkgs.aerospace}/Applications/AeroSpace.app/Contents/MacOS/AeroSpace";
|
|
||||||
RunAtLoad = true;
|
|
||||||
KeepAlive = true;
|
|
||||||
StandardOutPath = "/tmp/aerospace.log";
|
|
||||||
StandardErrorPath = "/tmp/aerospace.err.log";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
# Override Darwin-incompatible settings from base role
|
# Override Darwin-incompatible settings from base role
|
||||||
programs.rbw.settings.pinentry = lib.mkForce pkgs.pinentry_mac;
|
programs.rbw.settings.pinentry = lib.mkForce pkgs.pinentry_mac;
|
||||||
|
|
||||||
# Disable Home Manager from managing shell RC files
|
programs.bash.initExtra = ''
|
||||||
# topsoil/compost will manage these files instead
|
export NODE_EXTRA_CA_CERTS=/opt/homebrew/etc/ca-certificates/cert.pem
|
||||||
programs.bash.enable = lib.mkForce false;
|
export COREPACK_NPM_REGISTRY=https://global.block-artifacts.com/artifactory/api/npm/square-npm/
|
||||||
programs.zsh.enable = lib.mkForce false;
|
export COREPACK_INTEGRITY_KEYS=0
|
||||||
|
|
||||||
# Create a local nix integration file that topsoil-managed configs can source
|
export NVM_DIR="$HOME/.nvm"
|
||||||
home.file.".nix-integration.sh" = {
|
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh" # This loads nvm
|
||||||
text = ''
|
[ -s "$NVM_DIR/bash_completion" ] && \. "$NVM_DIR/bash_completion" # This loads nvm bash_completion
|
||||||
# Source Home Manager session variables (nix paths, environment, etc.)
|
'';
|
||||||
if [ -e /etc/profiles/per-user/johno/etc/profile.d/hm-session-vars.sh ]; then
|
|
||||||
. /etc/profiles/per-user/johno/etc/profile.d/hm-session-vars.sh
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Setup bash completions from nix profiles
|
programs.zsh.enable = true;
|
||||||
if [[ ! -v BASH_COMPLETION_VERSINFO ]] && [ -n "$NIX_PROFILES" ]; then
|
programs.zsh.initContent = ''
|
||||||
for profile in $NIX_PROFILES; do
|
export NODE_EXTRA_CA_CERTS=/opt/homebrew/etc/ca-certificates/cert.pem
|
||||||
if [ -f "$profile/etc/profile.d/bash_completion.sh" ]; then
|
export COREPACK_NPM_REGISTRY=https://global.block-artifacts.com/artifactory/api/npm/square-npm/
|
||||||
. "$profile/etc/profile.d/bash_completion.sh"
|
export COREPACK_INTEGRITY_KEYS=0
|
||||||
break
|
export NVM_DIR="$HOME/.nvm"
|
||||||
fi
|
[ -s "$NVM_DIR/nvm.sh" ] && . "$NVM_DIR/nvm.sh" # This loads nvm
|
||||||
done
|
[ -s "$NVM_DIR/bash_completion" ] && . "$NVM_DIR/bash_completion" # This loads nvm bash_completion
|
||||||
fi
|
'';
|
||||||
|
|
||||||
# command-not-found handler
|
|
||||||
command_not_found_handle() {
|
|
||||||
local p=/nix/var/nix/profiles/per-user/root/channels/nixos/programs.sqlite
|
|
||||||
if [ -n "$NIX_PROFILES" ]; then
|
|
||||||
for profile in $NIX_PROFILES; do
|
|
||||||
if [ -x "$profile/bin/command-not-found" ] && [ -f "$p" ]; then
|
|
||||||
"$profile/bin/command-not-found" "$@"
|
|
||||||
return $?
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
fi
|
|
||||||
echo "$1: command not found" >&2
|
|
||||||
return 127
|
|
||||||
}
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
|
|
||||||
home.file.".nix-integration.zsh" = {
|
|
||||||
text = ''
|
|
||||||
# Source Home Manager session variables (nix paths, environment, etc.)
|
|
||||||
if [ -e /etc/profiles/per-user/johno/etc/profile.d/hm-session-vars.sh ]; then
|
|
||||||
. /etc/profiles/per-user/johno/etc/profile.d/hm-session-vars.sh
|
|
||||||
fi
|
|
||||||
|
|
||||||
# Setup zsh completions from nix profiles
|
|
||||||
typeset -U path cdpath fpath manpath
|
|
||||||
for profile in ''${(z)NIX_PROFILES}; do
|
|
||||||
fpath+=($profile/share/zsh/site-functions $profile/share/zsh/$ZSH_VERSION/functions $profile/share/zsh/vendor-completions)
|
|
||||||
done
|
|
||||||
autoload -U compinit && compinit
|
|
||||||
|
|
||||||
# command-not-found handler
|
|
||||||
command_not_found_handler() {
|
|
||||||
local p=/nix/var/nix/profiles/per-user/root/channels/nixos/programs.sqlite
|
|
||||||
if [ -n "$NIX_PROFILES" ]; then
|
|
||||||
for profile in ''${(z)NIX_PROFILES}; do
|
|
||||||
if [ -x "$profile/bin/command-not-found" ] && [ -f "$p" ]; then
|
|
||||||
"$profile/bin/command-not-found" "$@"
|
|
||||||
return $?
|
|
||||||
fi
|
|
||||||
done
|
|
||||||
fi
|
|
||||||
echo "$1: command not found" >&2
|
|
||||||
return 127
|
|
||||||
}
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
|
|
||||||
# Keep SSH and Git disabled to avoid conflicts with work environment
|
# Keep SSH and Git disabled to avoid conflicts with work environment
|
||||||
programs.ssh.enable = lib.mkForce false;
|
programs.ssh.enable = lib.mkForce false;
|
||||||
@@ -127,99 +43,6 @@ in
|
|||||||
|
|
||||||
home.shell.enableShellIntegration = true;
|
home.shell.enableShellIntegration = true;
|
||||||
|
|
||||||
# TODO: Move this to its own role and/or module
|
|
||||||
programs.aerospace = {
|
|
||||||
enable = true;
|
|
||||||
userSettings.mode.main.binding = {
|
|
||||||
"${leader}-slash" = "layout tiles horizontal vertical";
|
|
||||||
"${leader}-comma" = "layout accordion horizontal vertical";
|
|
||||||
"${leader}-shift-q" = "close";
|
|
||||||
"${leader}-shift-f" = "fullscreen";
|
|
||||||
"${leader}-h" = "focus left";
|
|
||||||
"${leader}-j" = "focus down";
|
|
||||||
"${leader}-k" = "focus up";
|
|
||||||
"${leader}-l" = "focus right";
|
|
||||||
"${leader}-shift-h" = "move left";
|
|
||||||
"${leader}-shift-j" = "move down";
|
|
||||||
"${leader}-shift-k" = "move up";
|
|
||||||
"${leader}-shift-l" = "move right";
|
|
||||||
"${leader}-minus" = "resize smart -50";
|
|
||||||
"${leader}-equal" = "resize smart +50";
|
|
||||||
"${leader}-1" = "workspace 1";
|
|
||||||
"${leader}-2" = "workspace 2";
|
|
||||||
"${leader}-3" = "workspace 3";
|
|
||||||
"${leader}-4" = "workspace 4";
|
|
||||||
"${leader}-5" = "workspace 5";
|
|
||||||
"${leader}-6" = "workspace 6";
|
|
||||||
"${leader}-7" = "workspace 7";
|
|
||||||
"${leader}-8" = "workspace 8";
|
|
||||||
"${leader}-9" = "workspace 9";
|
|
||||||
"${leader}-0" = "workspace 10";
|
|
||||||
"${leader}-shift-1" = "move-node-to-workspace 1";
|
|
||||||
"${leader}-shift-2" = "move-node-to-workspace 2";
|
|
||||||
"${leader}-shift-3" = "move-node-to-workspace 3";
|
|
||||||
"${leader}-shift-4" = "move-node-to-workspace 4";
|
|
||||||
"${leader}-shift-5" = "move-node-to-workspace 5";
|
|
||||||
"${leader}-shift-6" = "move-node-to-workspace 6";
|
|
||||||
"${leader}-shift-7" = "move-node-to-workspace 7";
|
|
||||||
"${leader}-shift-8" = "move-node-to-workspace 8";
|
|
||||||
"${leader}-shift-9" = "move-node-to-workspace 9";
|
|
||||||
"${leader}-shift-0" = "move-node-to-workspace 10";
|
|
||||||
"${leader}-tab" = "workspace-back-and-forth";
|
|
||||||
"${leader}-shift-tab" = "move-workspace-to-monitor --wrap-around next";
|
|
||||||
|
|
||||||
"${leader}-enter" = ''
|
|
||||||
exec-and-forget osascript <<'APPLESCRIPT'
|
|
||||||
tell application "Ghostty"
|
|
||||||
activate
|
|
||||||
tell application "System Events"
|
|
||||||
keystroke "n" using {command down}
|
|
||||||
end tell
|
|
||||||
end tell
|
|
||||||
APPLESCRIPT
|
|
||||||
'';
|
|
||||||
|
|
||||||
"${leader}-shift-enter" = ''
|
|
||||||
exec-and-forget osascript <<'APPLESCRIPT'
|
|
||||||
tell application "Google Chrome"
|
|
||||||
set newWindow to make new window
|
|
||||||
activate
|
|
||||||
tell newWindow to set index to 1
|
|
||||||
end tell
|
|
||||||
APPLESCRIPT
|
|
||||||
'';
|
|
||||||
|
|
||||||
"${leader}-shift-e" = "exec-and-forget zsh --login -c \"emacsclient -c -n\"";
|
|
||||||
|
|
||||||
# Service mode: Deliberate aerospace window management
|
|
||||||
"${leader}-i" = "mode service";
|
|
||||||
|
|
||||||
# Passthrough mode: Temporarily disable aerospace to use macOS shortcuts
|
|
||||||
# Press Cmd-P, then use any macOS shortcut (like Cmd-K in Slack), then press Cmd-P again to exit
|
|
||||||
"${leader}-p" = "mode passthrough";
|
|
||||||
};
|
|
||||||
|
|
||||||
# Service mode: For deliberate aerospace window management operations
|
|
||||||
userSettings.mode.service.binding = {
|
|
||||||
esc = ["reload-config" "mode main"];
|
|
||||||
r = ["flatten-workspace-tree" "mode main"]; # reset layout
|
|
||||||
f = ["layout floating tiling" "mode main"]; # Toggle between floating and tiling layout
|
|
||||||
backspace = ["close-all-windows-but-current" "mode main"];
|
|
||||||
|
|
||||||
"${leader}-shift-h" = ["join-with left" "mode main"];
|
|
||||||
"${leader}-shift-j" = ["join-with down" "mode main"];
|
|
||||||
"${leader}-shift-k" = ["join-with up" "mode main"];
|
|
||||||
"${leader}-shift-l" = ["join-with right" "mode main"];
|
|
||||||
};
|
|
||||||
|
|
||||||
# Passthrough mode: All shortcuts pass through to macOS
|
|
||||||
# This mode has minimal bindings - just ways to exit back to main mode
|
|
||||||
userSettings.mode.passthrough.binding = {
|
|
||||||
esc = "mode main";
|
|
||||||
"${leader}-p" = "mode main"; # Toggle back with same key (Cmd-P)
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
home.roles = {
|
home.roles = {
|
||||||
base.enable = true;
|
base.enable = true;
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -1,6 +1,11 @@
|
|||||||
{ pkgs, globalInputs, system, ... }:
|
{ pkgs, globalInputs, system, ... }:
|
||||||
|
|
||||||
|
let
|
||||||
|
customPkgs = pkgs.callPackage ../packages {};
|
||||||
|
in
|
||||||
{
|
{
|
||||||
|
# Provide arguments to role modules
|
||||||
|
_module.args = { inherit customPkgs; };
|
||||||
# Home Manager configuration for full desktop experience
|
# Home Manager configuration for full desktop experience
|
||||||
home.username = "johno";
|
home.username = "johno";
|
||||||
home.homeDirectory = "/home/johno";
|
home.homeDirectory = "/home/johno";
|
||||||
|
|||||||
@@ -1,6 +1,11 @@
|
|||||||
{ config, lib, pkgs, globalInputs, system, ... }:
|
{ config, lib, pkgs, globalInputs, system, ... }:
|
||||||
|
|
||||||
|
let
|
||||||
|
customPkgs = pkgs.callPackage ../packages {};
|
||||||
|
in
|
||||||
{
|
{
|
||||||
|
# Provide arguments to role modules
|
||||||
|
_module.args = { inherit customPkgs; };
|
||||||
# Home Manager configuration for compact laptop setups
|
# Home Manager configuration for compact laptop setups
|
||||||
# Optimized for space-constrained environments
|
# Optimized for space-constrained environments
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,11 @@
|
|||||||
{ pkgs, globalInputs, system, ... }:
|
{ pkgs, globalInputs, system, ... }:
|
||||||
|
|
||||||
|
let
|
||||||
|
customPkgs = pkgs.callPackage ../packages {};
|
||||||
|
in
|
||||||
{
|
{
|
||||||
|
# Provide arguments to role modules
|
||||||
|
_module.args = { inherit customPkgs; };
|
||||||
# Home Manager configuration for live USB environments
|
# Home Manager configuration for live USB environments
|
||||||
# Minimal setup without persistent services
|
# Minimal setup without persistent services
|
||||||
|
|
||||||
|
|||||||
@@ -1,6 +1,11 @@
|
|||||||
{ pkgs, globalInputs, system, ... }:
|
{ pkgs, globalInputs, system, ... }:
|
||||||
|
|
||||||
|
let
|
||||||
|
customPkgs = pkgs.callPackage ../packages {};
|
||||||
|
in
|
||||||
{
|
{
|
||||||
|
# Provide arguments to role modules
|
||||||
|
_module.args = { inherit customPkgs; };
|
||||||
# Home Manager configuration for media center setups
|
# Home Manager configuration for media center setups
|
||||||
# Optimized for living room media consumption and gaming
|
# Optimized for living room media consumption and gaming
|
||||||
|
|
||||||
|
|||||||
@@ -1,18 +1,20 @@
|
|||||||
{ config, lib, pkgs, ... }:
|
{ config, lib, ... }:
|
||||||
|
|
||||||
with lib;
|
with lib;
|
||||||
|
|
||||||
let
|
let
|
||||||
cfg = config.home.i3_sway;
|
cfg = config.home.i3_sway;
|
||||||
|
i3_cfg = config.xsession.windowManager.i3.config;
|
||||||
|
|
||||||
shared_config = recursiveUpdate rec {
|
shared_config = recursiveUpdate rec {
|
||||||
modifier = "Mod4";
|
modifier = "Mod4";
|
||||||
terminal = "ghostty";
|
terminal = "kitty";
|
||||||
defaultWorkspace = "workspace number 1";
|
defaultWorkspace = "workspace number 1";
|
||||||
|
|
||||||
keybindings = {
|
keybindings = {
|
||||||
"${shared_config.modifier}+Return" = "exec ${terminal}";
|
"${shared_config.modifier}+Return" = "exec ${terminal}";
|
||||||
"${shared_config.modifier}+Shift+q" = "kill";
|
"${shared_config.modifier}+Shift+q" = "kill";
|
||||||
|
"${shared_config.modifier}+d" = "exec ${i3_cfg.menu}";
|
||||||
|
|
||||||
"${shared_config.modifier}+h" = "focus left";
|
"${shared_config.modifier}+h" = "focus left";
|
||||||
"${shared_config.modifier}+j" = "focus down";
|
"${shared_config.modifier}+j" = "focus down";
|
||||||
@@ -36,7 +38,7 @@ let
|
|||||||
|
|
||||||
#"${shared_config.modifier}+h" = "split h";
|
#"${shared_config.modifier}+h" = "split h";
|
||||||
"${shared_config.modifier}+v" = "split v";
|
"${shared_config.modifier}+v" = "split v";
|
||||||
"${shared_config.modifier}+Shift+f" = "fullscreen toggle";
|
"${shared_config.modifier}+f" = "fullscreen toggle";
|
||||||
|
|
||||||
"${shared_config.modifier}+s" = "layout stacking";
|
"${shared_config.modifier}+s" = "layout stacking";
|
||||||
"${shared_config.modifier}+w" = "layout tabbed";
|
"${shared_config.modifier}+w" = "layout tabbed";
|
||||||
@@ -105,166 +107,12 @@ in {
|
|||||||
};
|
};
|
||||||
|
|
||||||
config = {
|
config = {
|
||||||
# i3blocks configuration file
|
|
||||||
home.file.".config/i3blocks/config".text = ''
|
|
||||||
# i3blocks config - replicating waybar setup
|
|
||||||
separator_block_width=15
|
|
||||||
markup=pango
|
|
||||||
|
|
||||||
[disk]
|
|
||||||
command=df -h / | awk 'NR==2 {print "💾 " $5}'
|
|
||||||
interval=30
|
|
||||||
separator=true
|
|
||||||
|
|
||||||
[cpu]
|
|
||||||
command=top -bn1 | grep "Cpu(s)" | sed "s/.*, *\([0-9.]*\)%* id.*/\1/" | awk '{print "🧠 " int(100 - $1) "%"}'
|
|
||||||
interval=2
|
|
||||||
separator=true
|
|
||||||
|
|
||||||
[memory]
|
|
||||||
command=free | awk 'NR==2 {printf "🐏 %.0f%%\n", $3*100/$2}'
|
|
||||||
interval=5
|
|
||||||
separator=true
|
|
||||||
|
|
||||||
[pulseaudio]
|
|
||||||
command=${pkgs.writeShellScript "i3blocks-pulseaudio" ''
|
|
||||||
volume=$(pactl get-sink-volume @DEFAULT_SINK@ | grep -Po '\d+%' | head -1)
|
|
||||||
muted=$(pactl get-sink-mute @DEFAULT_SINK@ | grep -o 'yes')
|
|
||||||
if [ "$muted" = "yes" ]; then
|
|
||||||
echo "🔇"
|
|
||||||
else
|
|
||||||
vol_num=''${volume%\%}
|
|
||||||
if [ $vol_num -le 33 ]; then
|
|
||||||
echo "🔈 $volume"
|
|
||||||
elif [ $vol_num -le 66 ]; then
|
|
||||||
echo "🔉 $volume"
|
|
||||||
else
|
|
||||||
echo "🔊 $volume"
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
''}
|
|
||||||
interval=1
|
|
||||||
signal=10
|
|
||||||
separator=true
|
|
||||||
|
|
||||||
[backlight]
|
|
||||||
command=${pkgs.writeShellScript "i3blocks-backlight" ''
|
|
||||||
if command -v brightnessctl &>/dev/null; then
|
|
||||||
brightnessctl g | awk -v max=$(brightnessctl m) '{printf "☀️ %.0f%%\n", ($1/max)*100}'
|
|
||||||
fi
|
|
||||||
''}
|
|
||||||
interval=1
|
|
||||||
separator=true
|
|
||||||
|
|
||||||
[network]
|
|
||||||
command=${pkgs.writeShellScript "i3blocks-network" ''
|
|
||||||
if iwgetid -r &>/dev/null; then
|
|
||||||
ssid=$(iwgetid -r)
|
|
||||||
signal=$(grep "^\s*w" /proc/net/wireless | awk '{print int($3 * 100 / 70)}')
|
|
||||||
echo "📶 $ssid ($signal%)"
|
|
||||||
else
|
|
||||||
ip=$(ip -4 addr show | grep -oP '(?<=inet\s)\d+(\.\d+){3}' | grep -v '127.0.0.1' | head -1)
|
|
||||||
if [ -n "$ip" ]; then
|
|
||||||
echo "🔌 $ip"
|
|
||||||
else
|
|
||||||
echo "❌"
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
''}
|
|
||||||
interval=5
|
|
||||||
separator=true
|
|
||||||
|
|
||||||
[battery]
|
|
||||||
command=${pkgs.writeShellScript "i3blocks-battery" ''
|
|
||||||
if [ -d /sys/class/power_supply/BAT0 ]; then
|
|
||||||
capacity=$(cat /sys/class/power_supply/BAT0/capacity)
|
|
||||||
status=$(cat /sys/class/power_supply/BAT0/status)
|
|
||||||
|
|
||||||
if [ "$status" = "Charging" ]; then
|
|
||||||
echo "⚡ $capacity%"
|
|
||||||
else
|
|
||||||
echo "🔋 $capacity%"
|
|
||||||
fi
|
|
||||||
fi
|
|
||||||
''}
|
|
||||||
interval=10
|
|
||||||
separator=true
|
|
||||||
|
|
||||||
[time]
|
|
||||||
command=date '+%Y-%m-%d %H:%M'
|
|
||||||
interval=1
|
|
||||||
separator=false
|
|
||||||
'';
|
|
||||||
|
|
||||||
xsession.windowManager.i3 = let
|
xsession.windowManager.i3 = let
|
||||||
base_i3_config = recursiveUpdate shared_config {
|
base_i3_config = recursiveUpdate shared_config {
|
||||||
bars = [{
|
keybindings = {
|
||||||
position = "bottom";
|
|
||||||
statusCommand = "${pkgs.i3blocks}/bin/i3blocks";
|
|
||||||
trayOutput = "primary"; # Enable system tray on primary output
|
|
||||||
fonts = {
|
|
||||||
names = [ "Fira Code" "monospace" ];
|
|
||||||
size = 11.0;
|
|
||||||
};
|
|
||||||
colors = {
|
|
||||||
background = "#000000";
|
|
||||||
statusline = "#ffffff";
|
|
||||||
separator = "#666666";
|
|
||||||
|
|
||||||
# Workspace button colors (matching waybar)
|
|
||||||
focusedWorkspace = {
|
|
||||||
border = "#285577";
|
|
||||||
background = "#285577";
|
|
||||||
text = "#ffffff";
|
|
||||||
};
|
|
||||||
activeWorkspace = {
|
|
||||||
border = "#5f676a";
|
|
||||||
background = "#5f676a";
|
|
||||||
text = "#ffffff";
|
|
||||||
};
|
|
||||||
inactiveWorkspace = {
|
|
||||||
border = "#222222";
|
|
||||||
background = "#222222";
|
|
||||||
text = "#888888";
|
|
||||||
};
|
|
||||||
urgentWorkspace = {
|
|
||||||
border = "#900000";
|
|
||||||
background = "#900000";
|
|
||||||
text = "#ffffff";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
}];
|
|
||||||
keybindings = shared_config.keybindings // {
|
|
||||||
"${shared_config.modifier}+d" = "exec rofi -show drun";
|
|
||||||
"${shared_config.modifier}+Shift+e" =
|
"${shared_config.modifier}+Shift+e" =
|
||||||
"exec i3-nagbar -t warning -m 'Do you want to exit i3?' -b 'Yes' 'i3-msg exit'";
|
"exec i3-nagbar -t warning -m 'Do you want to exit i3?' -b 'Yes' 'i3-msg exit'";
|
||||||
};
|
};
|
||||||
startup = [
|
|
||||||
# GNOME polkit authentication agent
|
|
||||||
{
|
|
||||||
command = "/run/current-system/sw/libexec/polkit-gnome-authentication-agent-1";
|
|
||||||
always = false;
|
|
||||||
notification = false;
|
|
||||||
}
|
|
||||||
# Picom compositor for smooth rendering and no tearing (important for Nvidia)
|
|
||||||
{
|
|
||||||
command = "picom --backend glx -b";
|
|
||||||
always = false;
|
|
||||||
notification = false;
|
|
||||||
}
|
|
||||||
# NetworkManager system tray applet
|
|
||||||
{
|
|
||||||
command = "nm-applet";
|
|
||||||
always = false;
|
|
||||||
notification = false;
|
|
||||||
}
|
|
||||||
# Set wallpaper with feh
|
|
||||||
{
|
|
||||||
command = "feh --bg-scale ${../../wallpapers/metroid-samus-returns-kz-3440x1440.jpg}";
|
|
||||||
always = false;
|
|
||||||
notification = false;
|
|
||||||
}
|
|
||||||
];
|
|
||||||
};
|
};
|
||||||
in {
|
in {
|
||||||
enable = true;
|
enable = true;
|
||||||
@@ -273,9 +121,7 @@ in {
|
|||||||
|
|
||||||
wayland.windowManager.sway = let
|
wayland.windowManager.sway = let
|
||||||
base_sway_config = recursiveUpdate shared_config {
|
base_sway_config = recursiveUpdate shared_config {
|
||||||
bars = []; # Disable default bar, use waybar instead
|
keybindings = {
|
||||||
keybindings = shared_config.keybindings // {
|
|
||||||
"${shared_config.modifier}+d" = "exec wofi --show drun";
|
|
||||||
"${shared_config.modifier}+Shift+e" =
|
"${shared_config.modifier}+Shift+e" =
|
||||||
"exec swaynag -t warning -m 'You pressed the exit shortcut. Do you really want to exit sway? This will end your Wayland session.' -b 'Yes, exit sway' 'swaymsg exit'";
|
"exec swaynag -t warning -m 'You pressed the exit shortcut. Do you really want to exit sway? This will end your Wayland session.' -b 'Yes, exit sway' 'swaymsg exit'";
|
||||||
};
|
};
|
||||||
@@ -291,151 +137,10 @@ in {
|
|||||||
dwt = "enabled";
|
dwt = "enabled";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
output = {
|
|
||||||
"*" = {
|
|
||||||
bg = "${../../wallpapers/metroid-samus-returns-kz-3440x1440.jpg} fill";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
in {
|
in {
|
||||||
enable = true;
|
enable = true;
|
||||||
config = recursiveUpdate base_sway_config cfg.extraSwayConfig;
|
config = recursiveUpdate base_sway_config cfg.extraSwayConfig;
|
||||||
};
|
};
|
||||||
|
|
||||||
programs.waybar = {
|
|
||||||
enable = true;
|
|
||||||
systemd.enable = true;
|
|
||||||
settings = {
|
|
||||||
mainBar = {
|
|
||||||
layer = "top";
|
|
||||||
position = "bottom";
|
|
||||||
height = 30;
|
|
||||||
spacing = 4;
|
|
||||||
|
|
||||||
modules-left = [ "sway/workspaces" "sway/mode" ];
|
|
||||||
modules-center = [ ];
|
|
||||||
modules-right = [ "disk" "cpu" "memory" "pulseaudio" "backlight" "network" "battery" "tray" "clock" ];
|
|
||||||
|
|
||||||
"sway/workspaces" = {
|
|
||||||
disable-scroll = true;
|
|
||||||
all-outputs = true;
|
|
||||||
};
|
|
||||||
|
|
||||||
"clock" = {
|
|
||||||
format = "{:%Y-%m-%d %H:%M}";
|
|
||||||
tooltip-format = "<tt><small>{calendar}</small></tt>";
|
|
||||||
calendar = {
|
|
||||||
mode = "year";
|
|
||||||
mode-mon-col = 3;
|
|
||||||
weeks-pos = "right";
|
|
||||||
on-scroll = 1;
|
|
||||||
format = {
|
|
||||||
months = "<span color='#ffead3'><b>{}</b></span>";
|
|
||||||
days = "<span color='#ecc6d9'><b>{}</b></span>";
|
|
||||||
weeks = "<span color='#99ffdd'><b>W{}</b></span>";
|
|
||||||
weekdays = "<span color='#ffcc66'><b>{}</b></span>";
|
|
||||||
today = "<span color='#ff6699'><b><u>{}</u></b></span>";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
"disk" = {
|
|
||||||
interval = 30;
|
|
||||||
format = "💾 {percentage_used}%";
|
|
||||||
path = "/";
|
|
||||||
tooltip-format = "Used: {used} / {total} ({percentage_used}%)\nFree: {free} ({percentage_free}%)";
|
|
||||||
};
|
|
||||||
|
|
||||||
"cpu" = {
|
|
||||||
format = "🧠 {usage}%";
|
|
||||||
tooltip = false;
|
|
||||||
};
|
|
||||||
|
|
||||||
"memory" = {
|
|
||||||
format = "🐏 {percentage}%";
|
|
||||||
tooltip-format = "RAM: {used:0.1f}G / {total:0.1f}G";
|
|
||||||
};
|
|
||||||
|
|
||||||
"pulseaudio" = {
|
|
||||||
format = "{icon} {volume}%";
|
|
||||||
format-muted = "🔇";
|
|
||||||
format-icons = {
|
|
||||||
headphone = "🎧";
|
|
||||||
default = [ "🔈" "🔉" "🔊" ];
|
|
||||||
};
|
|
||||||
on-click = "pavucontrol";
|
|
||||||
};
|
|
||||||
|
|
||||||
"backlight" = {
|
|
||||||
format = "☀️ {percent}%";
|
|
||||||
tooltip = false;
|
|
||||||
};
|
|
||||||
|
|
||||||
"network" = {
|
|
||||||
format-wifi = "📶 {essid} ({signalStrength}%)";
|
|
||||||
format-ethernet = "🔌 {ipaddr}";
|
|
||||||
format-disconnected = "❌";
|
|
||||||
tooltip-format = "{ifname}: {ipaddr}/{cidr}";
|
|
||||||
};
|
|
||||||
|
|
||||||
"battery" = {
|
|
||||||
states = {
|
|
||||||
warning = 30;
|
|
||||||
critical = 15;
|
|
||||||
};
|
|
||||||
format = "{icon} {capacity}%";
|
|
||||||
format-charging = "⚡ {capacity}%";
|
|
||||||
format-icons = [ "🪫" "🔋" "🔋" "🔋" "🔋" ];
|
|
||||||
};
|
|
||||||
|
|
||||||
"tray" = {
|
|
||||||
spacing = 10;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
style = ''
|
|
||||||
* {
|
|
||||||
padding: 0 4px;
|
|
||||||
font-family: "Fira Code", monospace;
|
|
||||||
font-size: 13px;
|
|
||||||
}
|
|
||||||
|
|
||||||
#workspaces button {
|
|
||||||
padding: 0 8px;
|
|
||||||
background-color: transparent;
|
|
||||||
color: #ffffff;
|
|
||||||
border: none;
|
|
||||||
}
|
|
||||||
|
|
||||||
#workspaces button.focused {
|
|
||||||
background-color: #285577;
|
|
||||||
font-weight: bold;
|
|
||||||
}
|
|
||||||
|
|
||||||
#workspaces button.visible {
|
|
||||||
background-color: #5f676a;
|
|
||||||
}
|
|
||||||
|
|
||||||
#workspaces button.urgent {
|
|
||||||
background-color: #900000;
|
|
||||||
}
|
|
||||||
'';
|
|
||||||
};
|
|
||||||
|
|
||||||
programs.rofi = {
|
|
||||||
enable = true;
|
|
||||||
theme = "solarized";
|
|
||||||
extraConfig = {
|
|
||||||
modi = "drun,run,window";
|
|
||||||
show-icons = true;
|
|
||||||
drun-display-format = "{name}";
|
|
||||||
disable-history = false;
|
|
||||||
hide-scrollbar = true;
|
|
||||||
display-drun = " Apps";
|
|
||||||
display-run = " Run";
|
|
||||||
display-window = " Windows";
|
|
||||||
sidebar-mode = true;
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -13,10 +13,10 @@
|
|||||||
enable = true;
|
enable = true;
|
||||||
overrideConfig = true;
|
overrideConfig = true;
|
||||||
|
|
||||||
hotkeys.commands."launch-ghostty" = {
|
hotkeys.commands."launch-konsole" = {
|
||||||
name = "Launch Ghostty";
|
name = "Launch Konsole";
|
||||||
key = "Meta+Return";
|
key = "Meta+Return";
|
||||||
command = "ghostty";
|
command = "konsole";
|
||||||
};
|
};
|
||||||
|
|
||||||
shortcuts = {
|
shortcuts = {
|
||||||
@@ -167,12 +167,6 @@
|
|||||||
AutoRaiseInterval = 750; # Delay in ms before auto-raise (if enabled)
|
AutoRaiseInterval = 750; # Delay in ms before auto-raise (if enabled)
|
||||||
DelayFocusInterval = 0; # Delay in ms before focus follows mouse
|
DelayFocusInterval = 0; # Delay in ms before focus follows mouse
|
||||||
};
|
};
|
||||||
|
|
||||||
# Desktop wallpaper configuration
|
|
||||||
plasma-localerc.Formats.LANG = "en_US.UTF-8";
|
|
||||||
|
|
||||||
# Set wallpaper for all desktops
|
|
||||||
plasmarc.Wallpapers.usersWallpapers = "${../../wallpapers/metroid-samus-returns-kz-3440x1440.jpg}";
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -58,11 +58,11 @@ in
|
|||||||
|
|
||||||
programs.ssh = {
|
programs.ssh = {
|
||||||
enable = true;
|
enable = true;
|
||||||
addKeysToAgent = "yes";
|
|
||||||
matchBlocks = {
|
matchBlocks = {
|
||||||
"nucdeb1" = {
|
"nucdeb1" = {
|
||||||
hostname = "nucdeb1.oglehome";
|
hostname = "nucdeb1.oglehome";
|
||||||
user = "root";
|
user = "root";
|
||||||
|
addKeysToAgent = "yes";
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -14,7 +14,7 @@ in
|
|||||||
home.packages = [
|
home.packages = [
|
||||||
# Communication apps
|
# Communication apps
|
||||||
pkgs.element-desktop
|
pkgs.element-desktop
|
||||||
#pkgs.fluffychat #marked insecure as of nixos 25.05
|
pkgs.fluffychat
|
||||||
pkgs.nextcloud-talk-desktop
|
pkgs.nextcloud-talk-desktop
|
||||||
|
|
||||||
# For logging back into google chat
|
# For logging back into google chat
|
||||||
|
|||||||
@@ -16,15 +16,12 @@ in
|
|||||||
bitwarden
|
bitwarden
|
||||||
dunst
|
dunst
|
||||||
keepassxc
|
keepassxc
|
||||||
unstable.ghostty
|
kitty
|
||||||
|
|
||||||
# Desktop utilities
|
# Desktop utilities
|
||||||
feh # Image viewer and wallpaper setter for X11
|
|
||||||
rofi # Application launcher for X11
|
|
||||||
solaar # Logitech management software
|
solaar # Logitech management software
|
||||||
waybar
|
waybar
|
||||||
wofi # Application launcher for Wayland
|
wofi
|
||||||
xdg-utils # XDG utilities for opening files/URLs with default applications
|
|
||||||
|
|
||||||
# System utilities with GUI components
|
# System utilities with GUI components
|
||||||
(snapcast.override { pulseaudioSupport = true; })
|
(snapcast.override { pulseaudioSupport = true; })
|
||||||
@@ -40,14 +37,6 @@ in
|
|||||||
kdePackages.kaddressbook
|
kdePackages.kaddressbook
|
||||||
kdePackages.kontact
|
kdePackages.kontact
|
||||||
|
|
||||||
# KDE System components needed for proper integration
|
|
||||||
kdePackages.kded
|
|
||||||
kdePackages.systemsettings
|
|
||||||
kdePackages.kmenuedit
|
|
||||||
|
|
||||||
# Desktop menu support
|
|
||||||
kdePackages.plasma-desktop # Contains applications.menu
|
|
||||||
|
|
||||||
# KDE Online Accounts support
|
# KDE Online Accounts support
|
||||||
kdePackages.kaccounts-integration
|
kdePackages.kaccounts-integration
|
||||||
kdePackages.kaccounts-providers
|
kdePackages.kaccounts-providers
|
||||||
@@ -81,80 +70,8 @@ in
|
|||||||
enable = true;
|
enable = true;
|
||||||
};
|
};
|
||||||
|
|
||||||
# KDE environment variables for proper integration
|
xdg.enable = true;
|
||||||
home.sessionVariables = {
|
|
||||||
QT_QPA_PLATFORMTHEME = "kde";
|
|
||||||
KDE_SESSION_VERSION = "6";
|
|
||||||
};
|
|
||||||
|
|
||||||
xdg = {
|
|
||||||
enable = true;
|
|
||||||
|
|
||||||
# Ensure desktop files are made available for discovery
|
|
||||||
desktopEntries = {}; # This creates the desktop files directory structure
|
|
||||||
|
|
||||||
mimeApps = {
|
|
||||||
enable = true;
|
|
||||||
associations.added = {
|
|
||||||
# Ensure associations are properly registered
|
|
||||||
"text/html" = "firefox.desktop";
|
|
||||||
"x-scheme-handler/http" = "firefox.desktop";
|
|
||||||
"x-scheme-handler/https" = "firefox.desktop";
|
|
||||||
};
|
|
||||||
defaultApplications = {
|
|
||||||
# Web browsers
|
|
||||||
"text/html" = "firefox.desktop";
|
|
||||||
"x-scheme-handler/http" = "firefox.desktop";
|
|
||||||
"x-scheme-handler/https" = "firefox.desktop";
|
|
||||||
"x-scheme-handler/about" = "firefox.desktop";
|
|
||||||
"x-scheme-handler/unknown" = "firefox.desktop";
|
|
||||||
|
|
||||||
# Documents
|
|
||||||
"application/pdf" = "okular.desktop";
|
|
||||||
"text/plain" = "kate.desktop";
|
|
||||||
"text/x-tex" = "kate.desktop";
|
|
||||||
"text/x-c" = "kate.desktop";
|
|
||||||
"text/x-python" = "kate.desktop";
|
|
||||||
"application/x-shellscript" = "kate.desktop";
|
|
||||||
|
|
||||||
# Images
|
|
||||||
"image/png" = "gwenview.desktop";
|
|
||||||
"image/jpeg" = "gwenview.desktop";
|
|
||||||
"image/jpg" = "gwenview.desktop";
|
|
||||||
"image/gif" = "gwenview.desktop";
|
|
||||||
"image/bmp" = "gwenview.desktop";
|
|
||||||
"image/tiff" = "gwenview.desktop";
|
|
||||||
"image/webp" = "gwenview.desktop";
|
|
||||||
|
|
||||||
# Archives
|
|
||||||
"application/zip" = "ark.desktop";
|
|
||||||
"application/x-tar" = "ark.desktop";
|
|
||||||
"application/x-compressed-tar" = "ark.desktop";
|
|
||||||
"application/x-7z-compressed" = "ark.desktop";
|
|
||||||
"application/x-rar" = "ark.desktop";
|
|
||||||
|
|
||||||
# Audio
|
|
||||||
"audio/mpeg" = "elisa.desktop";
|
|
||||||
"audio/mp4" = "elisa.desktop";
|
|
||||||
"audio/flac" = "elisa.desktop";
|
|
||||||
"audio/ogg" = "elisa.desktop";
|
|
||||||
"audio/wav" = "elisa.desktop";
|
|
||||||
|
|
||||||
# Email
|
|
||||||
"message/rfc822" = "kmail.desktop";
|
|
||||||
"x-scheme-handler/mailto" = "kmail.desktop";
|
|
||||||
|
|
||||||
# Calendar
|
|
||||||
"text/calendar" = "korganizer.desktop";
|
|
||||||
"application/x-vnd.akonadi.calendar.event" = "korganizer.desktop";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
# Fix for KDE applications.menu file issue on Plasma 6
|
|
||||||
# KDE still looks for applications.menu but Plasma 6 renamed it to plasma-applications.menu
|
|
||||||
xdg.configFile."menus/applications.menu".source = "${pkgs.kdePackages.plasma-workspace}/etc/xdg/menus/plasma-applications.menu";
|
|
||||||
|
|
||||||
# Note: modules must be imported at top-level home config
|
# Note: modules must be imported at top-level home config
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
@@ -1,4 +1,4 @@
|
|||||||
{ config, lib, pkgs, globalInputs, system, ... }:
|
{ config, lib, pkgs, customPkgs, globalInputs, system, ... }:
|
||||||
|
|
||||||
with lib;
|
with lib;
|
||||||
|
|
||||||
@@ -12,11 +12,12 @@ in
|
|||||||
|
|
||||||
config = mkIf cfg.enable {
|
config = mkIf cfg.enable {
|
||||||
home.packages = [
|
home.packages = [
|
||||||
pkgs.unstable.claude-code
|
pkgs.claude-code
|
||||||
pkgs.codex
|
pkgs.codex
|
||||||
|
pkgs.goose-cli
|
||||||
|
|
||||||
# Custom packages
|
# Custom packages
|
||||||
pkgs.custom.tea-rbw
|
customPkgs.tea-rbw
|
||||||
];
|
];
|
||||||
|
|
||||||
programs.kubectl-secure.enable = true;
|
programs.kubectl-secure.enable = true;
|
||||||
|
|||||||
@@ -18,10 +18,6 @@ in
|
|||||||
delfin
|
delfin
|
||||||
moonlight-qt
|
moonlight-qt
|
||||||
vlc
|
vlc
|
||||||
|
|
||||||
# Spotify client
|
|
||||||
# Using unstable version for better authentication support
|
|
||||||
unstable.ncspot
|
|
||||||
];
|
];
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
Binary file not shown.
|
Before Width: | Height: | Size: 2.6 MiB |
@@ -24,7 +24,7 @@ with lib;
|
|||||||
};
|
};
|
||||||
kodi = {
|
kodi = {
|
||||||
enable = true;
|
enable = true;
|
||||||
autologin = true;
|
autologin = false;
|
||||||
wayland = true;
|
wayland = true;
|
||||||
};
|
};
|
||||||
users.enable = true;
|
users.enable = true;
|
||||||
|
|||||||
@@ -65,8 +65,6 @@
|
|||||||
|
|
||||||
# Enable NetworkManager for easy wifi setup
|
# Enable NetworkManager for easy wifi setup
|
||||||
networking.networkmanager.enable = true;
|
networking.networkmanager.enable = true;
|
||||||
# Disable wireless networking (conflicts with NetworkManager)
|
|
||||||
networking.wireless.enable = false;
|
|
||||||
|
|
||||||
# Enable SSH daemon for remote access
|
# Enable SSH daemon for remote access
|
||||||
services.openssh = {
|
services.openssh = {
|
||||||
|
|||||||
@@ -37,6 +37,9 @@
|
|||||||
networking.hostName = "nix-book"; # Define your hostname.
|
networking.hostName = "nix-book"; # Define your hostname.
|
||||||
# networking.wireless.enable = true; # Enables wireless support via wpa_supplicant.
|
# networking.wireless.enable = true; # Enables wireless support via wpa_supplicant.
|
||||||
|
|
||||||
|
boot.kernelPackages = pkgs.linuxPackages_latest;
|
||||||
|
|
||||||
|
|
||||||
# Enable networking
|
# Enable networking
|
||||||
networking.networkmanager.enable = true;
|
networking.networkmanager.enable = true;
|
||||||
|
|
||||||
|
|||||||
@@ -24,7 +24,6 @@ with lib;
|
|||||||
kde = true;
|
kde = true;
|
||||||
sddm = true;
|
sddm = true;
|
||||||
wayland = true;
|
wayland = true;
|
||||||
x11 = true;
|
|
||||||
};
|
};
|
||||||
nfs-mounts.enable = true;
|
nfs-mounts.enable = true;
|
||||||
nvidia.enable = true;
|
nvidia.enable = true;
|
||||||
@@ -52,15 +51,19 @@ with lib;
|
|||||||
hardware.graphics.enable = true;
|
hardware.graphics.enable = true;
|
||||||
hardware.graphics.enable32Bit = true;
|
hardware.graphics.enable32Bit = true;
|
||||||
|
|
||||||
# Set DP-0 as primary display with 164.90Hz refresh rate
|
|
||||||
services.xserver.displayManager.sessionCommands = ''
|
|
||||||
${pkgs.xorg.xrandr}/bin/xrandr --output DP-0 --mode 3440x1440 --rate 164.90 --primary
|
|
||||||
'';
|
|
||||||
|
|
||||||
hardware.nvidia = {
|
hardware.nvidia = {
|
||||||
|
# Modesetting is required.
|
||||||
modesetting.enable = true;
|
modesetting.enable = true;
|
||||||
|
|
||||||
|
# Enable the Nvidia settings menu,
|
||||||
|
# accessible via `nvidia-settings`.
|
||||||
nvidiaSettings = true;
|
nvidiaSettings = true;
|
||||||
|
|
||||||
|
# Optionally, you may need to select the appropriate driver version for your specific GPU.
|
||||||
package = pkgs.linuxPackages.nvidiaPackages.stable;
|
package = pkgs.linuxPackages.nvidiaPackages.stable;
|
||||||
|
|
||||||
|
# Use open source kernel modules (recommended for RTX/GTX 16xx and newer)
|
||||||
|
# Set to false if you have an older GPU
|
||||||
open = true;
|
open = true;
|
||||||
|
|
||||||
# For gaming performance
|
# For gaming performance
|
||||||
|
|||||||
@@ -7,7 +7,6 @@ import subprocess
|
|||||||
import sys
|
import sys
|
||||||
from http.server import BaseHTTPRequestHandler, HTTPServer
|
from http.server import BaseHTTPRequestHandler, HTTPServer
|
||||||
from urllib.parse import urlparse
|
from urllib.parse import urlparse
|
||||||
import psutil
|
|
||||||
|
|
||||||
# Configure logging
|
# Configure logging
|
||||||
logging.basicConfig(
|
logging.basicConfig(
|
||||||
@@ -22,60 +21,6 @@ ALLOWED_APPS = {
|
|||||||
'kodi': 'kodi'
|
'kodi': 'kodi'
|
||||||
}
|
}
|
||||||
|
|
||||||
def is_app_running(app_name):
|
|
||||||
"""Check if an application is already running, returns (is_running, pid)"""
|
|
||||||
command = ALLOWED_APPS.get(app_name)
|
|
||||||
if not command:
|
|
||||||
return False, None
|
|
||||||
|
|
||||||
logger.debug(f"Looking for processes related to app '{app_name}' (command: '{command}')")
|
|
||||||
|
|
||||||
for proc in psutil.process_iter(['name', 'cmdline', 'pid']):
|
|
||||||
try:
|
|
||||||
proc_name = proc.info['name']
|
|
||||||
cmdline = proc.info['cmdline'] or []
|
|
||||||
|
|
||||||
logger.debug(f"Checking process PID {proc.info['pid']}: name='{proc_name}', cmdline={cmdline}")
|
|
||||||
|
|
||||||
# Check multiple patterns for the application:
|
|
||||||
# 1. Process name exactly matches command
|
|
||||||
# 2. Process name contains the command (e.g., "kodi.bin" contains "kodi")
|
|
||||||
# 3. Command line starts with the command
|
|
||||||
# 4. Command line contains the wrapped version (e.g., ".kodi-wrapped")
|
|
||||||
# 5. Any command line argument ends with the command executable
|
|
||||||
|
|
||||||
matches = False
|
|
||||||
match_reason = ""
|
|
||||||
|
|
||||||
if proc_name == command:
|
|
||||||
matches = True
|
|
||||||
match_reason = f"exact process name match: '{proc_name}'"
|
|
||||||
elif command in proc_name:
|
|
||||||
matches = True
|
|
||||||
match_reason = f"process name contains command: '{proc_name}' contains '{command}'"
|
|
||||||
elif cmdline and cmdline[0] == command:
|
|
||||||
matches = True
|
|
||||||
match_reason = f"exact cmdline match: '{cmdline[0]}'"
|
|
||||||
elif cmdline and cmdline[0].endswith('/' + command):
|
|
||||||
matches = True
|
|
||||||
match_reason = f"cmdline path ends with command: '{cmdline[0]}'"
|
|
||||||
elif cmdline and any(f'.{command}-wrapped' in arg for arg in cmdline):
|
|
||||||
matches = True
|
|
||||||
match_reason = f"wrapped command in cmdline: {cmdline}"
|
|
||||||
elif cmdline and any(f'{command}.bin' in arg for arg in cmdline):
|
|
||||||
matches = True
|
|
||||||
match_reason = f"binary command in cmdline: {cmdline}"
|
|
||||||
|
|
||||||
if matches:
|
|
||||||
logger.info(f"Found running {app_name} process: PID {proc.info['pid']} ({match_reason})")
|
|
||||||
return True, proc.info['pid']
|
|
||||||
|
|
||||||
except (psutil.NoSuchProcess, psutil.AccessDenied, psutil.ZombieProcess):
|
|
||||||
continue
|
|
||||||
|
|
||||||
logger.debug(f"No running process found for {app_name}")
|
|
||||||
return False, None
|
|
||||||
|
|
||||||
class AppLauncherHandler(BaseHTTPRequestHandler):
|
class AppLauncherHandler(BaseHTTPRequestHandler):
|
||||||
def log_message(self, format, *args):
|
def log_message(self, format, *args):
|
||||||
logger.info(format % args)
|
logger.info(format % args)
|
||||||
@@ -111,22 +56,6 @@ class AppLauncherHandler(BaseHTTPRequestHandler):
|
|||||||
|
|
||||||
command = ALLOWED_APPS[app_name]
|
command = ALLOWED_APPS[app_name]
|
||||||
|
|
||||||
# Check if app is already running
|
|
||||||
is_running, existing_pid = is_app_running(app_name)
|
|
||||||
if is_running:
|
|
||||||
logger.info(f"Application {app_name} is already running (PID: {existing_pid}), skipping launch")
|
|
||||||
self.send_response(200)
|
|
||||||
self.send_header('Content-type', 'application/json')
|
|
||||||
self.end_headers()
|
|
||||||
response = {
|
|
||||||
'status': 'success',
|
|
||||||
'message': f'{app_name} is already running',
|
|
||||||
'pid': existing_pid,
|
|
||||||
'already_running': True
|
|
||||||
}
|
|
||||||
self.wfile.write(json.dumps(response).encode())
|
|
||||||
return
|
|
||||||
|
|
||||||
try:
|
try:
|
||||||
# Launch the application in the background
|
# Launch the application in the background
|
||||||
# Ensure we have the proper environment for GUI apps
|
# Ensure we have the proper environment for GUI apps
|
||||||
@@ -147,8 +76,7 @@ class AppLauncherHandler(BaseHTTPRequestHandler):
|
|||||||
response = {
|
response = {
|
||||||
'status': 'success',
|
'status': 'success',
|
||||||
'message': f'Successfully launched {app_name}',
|
'message': f'Successfully launched {app_name}',
|
||||||
'pid': process.pid,
|
'pid': process.pid
|
||||||
'already_running': False
|
|
||||||
}
|
}
|
||||||
self.wfile.write(json.dumps(response).encode())
|
self.wfile.write(json.dumps(response).encode())
|
||||||
|
|
||||||
|
|||||||
@@ -1,10 +1,5 @@
|
|||||||
{ pkgs }:
|
{ pkgs }:
|
||||||
|
|
||||||
let
|
|
||||||
python = pkgs.python3.withPackages (ps: with ps; [
|
|
||||||
psutil
|
|
||||||
]);
|
|
||||||
in
|
|
||||||
pkgs.writeShellScriptBin "app-launcher-server" ''
|
pkgs.writeShellScriptBin "app-launcher-server" ''
|
||||||
exec ${python}/bin/python3 ${./app-launcher-server.py} "$@"
|
exec ${pkgs.python3}/bin/python3 ${./app-launcher-server.py} "$@"
|
||||||
''
|
''
|
||||||
@@ -15,7 +15,6 @@ in
|
|||||||
environment.etc."bashrc".enable = false;
|
environment.etc."bashrc".enable = false;
|
||||||
environment.etc."zshrc".enable = false;
|
environment.etc."zshrc".enable = false;
|
||||||
environment.etc."zshenv".enable = false;
|
environment.etc."zshenv".enable = false;
|
||||||
environment.etc."zprofile".enable = false;
|
|
||||||
|
|
||||||
# Create .local files with nix environment setup
|
# Create .local files with nix environment setup
|
||||||
environment.etc."bash.local".text = ''
|
environment.etc."bash.local".text = ''
|
||||||
@@ -45,41 +44,6 @@ in
|
|||||||
|
|
||||||
time.timeZone = "America/Los_Angeles";
|
time.timeZone = "America/Los_Angeles";
|
||||||
|
|
||||||
# System preferences
|
|
||||||
system.defaults = {
|
|
||||||
# Custom keyboard shortcuts
|
|
||||||
CustomUserPreferences = {
|
|
||||||
"com.apple.symbolichotkeys" = {
|
|
||||||
AppleSymbolicHotKeys = {
|
|
||||||
# Screenshot - Capture entire screen (Cmd+Ctrl+3)
|
|
||||||
"28" = {
|
|
||||||
enabled = true;
|
|
||||||
value = {
|
|
||||||
parameters = [ 51 20 1310720 ];
|
|
||||||
type = "standard";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
# Screenshot - Capture selected portion (Cmd+Ctrl+4)
|
|
||||||
"30" = {
|
|
||||||
enabled = true;
|
|
||||||
value = {
|
|
||||||
parameters = [ 52 21 1310720 ];
|
|
||||||
type = "standard";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
# Screenshot - Show screenshot toolbar (Cmd+Ctrl+5)
|
|
||||||
"184" = {
|
|
||||||
enabled = true;
|
|
||||||
value = {
|
|
||||||
parameters = [ 53 23 1310720 ];
|
|
||||||
type = "standard";
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
|
|
||||||
environment.systemPackages = with pkgs; [
|
environment.systemPackages = with pkgs; [
|
||||||
git
|
git
|
||||||
glances
|
glances
|
||||||
|
|||||||
@@ -19,18 +19,8 @@ in
|
|||||||
|
|
||||||
(mkIf (cfg.enable && cfg.gaming.emulation) {
|
(mkIf (cfg.enable && cfg.gaming.emulation) {
|
||||||
environment.systemPackages = with pkgs; [
|
environment.systemPackages = with pkgs; [
|
||||||
dolphin-emu
|
|
||||||
dolphin-emu-primehack
|
|
||||||
retroarch-full
|
|
||||||
ryubing
|
ryubing
|
||||||
];
|
dolphin-emu
|
||||||
# TODO: Remove me once dolphin-emu and dolphin-emu-primehack update
|
|
||||||
# dependencies to mbedtls from mbedtls_2 (which is currently)
|
|
||||||
# unmaintained
|
|
||||||
nixpkgs.config.permittedInsecurePackages = [ "mbedtls-2.28.10" ];
|
|
||||||
|
|
||||||
warnings = [
|
|
||||||
"Using insecure mbedtls-2.28.10 for Dolphin Emu - check for updates regularly"
|
|
||||||
];
|
];
|
||||||
})
|
})
|
||||||
];
|
];
|
||||||
|
|||||||
@@ -16,22 +16,5 @@ in
|
|||||||
programs.dconf.enable = true;
|
programs.dconf.enable = true;
|
||||||
services.gnome.gnome-keyring.enable = true;
|
services.gnome.gnome-keyring.enable = true;
|
||||||
programs.kdeconnect.enable = true;
|
programs.kdeconnect.enable = true;
|
||||||
|
|
||||||
# XDG Desktop Portal for default application handling in non-KDE environments
|
|
||||||
xdg.portal = {
|
|
||||||
enable = true;
|
|
||||||
extraPortals = with pkgs; [
|
|
||||||
kdePackages.xdg-desktop-portal-kde # For KDE application integration
|
|
||||||
xdg-desktop-portal-gtk # Fallback for GTK applications
|
|
||||||
];
|
|
||||||
config = {
|
|
||||||
common = {
|
|
||||||
default = "kde";
|
|
||||||
};
|
|
||||||
i3 = {
|
|
||||||
default = ["kde" "gtk"];
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -12,14 +12,7 @@ in
|
|||||||
|
|
||||||
windowManager.i3 = {
|
windowManager.i3 = {
|
||||||
enable = true;
|
enable = true;
|
||||||
extraPackages = with pkgs; [
|
extraPackages = with pkgs; [ dmenu i3status i3lock ];
|
||||||
dmenu
|
|
||||||
i3status
|
|
||||||
i3lock
|
|
||||||
polkit_gnome # GNOME polkit authentication agent (more stable with i3)
|
|
||||||
picom # Compositor for smooth rendering (important for Nvidia)
|
|
||||||
networkmanagerapplet # NetworkManager system tray applet
|
|
||||||
];
|
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|||||||
@@ -4,6 +4,7 @@ with lib;
|
|||||||
|
|
||||||
let
|
let
|
||||||
cfg = config.roles.kodi;
|
cfg = config.roles.kodi;
|
||||||
|
customPkgs = pkgs.callPackage ../../packages {};
|
||||||
in
|
in
|
||||||
{
|
{
|
||||||
options.roles.kodi = {
|
options.roles.kodi = {
|
||||||
@@ -53,7 +54,7 @@ in
|
|||||||
kodiPkg
|
kodiPkg
|
||||||
wget
|
wget
|
||||||
firefox
|
firefox
|
||||||
] ++ optional cfg.appLauncherServer.enable pkgs.custom.app-launcher-server;
|
] ++ optional cfg.appLauncherServer.enable customPkgs.app-launcher-server;
|
||||||
|
|
||||||
programs.kdeconnect.enable = true;
|
programs.kdeconnect.enable = true;
|
||||||
|
|
||||||
@@ -64,7 +65,7 @@ in
|
|||||||
after = [ "graphical-session.target" ];
|
after = [ "graphical-session.target" ];
|
||||||
serviceConfig = {
|
serviceConfig = {
|
||||||
Type = "simple";
|
Type = "simple";
|
||||||
ExecStart = "${pkgs.custom.app-launcher-server}/bin/app-launcher-server ${toString cfg.appLauncherServer.port}";
|
ExecStart = "${customPkgs.app-launcher-server}/bin/app-launcher-server ${toString cfg.appLauncherServer.port}";
|
||||||
Restart = "always";
|
Restart = "always";
|
||||||
RestartSec = "5s";
|
RestartSec = "5s";
|
||||||
Environment = [
|
Environment = [
|
||||||
@@ -74,10 +75,13 @@ in
|
|||||||
};
|
};
|
||||||
};
|
};
|
||||||
|
|
||||||
services.displayManager = mkIf cfg.autologin {
|
services = if cfg.autologin then {
|
||||||
autoLogin.enable = true;
|
displayManager = {
|
||||||
autoLogin.user = "kodi";
|
autoLogin.enable = true;
|
||||||
defaultSession = "plasma";
|
autoLogin.user = "kodi";
|
||||||
};
|
defaultSession = "kodi";
|
||||||
|
sessionData.autologinSession = "plasma";
|
||||||
|
};
|
||||||
|
} else {};
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -26,11 +26,5 @@ in
|
|||||||
model = "everywhere";
|
model = "everywhere";
|
||||||
}];
|
}];
|
||||||
hardware.printers.ensureDefaultPrinter = "MFC-L8900CDW_series";
|
hardware.printers.ensureDefaultPrinter = "MFC-L8900CDW_series";
|
||||||
|
|
||||||
# Fix ensure-printers service to wait for network availability
|
|
||||||
systemd.services.ensure-printers = {
|
|
||||||
after = [ "cups.service" "network-online.target" ];
|
|
||||||
wants = [ "cups.service" "network-online.target" ];
|
|
||||||
};
|
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user