diff --git a/sh/tmux.sh b/sh/tmux.sh index 9d3777e..b15df86 100644 --- a/sh/tmux.sh +++ b/sh/tmux.sh @@ -2,24 +2,22 @@ # │ tmux │ # ╰──────╯ -# ╭──────┬─────────╮ -# │ tmux │ servers │ -# ╰──────┴─────────╯ - -rwx_tmux_server() { - basename "${TMUX}" | - cut \ - --delimiter "," \ - --fields "1" -} - # ╭──────┬───────╮ # │ tmux │ setup │ # ╰──────┴───────╯ rwx_tmux_setup() { - local file + local file script file="${HOME}/.tmux.conf" + script="${HOME}/.tmux.sh" + rwx_file_write "${script}" "\ +rwx_tmux_server() { + basename \"\${TMUX}\" | + cut \\ + --delimiter \",\" \\ + --fields \"1\" +} +" rwx_file_write "${file}" "\ # ╭────────╮ # │ option │ @@ -62,7 +60,7 @@ set-option -g set-titles on # set title to working directory set-option -g set-titles-string '\ -#(rwx_tmux_server)\ +#(sh -c \". ${script}; rwx_tmux_server\")\ → \ #{session_name}\ → \