Flutter運行錯誤:Gradle does not have execution permission

[!] Gradle does not have execution permission.
    You should change the ownership of the project directory to your user, or move the project to a directory with execute permissions.
Finished with error: Gradle task assembleDebug failed with exit code 1

 

我當時是把Win裏面的項目轉到Mac裏面,剛開始由於路徑不對,Flutter跟SDK路徑要換成Mac上的路徑。

然後我Put get一下,項目沒有報錯,但是我啓動IOS模擬器就報上面那個錯誤,我以爲是模擬器的原因,我用了Android真機,發現同樣的問題。

搜索到一個答案,我沒看懂。

https://autoref.cn/2019/12/26/314/ 這是那個答案的連接。

問羣裏的人,別人告訴我,可能是你gradle的原因,我就把項目裏,Android的項目單獨運行一下,,把gradle生成一下,能跑起來,然後我重新Flutter運行,就好了。ios模擬器也可以用了

發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章