mirror of
https://github.com/sobolevn/git-secret
synced 2024-11-06 15:20:36 +00:00
5360384085
* bats-core v1.1.0 imported * target 'install-test' removed from Makefile * info re: bats-core import added in vendor/bats-core/README.md
22 lines
545 B
Bash
Executable File
22 lines
545 B
Bash
Executable File
#!/usr/bin/env bash
|
|
|
|
set -e
|
|
|
|
BATS_ROOT="${0%/*}"
|
|
PREFIX="$1"
|
|
|
|
if [[ -z "$PREFIX" ]]; then
|
|
printf '%s\n' \
|
|
"usage: $0 <prefix>" \
|
|
" e.g. $0 /usr/local" >&2
|
|
exit 1
|
|
fi
|
|
|
|
install -d -m 755 "$PREFIX"/{bin,libexec/bats-core,share/man/man{1,7}}
|
|
install -m 755 "$BATS_ROOT/bin"/* "$PREFIX/bin"
|
|
install -m 755 "$BATS_ROOT/libexec/bats-core"/* "$PREFIX/libexec/bats-core"
|
|
install -m 644 "$BATS_ROOT/man/bats.1" "$PREFIX/share/man/man1"
|
|
install -m 644 "$BATS_ROOT/man/bats.7" "$PREFIX/share/man/man7"
|
|
|
|
echo "Installed Bats to $PREFIX/bin/bats"
|