Auto merge of #1641 - RyuKojiro:bashless, r=Valloric
Removed the bash dependency that install.sh had People like me use YCM on machines that don't have bash, and it's nice to not have to add it unnecessarily. This removes the bash dependency for installation.
This commit is contained in:
commit
cc94a96c9d
11
install.sh
11
install.sh
@ -1,12 +1,11 @@
|
|||||||
#!/usr/bin/env bash
|
#!/bin/sh
|
||||||
|
|
||||||
set -e
|
SCRIPT_DIR=$(dirname $0 || exit $?)
|
||||||
|
cd $SCRIPT_DIR || exit $?
|
||||||
SCRIPT_DIR="$( cd "$( dirname "${BASH_SOURCE[0]}" )" && pwd )"
|
|
||||||
|
|
||||||
build_file=$SCRIPT_DIR/third_party/ycmd/build.py
|
build_file=$SCRIPT_DIR/third_party/ycmd/build.py
|
||||||
|
|
||||||
if [[ ! -f "$build_file" ]]; then
|
if [ ! -f "$build_file" ]; then
|
||||||
echo "File $build_file doesn't exist; you probably forgot to run:"
|
echo "File $build_file doesn't exist; you probably forgot to run:"
|
||||||
printf "\n\tgit submodule update --init --recursive\n\n"
|
printf "\n\tgit submodule update --init --recursive\n\n"
|
||||||
exit 1
|
exit 1
|
||||||
@ -21,7 +20,7 @@ if command_exists python2; then
|
|||||||
PYTHON_BINARY=python2
|
PYTHON_BINARY=python2
|
||||||
fi
|
fi
|
||||||
|
|
||||||
$PYTHON_BINARY "$build_file" "$@"
|
$PYTHON_BINARY "$build_file" "$@" || exit $?
|
||||||
|
|
||||||
# Remove old YCM libs if present so that YCM can start.
|
# Remove old YCM libs if present so that YCM can start.
|
||||||
rm -f python/*ycm_core.* &> /dev/null
|
rm -f python/*ycm_core.* &> /dev/null
|
||||||
|
Loading…
Reference in New Issue
Block a user