mirror of https://github.com/linkerd/linkerd2.git
18 lines
313 B
Bash
Executable File
18 lines
313 B
Bash
Executable File
#!/usr/bin/env sh
|
|
|
|
set -eu
|
|
|
|
bindir=$( cd "${0%/*}" && pwd )
|
|
rootdir=$( cd "$bindir"/.. && pwd )
|
|
# shellcheck source=_os.sh
|
|
. "$bindir"/_os.sh
|
|
|
|
bin=$rootdir/target/cli/$(os)/linkerd
|
|
|
|
# build linkerd executable if it does not exist
|
|
if [ ! -f "$bin" ]; then
|
|
"$bindir"/build-cli-bin >/dev/null
|
|
fi
|
|
|
|
exec "$bin" "$@"
|