Mac OS Create case-sensitive build environment

hdiutil create -type SPARSE -fs 'Case-sensitive Journaled HFS+' -size 40g ~/android.dmg
 
 
注意:如果系统使用hdiutil create创建镜像时,生成的镜像文件为android.dmg.sparsefile(不是android.dmg),则需要使用~/android.dmg.sparsefile替换~/android.dmg
hdiutil attach ~/android.dmg.sparseimage -mountpoint /Volumes/android
cd /Volumes/android
 
 
卸载挂载到目录/Volumes/android的大小写敏感的磁盘镜像文件~/android.dmg
hdiutil detach /Volumes/android

注:为了方便挂载和卸载磁盘镜像文件,你可以写两个方法命令,将这两个方法命令加如到~/.bash_profile,例如:

命令行中执行mountAndroid挂载磁盘镜像 ~/android.dmg到目录/Volumes/android:

# mount the android file image
function mountAndroid { hdiutil attach ~/android.dmg -mountpoint /Volumes/android; }


命令行中执行umountAndroid卸载挂载到目录/Volumes/android的磁盘镜像~/android.dmg:

# unmount the android file image
function umountAndroid() { hdiutil detach /Volumes/android; }
 
 
 
  
 
 

你可能感兴趣的:(Mac OS Create case-sensitive build environment)