diff options
-rw-r--r-- | .config/tmuxinator/.template.yml | 6 | ||||
-rwxr-xr-x | .vifm/scripts/bootstrap.sh | 18 | ||||
-rw-r--r-- | .vifm/vifmrc | 2 |
3 files changed, 25 insertions, 1 deletions
diff --git a/.config/tmuxinator/.template.yml b/.config/tmuxinator/.template.yml new file mode 100644 index 0000000..6bc617b --- /dev/null +++ b/.config/tmuxinator/.template.yml @@ -0,0 +1,6 @@ +windows: + - editor: + layout: main-vertical + panes: + - vim + - null diff --git a/.vifm/scripts/bootstrap.sh b/.vifm/scripts/bootstrap.sh new file mode 100755 index 0000000..422809c --- /dev/null +++ b/.vifm/scripts/bootstrap.sh @@ -0,0 +1,18 @@ +#!/bin/bash +# Create tmuxinator project if it doesn't exist and run it + +ROOT=$1 +NAME=$(basename $1) +CONFIG_DIR=~/.config/tmuxinator +CONFIG=$CONFIG_DIR/$NAME.yml + +if [ -f $CONFIG ]; then + echo 'Project already exists' +else + echo name: $NAME >> $CONFIG + echo root: $ROOT >> $CONFIG + cat $CONFIG_DIR/.template.yml >> $CONFIG +fi + +tmuxinator start $NAME + diff --git a/.vifm/vifmrc b/.vifm/vifmrc index 7b4757b..4aeb9bd 100644 --- a/.vifm/vifmrc +++ b/.vifm/vifmrc @@ -141,7 +141,7 @@ command! make !!make %a command! mkcd :mkdir %a | cd %a command! vgrep vim "+grep %a" command! reload :write | restart -command! w :!i3-workspace.sh %d/%c +command! w :!bootstrap.sh %d/%c " ------------------------------------------------------------------------------ |