Mos*_*dam 427 macos uninstall android-studio
我最近在我的Macbook Pro上下载了Android Studio,每次打开它时都会搞砸它.它给了我插件错误和其他几个错误.我需要从我的mac上完全卸载它.我试图从我的mac中删除它,然后再次安装,就像你第一次做的那样,但它没有做任何事情,现在出现同样的问题.
我怎样才能完全删除它并重新安装一个新的?
Sim*_*mon 1072
在终端中执行这些命令(不包括带有主题标签的行 - 它们是注释):
# Deletes the Android Studio application
# Note that this may be different depending on what you named the application as, or whether you downloaded the preview version
rm -Rf /Applications/Android\ Studio.app
# Delete All Android Studio related preferences
# The asterisk here should target all folders/files beginning with the string before it
rm -Rf ~/Library/Preferences/AndroidStudio*
# Deletes the Android Studio's plist file
rm -Rf ~/Library/Preferences/com.google.android.*
# Deletes the Android Emulator's plist file
rm -Rf ~/Library/Preferences/com.android.*
# Deletes mainly plugins (or at least according to what mine (Edric) contains)
rm -Rf ~/Library/Application\ Support/AndroidStudio*
# Deletes all logs that Android Studio outputs
rm -Rf ~/Library/Logs/AndroidStudio*
# Deletes Android Studio's caches
rm -Rf ~/Library/Caches/AndroidStudio*
# Deletes older versions of Android Studio
rm -Rf ~/.AndroidStudio*
Run Code Online (Sandbox Code Playgroud)
如果您想删除所有项目:
rm -Rf ~/AndroidStudioProjects
Run Code Online (Sandbox Code Playgroud)
删除与gradle相关的文件(缓存和包装器)
rm -Rf ~/.gradle
Run Code Online (Sandbox Code Playgroud)
使用以下命令删除所有Android虚拟设备(AVD)和密钥库.
注意:此文件夹也被其他Android IDE使用,因此如果您仍在使用其他IDE,则可能不想删除此文件夹)
rm -Rf ~/.android
Run Code Online (Sandbox Code Playgroud)
删除Android SDK工具
rm -Rf ~/Library/Android*
Run Code Online (Sandbox Code Playgroud)
仿真器控制台验证令牌
rm -Rf ~/.emulator_console_auth_token
Run Code Online (Sandbox Code Playgroud)
感谢那些对此答案进行评论/改进的人!
rm
区分大小写为1(与大多数其他命令一样),这意味着f
标志必须为小写.但是,r
旗帜也可以大写.rm
可以组合在一起或分开.它们不必合并.r
标志表明该rm
命令应该 -
一个ttempt删除根植于每个文件参数的文件层次结构.- 联机帮助页上的描述部分
rm
(有关man rm
详细信息,请参阅参考资料)
f
标志表明该rm
命令应该 -
一个ttempt删除文件而不提示进行确认,不管该文件的权限.- 联机帮助页上的描述部分
rm
(有关man rm
详细信息,请参阅参考资料)
小智 17
在终端中运行以下命令:
rm -Rf /Applications/Android\ Studio.app
rm -Rf ~/Library/Preferences/AndroidStudio*
rm -Rf ~/Library/Preferences/com.google.android.*
rm -Rf ~/Library/Preferences/com.android.*
rm -Rf ~/Library/Application\ Support/AndroidStudio*
rm -Rf ~/Library/Logs/AndroidStudio*
rm -Rf ~/Library/Caches/AndroidStudio*
rm -Rf ~/.AndroidStudio*
rm -Rf ~/.gradle
rm -Rf ~/.android
rm -Rf ~/Library/Android*
rm -Rf /usr/local/var/lib/android-sdk/
Run Code Online (Sandbox Code Playgroud)
要删除所有项目:
rm -Rf ~/AndroidStudioProjects
Run Code Online (Sandbox Code Playgroud)
end*_*421 17
对于在 MacOS 10.15.1 或更高版本上使用 Android Studio 4.0 或更高版本的人。使用命令行打击:
# Deletes the Android Studio application
# Note that this may be different depending on what you named the application as, or whether you downloaded the preview version
rm -Rf /Applications/Android\ Studio.app
# Delete All Android Studio related preferences
# The asterisk here should target all folders/files beginning with the string before it
rm -Rf ~/Library/Preferences/Google/AndroidStudio*
# Deletes the Android Studio's plist file
rm -Rf ~/Library/Preferences/com.google.android.*
# Deletes the Android Emulator's plist file
rm -Rf ~/Library/Preferences/com.android.*
# Deletes mainly plugins (or at least according to what mine (Edric) contains)
rm -Rf ~/Library/Application\ Support/Google/AndroidStudio*
# Deletes all logs that Android Studio outputs
rm -Rf ~/Library/Logs/Google/AndroidStudio*
# Deletes Android Studio's caches
rm -Rf ~/Library/Caches/Google/AndroidStudio*
# Deletes older versions of Android Studio
rm -Rf ~/.AndroidStudio*
Run Code Online (Sandbox Code Playgroud)
区别
图书馆/首选项/谷歌/AndroidStudio*
图书馆/日志/谷歌/AndroidStudio*
图书馆/缓存/谷歌/AndroidStudio*
Ank*_*nha 11
我的Macbook Pro上也遇到了同样的问题.我采取了这些非常简单的步骤并重新安装了Android Studio.
**链接包含图像,看看是否面临任何问题.
这些非常简单的步骤可以解决您的问题.
Simon单独列出的一些文件也可以使用类似下面的命令找到,但是有一些关于彻底性的额外保证,并且没有将rm -rf与通配符一起使用的鲁莽性:
find ~ \
-path ~/Library/Caches/Metadata/Safari -prune -o \
-iname \*android\*studio\* -print -prune
Run Code Online (Sandbox Code Playgroud)
另外不要忘记现在与应用程序分开的SDK和〜/ .gradle /(参见vijay的回答).
如果您不在任何其他地方使用gradle,您也可以删除gradle文件:
rm -Rfv ~/.gradle/
Run Code Online (Sandbox Code Playgroud)
因为.gradle文件夹包含不再需要的缓存工件.
归档时间: |
|
查看次数: |
243441 次 |
最近记录: |