1、打开终端安装 Homebrew
/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
国内请用:
/bin/zsh -c "$(curl -fsSL https://gitee.com/cunkai/HomebrewCN/raw/master/Homebrew.sh)"
最后安装提示安装等待就行。安装完成之后可以使用下面名称测试:brew search redis #搜索包信息
我中途遇到了一些xcode遗留问题,可以参考我的另一篇博客mac os安装Homebrew报错xcode-select: note: no developer tools were found at ‘/Applications/Xcode.app‘
二、按顺序依次:
(如果不清楚安装过了可以用 python -V 看看是什么版本)
brew install python3
brew install scala
brew install apache-spark
nano ~/.bash_profile
Move to the end of the file, and add the following line: export
PYSPARK_PYTHON=python3