站点图标 神之眼的博客

MacOS下配置Android环境变量 

當前文章的短網址連結為: https://unos.top/azpm

打开配置文件

sudo vim ~/.zprofile

添加以下环境参数

# Add Android Home
export ANDROID_HOME="/Users/marcus/Downloads/env/android-sdk"
export PATH="$PATH:$ANDROID_HOME/tools"
export PATH="$PATH:$ANDROID_HOME/platform-tools"

立即生效配置

source ~/.zprofile

查看配置是否成功

adb version

android-sdk % adb version
Android Debug Bridge version 1.0.41
Version 35.0.1-11580240
Installed as /Users/marcus/Downloads/env/android-sdk/platform-tools/adb
Running on Darwin 23.4.0 (arm64)

退出移动版