Keyboard shortcut lovers can add a shortcut for running gradle sync manually by going to File -> Settings -> Keymap -> Plugins -> Android Support -> Sync Project with gradle files (Right click on it to add keyboard shortcut) -> Apply -> OK and you are done.
选择任何一个方便的键作为你的gradle sync的快捷键,并且不与其他快捷键冲突,(我选择了Shift + 5作为我的gradle sync键),所以接下来当你想手动运行gradle sync时,只要按这个键盘快捷键。
PS D:\work\wctposdemo> .\gradlew.bat clean
FAILURE: Build failed with an exception.
* Where:
Build file 'D:\work\wctposdemo\app\build.gradle'
* What went wrong:
Could not compile build file 'D:\work\wctposdemo\app\build.gradle'.
> startup failed:
General error during semantic analysis: Unsupported class file major version 57
I've the same error-message some minutes ago: > Unsupported class file major version 57 The issue for me was, that gradle doesn't work with current openJdk13 on Linux (I use Manjaro... an Arch-Like Linux). So to fix this, I've done this: I've checked which Java version I've installed at my pc, and choosed the version 8: sudo archlinux-java stauts sudo archlinux-java set java-8-openjdk Maybe this helping you out, even If your system seems to be windows. So try another SDK Version. Maybe it also solve your issue.