1
0
Fork 0

Add Tmux (in a smarter way)

This commit is contained in:
Aires 2024-05-06 00:05:14 -04:00
parent 92d976ff0f
commit 644fac4baf
3 changed files with 22 additions and 9 deletions

View file

@ -12,14 +12,8 @@ with lib;
config = mkIf cfg.enable { config = mkIf cfg.enable {
nixpkgs.config.allowUnfree = true; nixpkgs.config.allowUnfree = true;
environment.systemPackages = with pkgs; [ environment.systemPackages = with pkgs; [
# Install Beeper, but override the InstallPhase so it uses Wayland. # Check Beeper Flatpak status here: https://github.com/daegalus/beeper-flatpak-wip/issues/1
# Check Flatpak status here: https://github.com/daegalus/beeper-flatpak-wip/issues/1 beeper
(beeper.overrideAttrs (oldAttrs: {
postInstall = ''
wrapProgram $out/bin/beeper \
--add-flags "\''${NIXOS_OZONE_WL:+\''${WAYLAND_DISPLAY:+--ozone-platform-hint=wayland --enable-features=WaylandWindowDecorations}} --no-update"
'';
}))
]; ];
host.ui.flatpak.enable = true; host.ui.flatpak.enable = true;

19
modules/apps/tmux.nix Normal file
View file

@ -0,0 +1,19 @@
{ pkgs, config, lib, ... }:
let
cfg = config.host.apps.tmux;
in
with lib;
{
options = {
host.apps.tmux.enable = mkEnableOption (mdDoc "Enables tmux - terminal multiplexer");
};
config = mkIf cfg.enable {
programs.tmux = {
enable = true;
newSession = true;
clock24 = true;
};
};
}

View file

@ -7,10 +7,10 @@ in
imports = [ (modulesPath + "/installer/scan/not-detected.nix") ]; imports = [ (modulesPath + "/installer/scan/not-detected.nix") ];
config = mkIf (role == "server") { config = mkIf (role == "server") {
host.apps.tmux.enable = true;
environment.systemPackages = with pkgs; [ environment.systemPackages = with pkgs; [
htop htop
mdadm mdadm
tmux
]; ];
}; };
} }