Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(build): improve darwin support #336

Merged
Merged
Show file tree
Hide file tree
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
4 changes: 2 additions & 2 deletions hack/ensure-clusterctl.sh
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ verify_clusterctl_version() {
Detected clusterctl version: v${clusterctl_version}.
Install v${MINIMUM_CLUSTERCTL_VERSION} of clusterctl.
EOF

echo 'Installing Clusterctl' && install_clusterctl
else
cat <<EOF
Expand All @@ -45,7 +45,7 @@ EOF
}

install_clusterctl() {
if [[ "${OSTYPE}" == "linux"* || "${OSTYPE}" == "darwin22"* ]]; then
if [[ "${OSTYPE}" == "linux"* || "${OSTYPE}" == "darwin"* ]]; then
curl -sLo "clusterctl" "https://github.com/kubernetes-sigs/cluster-api/releases/download/v${MINIMUM_CLUSTERCTL_VERSION}/clusterctl-linux-amd64"
copy_binary
else
Expand Down
2 changes: 1 addition & 1 deletion hack/ensure-controller-gen.sh
Original file line number Diff line number Diff line change
Expand Up @@ -46,7 +46,7 @@ EOF
}

install_controller_gen() {
if [[ "${OSTYPE}" == "linux"* || "${OSTYPE}" == "darwin22"* ]]; then
if [[ "${OSTYPE}" == "linux"* || "${OSTYPE}" == "darwin"* ]]; then
if ! [ -d "${BIN_ROOT}" ]; then
mkdir -p "${BIN_ROOT}"
fi
Expand Down
2 changes: 1 addition & 1 deletion hack/ensure-envsubst.sh
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ check_envsubst_installed() {
}

install_envsubst() {
if [[ "${OSTYPE}" == "linux"* || "${OSTYPE}" == "darwin22"* ]]; then
if [[ "${OSTYPE}" == "linux"* || "${OSTYPE}" == "darwin"* ]]; then
if ! [ -d "${BIN_ROOT}" ]; then
mkdir -p "${BIN_ROOT}"
fi
Expand Down
2 changes: 1 addition & 1 deletion hack/ensure-envtest.sh
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ EOF
}

install_envtest() {
if [[ "${OSTYPE}" == "linux"* || "${OSTYPE}" == "darwin22"* ]]; then
if [[ "${OSTYPE}" == "linux"* || "${OSTYPE}" == "darwin"* ]]; then
if ! [ -d "${BIN_ROOT}" ]; then
mkdir -p "${BIN_ROOT}"
fi
Expand Down
2 changes: 1 addition & 1 deletion hack/ensure-gh.sh
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ EOF
}

install_gh() {
if [[ "${OSTYPE}" == "linux"* || "${OSTYPE}" == "darwin22"* ]]; then
if [[ "${OSTYPE}" == "linux"* || "${OSTYPE}" == "darwin"* ]]; then
if ! [ -d "${BIN_ROOT}" ]; then
mkdir -p "${BIN_ROOT}"
fi
Expand Down
2 changes: 1 addition & 1 deletion hack/ensure-golangci-lint.sh
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ EOF
}

install_golangci_lint() {
if [[ "${OSTYPE}" == "linux"* || "${OSTYPE}" == "darwin22"* ]]; then
if [[ "${OSTYPE}" == "linux"* || "${OSTYPE}" == "darwin"* ]]; then
if ! [ -d "${BIN_ROOT}" ]; then
mkdir -p "${BIN_ROOT}"
fi
Expand Down
2 changes: 1 addition & 1 deletion hack/ensure-kind.sh
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ EOF
}

install_kind() {
if [[ "${OSTYPE}" == "linux"* || "${OSTYPE}" == "darwin22"* ]]; then
if [[ "${OSTYPE}" == "linux"* || "${OSTYPE}" == "darwin"* ]]; then
curl -sLo "kind" "https://github.com/kubernetes-sigs/kind/releases/download/${MINIMUM_KIND_VERSION}/kind-linux-amd64"
copy_binary
else
Expand Down
2 changes: 1 addition & 1 deletion hack/ensure-kubebuildertool.sh
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ EOF
}

install_kubebuildertool() {
if [[ "${OSTYPE}" == "linux"* || "${OSTYPE}" == "darwin22"* ]]; then
if [[ "${OSTYPE}" == "linux"* || "${OSTYPE}" == "darwin"* ]]; then
if ! [ -d "${BIN_ROOT}" ]; then
mkdir -p "${BIN_ROOT}"
fi
Expand Down
2 changes: 1 addition & 1 deletion hack/ensure-kubectl.sh
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ EOF
}

install_kubectl() {
if [[ "${OSTYPE}" == "linux"* || "${OSTYPE}" == "darwin22"* ]]; then
if [[ "${OSTYPE}" == "linux"* || "${OSTYPE}" == "darwin"* ]]; then
curl -sLo "kubectl" "https://storage.googleapis.com/kubernetes-release/release/v${MINIMUM_KUBECTL_VERSION}/bin/linux/amd64/kubectl"
copy_binary
else
Expand Down
2 changes: 1 addition & 1 deletion hack/ensure-kustomize.sh
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ EOF
}

install_kustomize() {
if [[ "${OSTYPE}" == "linux"* || "${OSTYPE}" == "darwin22"* ]]; then
if [[ "${OSTYPE}" == "linux"* || "${OSTYPE}" == "darwin"* ]]; then
if ! [ -d "${BIN_ROOT}" ]; then
mkdir -p "${BIN_ROOT}"
fi
Expand Down
2 changes: 1 addition & 1 deletion hack/ensure-mdbook.sh
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ EOF
}

install_mdbook() {
if [[ "${OSTYPE}" == "linux"* || "${OSTYPE}" == "darwin22"* ]]; then
if [[ "${OSTYPE}" == "linux"* || "${OSTYPE}" == "darwin"* ]]; then
if ! [ -d "${BIN_ROOT}" ]; then
mkdir -p "${BIN_ROOT}"
fi
Expand Down
2 changes: 1 addition & 1 deletion hack/ensure-mockgen.sh
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ EOF
}

install_mockgen() {
if [[ "${OSTYPE}" == "linux"* || "${OSTYPE}" == "darwin22"* ]]; then
if [[ "${OSTYPE}" == "linux"* || "${OSTYPE}" == "darwin"* ]]; then
if ! [ -d "${BIN_ROOT}" ]; then
mkdir -p "${BIN_ROOT}"
fi
Expand Down
2 changes: 1 addition & 1 deletion hack/ensure-packer.sh
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ EOF
}

install_packer() {
if [[ "${OSTYPE}" == "linux"* || "${OSTYPE}" == "darwin22"* ]]; then
if [[ "${OSTYPE}" == "linux"* || "${OSTYPE}" == "darwin"* ]]; then
curl -sLo "packer.zip" "https://releases.hashicorp.com/packer/${MINIMUM_PACKER_VERSION}/packer_${MINIMUM_PACKER_VERSION}_linux_amd64.zip" && unzip packer.zip -d packer-bin && mv packer-bin/packer . && rm -rf packer.zip packer-bin
copy_binary
else
Expand Down
2 changes: 1 addition & 1 deletion hack/ensure-tilt.sh
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ EOF
}

install_tilt() {
if [[ "${OSTYPE}" == "linux"* || "${OSTYPE}" == "darwin22"* ]]; then
if [[ "${OSTYPE}" == "linux"* || "${OSTYPE}" == "darwin"* ]]; then
curl -fsSL "https://github.com/tilt-dev/tilt/releases/download/v$MINIMUM_TILT_VERSION/tilt.$MINIMUM_TILT_VERSION.linux.x86_64.tar.gz" | tar -xzv tilt
copy_binary
else
Expand Down
2 changes: 1 addition & 1 deletion hack/ensure-yamlfmt.sh
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ check_yamlfmt_installed() {
}

install_yamlfmt() {
if [[ "${OSTYPE}" == "linux"* || "${OSTYPE}" == "darwin22"* ]]; then
if [[ "${OSTYPE}" == "linux"* || "${OSTYPE}" == "darwin"* ]]; then
if ! [ -d "${BIN_ROOT}" ]; then
mkdir -p "${BIN_ROOT}"
fi
Expand Down
2 changes: 1 addition & 1 deletion hack/verify-buildifier.sh
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ EOF
}

install_buildifier() {
if [[ "${OSTYPE}" == "linux"* || "${OSTYPE}" == "darwin22"* ]]; then
if [[ "${OSTYPE}" == "linux"* || "${OSTYPE}" == "darwin"* ]]; then
if ! [ -d "${BIN_ROOT}" ]; then
mkdir -p "${BIN_ROOT}"
fi
Expand Down
2 changes: 1 addition & 1 deletion hack/verify-shellcheck.sh
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ EOF
}

install_shellcheck() {
if [[ "${OSTYPE}" == "linux"* || "${OSTYPE}" == "darwin22"* ]]; then
if [[ "${OSTYPE}" == "linux"* || "${OSTYPE}" == "darwin"* ]]; then
if ! [ -d "${BIN_ROOT}" ]; then
mkdir -p "${BIN_ROOT}"
fi
Expand Down
Loading