I need main() method generation

Answered

I created new project, new class (Main.java) and must write "

public static void main(String[] args){}

"

It will be good if will possible generation main method by IDE.

6 comments
Comment actions Permalink

This does not work. IntelliJ 2019.3. I get something like Upsert instead

0
Comment actions Permalink

Please share the screenshot of the issue. What file type do you use? Note that for Java you can now also type main instead of psvm.

0
Comment actions Permalink

I was in JShell, so .snippet file?

0
Comment actions Permalink

Live templates do not work in JShell. Normally you don't even have a class there and you just run any statement, so you don't need a class or a main method in JShell.

0
Comment actions Permalink

Ah, good to know, thanks!

0

Please sign in to leave a comment.