From 02279f6d7250495b04cb9229f093144189f1fdd8 Mon Sep 17 00:00:00 2001 From: Alicia Sykes Date: Thu, 14 Dec 2023 18:12:18 +0000 Subject: [PATCH] Adds aliases for Tmux --- config/zsh/aliases/tmux.zsh | 57 +++++++++++++++++++++++++++++++++++++ 1 file changed, 57 insertions(+) create mode 100644 config/zsh/aliases/tmux.zsh diff --git a/config/zsh/aliases/tmux.zsh b/config/zsh/aliases/tmux.zsh new file mode 100644 index 0000000..3c32819 --- /dev/null +++ b/config/zsh/aliases/tmux.zsh @@ -0,0 +1,57 @@ +###################################################################### +# ZSH aliases and helper functions for Tmux and common Tmux tasks # +# Licensed under MIT (C) Alicia Sykes 2022 # +###################################################################### + +# Tmux shortcuts +alias tmux='tmux -u' +alias t='tmux' +alias ta='tmux attach-session -t' +alias tn='tmux new-session -s' +alias tl='tmux list-sessions' +alias tk='tmux kill-session -t' + +# Tmux helpers +function tsplit() { + tmux split-window -v "$@" +} + +function tvsplit() { + tmux split-window -h "$@" +} + +function tresize() { + tmux resize-pane -D "$@" +} + +function tresizeh() { + tmux resize-pane -R "$@" +} + +function tresizev() { + tmux resize-pane -U "$@" +} + +function tresizeleft() { + tmux resize-pane -L "$@" +} + +function tresizeup() { + tmux resize-pane -U "$@" +} + +function tresizedown() { + tmux resize-pane -D "$@" +} + +function tresizeup() { + tmux resize-pane -U "$@" +} + +function tresizeleft() { + tmux resize-pane -L "$@" +} + +function tresizeright() { + tmux resize-pane -R "$@" +}