summaryrefslogtreecommitdiff
path: root/home-manager
diff options
context:
space:
mode:
authoralex <[email protected]>2026-10-17 18:51:30 +0200
committeralex <[email protected]>2026-10-17 18:51:30 +0200
commit73a4ca1dbd42a92839ab03e832f48fe7bed96de7 (patch)
tree306b9a81146d84e23f69b2d37bed93728dd8727e /home-manager
parent8c72ed35ec5c8efda1dd3a2c2037a6b9126f0d71 (diff)
downloadnixos-73a4ca1dbd42a92839ab03e832f48fe7bed96de7.tar.xz
nixos-73a4ca1dbd42a92839ab03e832f48fe7bed96de7.zip
added tmux config to home manager
Diffstat (limited to 'home-manager')
-rw-r--r--home-manager/home.nix1
-rw-r--r--home-manager/modules/tmux.nix3
-rw-r--r--home-manager/tmux.conf19
3 files changed, 23 insertions, 0 deletions
diff --git a/home-manager/home.nix b/home-manager/home.nix
index cdf9e2f..f4c1189 100644
--- a/home-manager/home.nix
+++ b/home-manager/home.nix
@@ -8,6 +8,7 @@
./modules/base.nix
./modules/git.nix
./modules/hyprland.nix
+ ./modules/tmux.nix
./modules/packages-basic.nix
./modules/packages-development.nix
];
diff --git a/home-manager/modules/tmux.nix b/home-manager/modules/tmux.nix
new file mode 100644
index 0000000..8b02285
--- /dev/null
+++ b/home-manager/modules/tmux.nix
@@ -0,0 +1,3 @@
+{ ... }: {
+ home.file.".tmux.conf".source = ../tmux.conf;
+}
diff --git a/home-manager/tmux.conf b/home-manager/tmux.conf
new file mode 100644
index 0000000..ece9774
--- /dev/null
+++ b/home-manager/tmux.conf
@@ -0,0 +1,19 @@
+# Enable mouse support for resizing panes and scrolling
+set -g mouse on
+set -g base-index 1
+set -g default-terminal "tmux-256color"
+# Enable True Color support (crucial for code editor themes)
+set -ga terminal-overrides ",*256col*:Tc"
+
+# More intuitive split commands that inherit the current directory.
+# This is critical for direnv to work smoothly across splits.
+bind | split-window -h -c "#{pane_current_path}"
+bind - split-window -v -c "#{pane_current_path}"
+unbind '"'
+unbind %
+
+# Open new windows in the current directory
+bind c new-window -c "#{pane_current_path}"
+
+# Reload user tmux config on the fly with Prefix + r
+bind r source-file ~/.tmux.conf \; display "Config reloaded!"