Skip to content

Commit

Permalink
re-release install.sh
Browse files Browse the repository at this point in the history
  • Loading branch information
ko1nksm committed Jul 11, 2019
1 parent ec21430 commit 9809f1f
Showing 1 changed file with 9 additions and 9 deletions.
18 changes: 9 additions & 9 deletions install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -25,9 +25,9 @@ VERSION:
. Install from local directory
OPTIONS:
-p, --prefix PREFIX Specify prefix [default: \\\$HOME]
-b, --bin BIN Specify bin directory [default: <PREFIX>/bin]
-d, --dir DIR Specify directory name [default: .$project]
-p, --prefix PREFIX Specify prefix [default: \\\$HOME]
-b, --bin BIN Specify bin directory [default: <PREFIX>/bin]
-d, --dir DIR Specify installation directory [default: <PREFIX>/opt/$project]
-s, --switch Switch version (requires installed via git)
-l, --list List available versions (tags)
--pre Include pre-release
Expand All @@ -36,7 +36,7 @@ OPTIONS:
-h, --help You're looking at it
USAGE

VERSION='' PREFIX=$HOME BIN='' DIR=.$project SWITCH='' PRE='' YES='' FETCH=''
VERSION='' PREFIX=$HOME BIN='' DIR='' SWITCH='' PRE='' YES='' FETCH=''
done=''

finished() {
Expand All @@ -63,7 +63,7 @@ fetch() {
}

unarchive() {
mkdir "$1"
mkdir -p "$1"
tar xzf - -C "$1" --strip-components 1
}

Expand Down Expand Up @@ -111,7 +111,7 @@ while [ $# -gt 0 ]; do
shift
done

BIN=${BIN:-${PREFIX%/}/bin} DIR=${PREFIX%/}/$DIR
BIN=${BIN:-${PREFIX%/}/bin} DIR=${DIR:-${PREFIX%/}/opt/$project}

case $VERSION in
.)
Expand Down Expand Up @@ -143,9 +143,9 @@ case $VERSION in
[ "$VERSION" ] || VERSION=$(latest_version)
esac

echo "Executable file: $BIN/$exec"
echo "Installation : $DIR"
echo "Version : $VERSION"
echo "Executable file : $BIN/$exec"
echo "Installation directory : $DIR"
echo "Version (tag or commit): $VERSION"
case $method in
git) echo "[git] $repo" ;;
archive) echo "[$FETCH] $archive/$VERSION" ;;
Expand Down

0 comments on commit 9809f1f

Please sign in to comment.