1、system_profiler SPUSBDataType 查看Mac系统全部USB设备信息android
2、[写入内容到指定文件]bash
echo "0x1bbb" > ~/.android/adb_usb.ini(~/表明全部符合条件的上级目录)app
3、[配置环境变量]编辑器
打开或建立配置环境变量文件gradle
cd ~spa
touch .bash_profileblog
open -e .bash_profile (关键是这一句,直接用本文编辑器打开bash_profile,若是没有会建立该文件)it
source .bash_profile(更新刚配置的环境变量,使配置生效)class
如下是adb和gradle环境变量的配置
变量
[Mac显示隐藏文件夹]
defaults write com.apple.finder AppleShowAllFiles -bool true(显示)
defaults write com.apple.finder AppleShowAllFiles -bool false(关闭)
(或者defaults write com.apple.finder AppleShowAllFiles YES/NO)