#!/bin/bash
+tmux_conf() {
+ tmux -f $XDG_CONFIG_HOME/tmux/tmux.conf "$@"
+}
+
type="${1:-bash}"
if [ -n "$TMUX" ]; then
m=switch-client
tmux $m -t "$type"
else
if [ "$type" = "remote" ]; then
- tmux new-session -d -c $start_dir -s "$type" mosh immae.eu \; \
+ tmux_conf new-session -d -c $start_dir -s "$type" mosh immae.eu \; \
$m -t "$type"
elif [ -n "$start_dir" ]; then
- tmux new-session -d -c $start_dir -s "$type" \; \
+ tmux_conf new-session -d -c $start_dir -s "$type" \; \
$m -t "$type" \; \
new-window -c $start_dir
elif [ -d "$HOME/workdir/$type" ]; then
- tmux new-session -d -c "$HOME/workdir/$type" -s "$type" \; \
+ tmux_conf new-session -d -c "$HOME/workdir/$type" -s "$type" \; \
$m -t "$type" \; \
send-keys "../start" C-m \; \
rename-window "running" \; \