Skip to content

Commit

Permalink
Fix TMPDIR on OSX for creating vimclip directory
Browse files Browse the repository at this point in the history
  • Loading branch information
cjbassi committed Feb 2, 2019
1 parent c52a5e7 commit 8b07d50
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion vimclip
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,10 @@ if [ "Darwin" = $(uname -s) ]; then
exit 1
fi

mkdir -p /tmp/vimclip
if [ -z $TMPDIR ]; then
TMPDIR=/tmp
fi
mkdir -p $TMPDIR/vimclip
TMP=$(mktemp -t vimclip/vimclip)
$EDITOR $TMP
pbcopy < $TMP
Expand Down

0 comments on commit 8b07d50

Please sign in to comment.