mirror of
https://github.com/k3s-io/kubernetes.git
synced 2025-09-10 05:30:26 +00:00
Fix update/verify-codecgen.sh for OSX.
This commit is contained in:
@@ -40,3 +40,16 @@ source "${KUBE_ROOT}/hack/lib/golang.sh"
|
||||
source "${KUBE_ROOT}/hack/lib/etcd.sh"
|
||||
|
||||
KUBE_OUTPUT_HOSTBIN="${KUBE_OUTPUT_BINPATH}/$(kube::util::host_platform)"
|
||||
|
||||
# emulates "readlink -f" which is not available on BSD (OS X).
|
||||
function readlinkdashf {
|
||||
path=$1
|
||||
# Follow links until there are no more links to follow.
|
||||
while readlink "$path"; do
|
||||
path="$(readlink $path)"
|
||||
done
|
||||
# Convert to canonical path.
|
||||
path=$(cd "$(dirname "${path}")" && pwd -P)
|
||||
echo "$path"
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user