Compilation on save
Answered
Automatic compilation feature looks inconvenient. It either tries to build my stuff almost immediately (and causes auto saving as a side effect), or is not working automatically at all. I feel that auto saving is a scary thing to do (several Ctrl-Z, type something, so cannot Ctry-Y, and than auto-save completes the job).
Is it possible to somehow emulate what Eclipse or Visual Studio do: no auto save, Ctrl-S (or some other shortcut) saves single file instead of all files, and automatic compilation is triggered by the save event, not by typing?
Please sign in to leave a comment.
Assign Ctrl+S to Build | Make, however it will save all the files before Make anyway. There is no way to disable it.
Thank you, it feels much better now.
Hi, I´m new to intelliJ :)
When I assign Ctrl+S to Rebuild (Default assign of Rebuild is STRG+Shift+F9) nothing happens.
Is it somehow possible in a Java Projekt to rebuild on save?
Does the Build | Rebuild menu work for you? Can you share a sample project where it doesn't work? Any errors in the logs?
Hi Serge, I shared my test project on github https://github.com/Mattes1000/Test.git . I hope I did it right.
What do you mean by “Build | Rebuild menu”? Where do I find it?
Your GitHub link doesn't work.
:) Sorry. Now the repo is public.
The “Rebuild Project” builds - as the name says - the whole project. But yes: This refreshes my classes.
I want to compile and refresh a single file as the shortcut “STRG+Shift+F9” does
Recompile action works fine after redefining the shortcut:
I'm pressing Ctrl+S at the end, and the Recompile action is invoked for the current file.
That did the trick! Thank you very much for this newbie support.