fix install script
This commit is contained in:
parent
1d1ec88edb
commit
894b011bb1
17
install.sh
17
install.sh
|
@ -14,9 +14,10 @@ USAGE
|
||||||
|
|
||||||
OPTIONS
|
OPTIONS
|
||||||
-h, --help Display this help message.
|
-h, --help Display this help message.
|
||||||
|
-y --yes Skip confirmations.
|
||||||
--symlink Symlink the files. This is the default behavior.
|
--symlink Symlink the files. This is the default behavior.
|
||||||
--copy Copy the files.
|
--copy Copy the files.
|
||||||
--noscript Skip the post-install script
|
--noscript Skip the pre-install and the post-install scripts
|
||||||
|
|
||||||
EOF
|
EOF
|
||||||
}
|
}
|
||||||
|
@ -99,11 +100,6 @@ make_link() {
|
||||||
fi
|
fi
|
||||||
}
|
}
|
||||||
|
|
||||||
post_install() {
|
|
||||||
# install vim plugins
|
|
||||||
vim -E +"call dein#update()" +"qall!" /dev/null &>/dev/null
|
|
||||||
}
|
|
||||||
|
|
||||||
short_args=hy
|
short_args=hy
|
||||||
long_args=help,yes,symlink,copy,noscript
|
long_args=help,yes,symlink,copy,noscript
|
||||||
|
|
||||||
|
@ -154,6 +150,11 @@ fi
|
||||||
|
|
||||||
pushd "${0%/*}" >/dev/null
|
pushd "${0%/*}" >/dev/null
|
||||||
|
|
||||||
|
if [[ -f "./scripts/pre-install.sh" && -z "$OPT_NOSCRIPT" ]]; then
|
||||||
|
log "*" "Running pre-install"
|
||||||
|
bash ./scripts/pre-install.sh
|
||||||
|
fi
|
||||||
|
|
||||||
for file_source in "files"; do
|
for file_source in "files"; do
|
||||||
log "*" "Processing $file_source"
|
log "*" "Processing $file_source"
|
||||||
for file_path in $(get_path "$file_source"); do
|
for file_path in $(get_path "$file_source"); do
|
||||||
|
@ -161,9 +162,9 @@ for file_source in "files"; do
|
||||||
done
|
done
|
||||||
done
|
done
|
||||||
|
|
||||||
if [[ -z "$OPT_NOSCRIPT" ]]; then
|
if [[ -f "./scripts/post-install.sh" && -z "$OPT_NOSCRIPT" ]]; then
|
||||||
log "*" "Running post-install"
|
log "*" "Running post-install"
|
||||||
post_install
|
bash ./scripts/post-install.sh
|
||||||
fi
|
fi
|
||||||
|
|
||||||
popd >/dev/null
|
popd >/dev/null
|
||||||
|
|
|
@ -0,0 +1,5 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
# install vim plugins
|
||||||
|
vim -E +"call dein#update()" +"qall!" /dev/null &>/dev/null
|
||||||
|
|
Loading…
Reference in New Issue