aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rwxr-xr-xsrc/plug.sh22
1 files changed, 17 insertions, 5 deletions
diff --git a/src/plug.sh b/src/plug.sh
index ab022bc..1a95764 100755
--- a/src/plug.sh
+++ b/src/plug.sh
@@ -33,7 +33,7 @@ fi
PLUG_PATH=".vim/pack/$USER/start/"
VIM_PATH="vim"
JOBS=4
-LOG_FILE=~/.plug/$(date -Is).log
+LOG_FILE=/tmp/PLUGVIM-$(date -Is).log
GIT_DIR="$HOME/dotfiles"
PROGRAM="plug"
touch $LOG_FILE
@@ -84,7 +84,7 @@ cmd_usage () {
}
cmd_install() {
- while getopts ":ocg:d:" opt;
+ while getopts ":ocg:d:l" opt;
do
case $opt in
o)
@@ -99,6 +99,9 @@ cmd_install() {
d)
VIM_PATH=$OPTARG
;;
+ l)
+ LOG_FILE=~/.plug/$(date -Is).log
+ ;;
\?)
echo "Invalid option: -$OPTARG" >&2
return
@@ -135,7 +138,7 @@ cmd_install() {
}
cmd_update() {
- while getopts ":jc" opt;
+ while getopts ":jcl" opt;
do
case $opt in
c)
@@ -144,6 +147,9 @@ cmd_update() {
j)
JOBS=$OPTARG
;;
+ l)
+ LOG_FILE=~/.plug/$(date -Is).log
+ ;;
\?)
echo "Invalid option: -$OPTARG" >&2
return
@@ -173,7 +179,7 @@ cmd_update() {
}
cmd_remove() {
- while getopts ":ocd:g:" opt;
+ while getopts ":ocd:g:l" opt;
do
case $opt in
o)
@@ -188,6 +194,9 @@ cmd_remove() {
d)
VIM_PATH=$OPTARG
;;
+ l)
+ LOG_FILE=~/.plug/$(date -Is).log
+ ;;
\?)
echo "Invalid option: -$OPTARG" >&2
return
@@ -224,12 +233,15 @@ cmd_remove() {
}
cmd_list() {
- while getopts ":ocg:" opt;
+ while getopts ":ocg:l" opt;
do
case $opt in
g)
GIT_DIR=$OPTARG
;;
+ l)
+ LOG_FILE=~/.plug/$(date -Is).log
+ ;;
\?)
echo "Invalid option: -$OPTARG" >&2
return