File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -14,8 +14,10 @@ ARCH=$(uname -m)
1414
1515if [ " $PLATFORM " = " Darwin" ]; then
1616 OS=darwin
17+ OS_NAME=macOS
1718elif [ " ${PLATFORM%% * } " = " Linux" ]; then
1819 OS=linux
20+ OS_NAME=Linux
1921else
2022 echo " This installer is only supported on Linux and MacOS."
2123 exit 1
@@ -78,12 +80,12 @@ tar xzf "$TEMP_FILE" -C "$TEMP_FOLDER" codecrafters
7880chmod 0755 " $TEMP_FOLDER /codecrafters"
7981
8082if ! mkdir -p " $INSTALL_DIR " 2> /dev/null; then
81- echo -e " ${MUTED} Note:${NC} You might need to enter your password to install."
83+ echo -e " ${MUTED} Note:${NC} You might need to enter your ${OS_NAME} user password to install."
8284 sudo mkdir -p " $INSTALL_DIR "
8385fi
8486
8587if ! mv " $TEMP_FOLDER /codecrafters" " $INSTALL_PATH " 2> /dev/null; then
86- echo -e " ${MUTED} Note:${NC} You might need to enter your password to install."
88+ echo -e " ${MUTED} Note:${NC} You might need to enter your ${OS_NAME} user password to install."
8789 sudo mv " $TEMP_FOLDER /codecrafters" " $INSTALL_PATH "
8890fi
8991
You can’t perform that action at this time.
0 commit comments