mirror of
https://github.com/jimeh/dotfiles.git
synced 2026-02-19 11:46:40 +00:00
Further enhance tmux's default command
This commit is contained in:
12
bin/login-shell
Executable file
12
bin/login-shell
Executable file
@@ -0,0 +1,12 @@
|
||||
#! /usr/bin/env bash
|
||||
|
||||
# Ensure that tmux windows are by default named after the shell, rather than
|
||||
# full path to the shell binary.
|
||||
shell=$(basename "$SHELL")
|
||||
|
||||
# If reattach-to-user-namespace is not available, just run the command.
|
||||
if [ -n "$(command -v reattach-to-user-namespace)" ]; then
|
||||
reattach-to-user-namespace -l "$shell"
|
||||
else
|
||||
exec "$shell"
|
||||
fi
|
||||
@@ -13,7 +13,7 @@ set -g mouse-select-window on
|
||||
set -g history-limit 10240
|
||||
|
||||
# Mac OS X fix for pbcopy, pbpaste, and launchctl
|
||||
set-option -g default-command "safe-reattach-to-user-namespace -l $SHELL"
|
||||
set-option -g default-command "login-shell"
|
||||
|
||||
# Load Theme
|
||||
source-file "${HOME}/.tmux/themes/powerline-block-green.tmuxtheme"
|
||||
|
||||
Reference in New Issue
Block a user