From 5832c0d70754ad49c4c0d49789672b155930b6be Mon Sep 17 00:00:00 2001 From: thek4n Date: Fri, 24 May 2024 16:50:26 +0300 Subject: [PATCH] tmux mappings --- home/user/.config/tmux/mappings.conf | 2 +- home/user/.tmux/10.sh | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/home/user/.config/tmux/mappings.conf b/home/user/.config/tmux/mappings.conf index 29d8ccb..4aa7a22 100644 --- a/home/user/.config/tmux/mappings.conf +++ b/home/user/.config/tmux/mappings.conf @@ -50,7 +50,7 @@ bind R command-prompt -I '#S' -p "New session name:" "rename-session '%%'" # SSH Session -bind h command-prompt -p "Remote host:" "new-session -n 1 -s 'ssh-%1' -A ssh %1" +bind H command-prompt -p "Remote host:" "new-session -s 'ssh-%1' -A ssh %1 \; set default-command 'ssh %1' \; set remain-on-exit on \; set detach-on-destroy on" # Call prompt via prefix ; diff --git a/home/user/.tmux/10.sh b/home/user/.tmux/10.sh index 57c234f..1204e8a 100755 --- a/home/user/.tmux/10.sh +++ b/home/user/.tmux/10.sh @@ -9,4 +9,5 @@ WORKING_PROJECT="$(mktemp -d)" tmux new-session -s "$SESSION" -d -n "$MAINW" -c "$WORKING_PROJECT" tmux switch-client -t "$SESSION" -tmux splitw -t "$SESSION:$MAINW" -d -b -h -l "$_tmux_new_pane_size" -c '#{pane_current_path}' \ No newline at end of file +tmux splitw -t "$SESSION:$MAINW" -d -b -h -l "$_tmux_new_pane_size" -c '#{pane_current_path}' +tmux send-keys -t "$SESSION:$MAINW.1" 'git clone .' Left Left \ No newline at end of file