Skip to content

Commit

Permalink
Export tsm env vars when sourcing the plugin file
Browse files Browse the repository at this point in the history
  • Loading branch information
RobertAudi committed Jun 2, 2019
1 parent 1fedd7e commit 4c91ede
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions tsm.plugin.zsh
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
typeset -gx TSM_HOME TSM_SESSIONS_DIR TSM_BACKUPS_DIR TSM_DEFAULT_SESSION_FILE TSM_BACKUPS_COUNT

: ${TSM_HOME:=${XDG_DATA_HOME:-$HOME/.local/share}/tsm}
: ${TSM_SESSIONS_DIR:=$TSM_HOME/sessions}
: ${TSM_BACKUPS_DIR:=$TSM_HOME/backups}
: ${TSM_DEFAULT_SESSION_FILE:=$TSM_HOME/default-session.txt}
: ${TSM_BACKUPS_COUNT:=20}

typeset __tsm_dist_dir="${${(%):-%x}:A:h}/dist"
path=("${__tsm_dist_dir}/"bin $path)
fpath=("${__tsm_dist_dir}/"functions $fpath)
Expand Down

0 comments on commit 4c91ede

Please sign in to comment.