我有一个 Android 项目,它在 Android Studio 上使用带有 Fabric 插件的 Crashlytics,为文件设置代理:
studio64.exe.vmoptions :
-Dhttps.proxyPort=8080
-Dhttps.proxyHost=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
-Dhttps.proxyUser=xxxxx
-Dhttps.proxyPassword=xxxxxxxx
gradle.properties:
systemProp.http.proxyPassword=xxxxx
systemProp.http.proxyHost=proxy-xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
systemProp.http.proxyUser=xxxxxxxx
systemProp.http.proxyPort=8080
systemProp.https.proxyPassword=xxxxx
systemProp.https.proxyHost=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx
systemProp.https.proxyUser=xxxxxxxx
systemProp.https.proxyPort=8080
由于某些原因,我无法登录插件并显示“无法连接到网络”的消息
有人对此问题有任何想法或可能的解决方案吗?
最佳答案
导航到
Android Studio directory > bin
将以下行添加到 studio.exe.vmoptions
和 studio64.exe.vmoptions
-Dhttps.proxyHost=PROXY_ADDRESS
-Dhttps.proxyPort=PROXY_PORT
-Dhttps.proxyUser=USER_NAME_HERE
-Dhttps.proxyPassword=PASSWORD_HERE
对我来说,它与 Android studio 2 Beta 5 完美配合。
更新:
如果您的用户名或密码中有任何特殊字符,例如“Domain/Userid”,请确保将您的特殊字符替换为此处的 ASCII 编码引用 https://www.w3schools.com/tags/ref_urlencode.asp
关于具有代理设置的 Android Studio Gradle Fabric "Unable to connect to the network",我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/31879164/