From 557a1dd51c0be5732c6c49c5baca024e9366b0e7 Mon Sep 17 00:00:00 2001 From: millken Date: Thu, 23 Nov 2023 12:23:32 +0800 Subject: [PATCH] fix ioctl update failed on mac (#3957) --- install-cli.sh | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) diff --git a/install-cli.sh b/install-cli.sh index 422803e5e3..84f74a71c0 100755 --- a/install-cli.sh +++ b/install-cli.sh @@ -24,7 +24,7 @@ BREW_UPDATE_CMD="brew update" BREW_INSTALL_CMD="brew install ioctl" BREW_REINSTALL_CMD="brew reinstall ioctl" BREW_UNSTABLE_TAP_CMD="brew tap iotexproject/ioctl-unstable" -BREW_UNSTABLE_INSTALL_CMD="brew install --HEAD iotexproject/ioctl-unstable/ioctl-unstable" +BREW_UNSTABLE_INSTALL_CMD="brew install iotexproject/ioctl-unstable/ioctl-unstable" BREW_UNSTABLE_REINSTALL_CMD="brew reinstall ioctl-unstable" BREW_INSTALLED_PATH="/usr/local/bin" @@ -124,25 +124,18 @@ fi if [ "${OS}" = "darwin" ];then if test -x "$(command -v brew)"; then if [ "$1" = "unstable" ]; then - if [ `command -v ioctl` ]; then - rm -f $BREW_INSTALLED_PATH/ioctl - fi - if [ `command -v ioctl-unstable` ]; then $BREW_UNSTABLE_REINSTALL_CMD else $BREW_UNSTABLE_TAP_CMD && $BREW_UNSTABLE_INSTALL_CMD fi - ln -s $BREW_INSTALLED_PATH/ioctl-unstable $BREW_INSTALLED_PATH/ioctl echo "Command-line tools is installed to `command -v ioctl-unstable`" else if [ `command -v ioctl` ]; then - rm -f $BREW_INSTALLED_PATH/ioctl $BREW_UPDATE_CMD && $BREW_REINSTALL_CMD else $BREW_UPDATE_CMD && $BREW_INSTALL_CMD fi - echo "Command-line tools is installed to `command -v ioctl`" fi exit 0