1.gogradle顯示java.nio.file.FileSystemException: 客戶端沒有所需的特權(quán) (win10)
解決方案參考:?https://github.com/gogradle/gogradle/issues/294
2.下載golang.org/x/tools等失敗
使用gogradle的鏡像倉庫功能
repositories {
? ? golang {
? ? ? ? root ~/golang\.org\/[\w-]+\/[\w-]+/
? ? ? ? url { path->
? ? ? ? ? ? def split = path.split('/')
? ? ? ? ? "https://github.com/golang/${split[2]}"
? ? ? ? }
? ? }
}
3.Gogradle插件無法下載
由于防火墻等限制,訪問官方插件倉庫https://plugins.gradle.org存在可能存在問題。
解決辦法一:
移步Gogradle Release下載最新版本的jar包。
將構(gòu)建腳本改為
build.gradle:
buildscript {
? ? dependencies {
? ? ? ? classpath files('<path to downloaded jar>')? ? ?//這里是gogradle在本地存放的絕對(duì)路徑,例如
? ? }
}
apply plugin: 'com.github.blindpirate.gogradle'
解決辦法二:
搭建私有的maven鏡像倉