Skip to content
This repository has been archived by the owner on Apr 29, 2021. It is now read-only.

install.sh should make files executable before copy #246

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 7 additions & 6 deletions install.sh
Original file line number Diff line number Diff line change
Expand Up @@ -28,10 +28,11 @@ if [ -z "$1" ]; then
fi

BATS_ROOT="$(abs_dirname "$0")"
mkdir -p "$PREFIX"/{bin,libexec,share/man/man{1,7}}
cp -R "$BATS_ROOT"/bin/* "$PREFIX"/bin
cp -R "$BATS_ROOT"/libexec/* "$PREFIX"/libexec
cp "$BATS_ROOT"/man/bats.1 "$PREFIX"/share/man/man1
cp "$BATS_ROOT"/man/bats.7 "$PREFIX"/share/man/man7
mkdir -p "${PREFIX%/}"/{bin,libexec,share/man/man{1,7}}
chmod +x "$BATS_ROOT"/bin/* "$BATS_ROOT"/libexec/*
cp -R "$BATS_ROOT"/bin/* "${PREFIX%/}"/bin
cp -R "$BATS_ROOT"/libexec/* "${PREFIX%/}"/libexec
cp "$BATS_ROOT"/man/bats.1 "${PREFIX%/}"/share/man/man1
cp "$BATS_ROOT"/man/bats.7 "${PREFIX%/}"/share/man/man7

echo "Installed Bats to $PREFIX/bin/bats"
echo "Installed Bats to ${PREFIX%/}/bin/bats"