Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Build Java application from .net perspective

Tags:

java

I have been a .net developer for some time now and recently started using java and eclipse.

Up until now i've been executing a little test app by right-clicking in Eclipse and "Run As-> Java Application".

Everything works fine until i go to try set this up so i can deploy it to another machine.

In .Net, it's easy. All the references will be automatically included in the output folders, so all one has to do is take the entire package and move it to another machine and run from there.

Does this happen for java?

I've been playing around with javac.exe and it's needing quite a bit of information to get this to build. I'm really just trying to find the equivalent of building the project in debug mode so i can avoid setting up ant configurations.

Thanks for the ideas

like image 373
Beta033 Avatar asked Jun 11 '26 15:06

Beta033


1 Answers

"Does this happen for java?" " - Yes you need to build the project file, then export it as a "Runnable jar".

You will find your .jar file in a directory specified by your export command. GUIs nowadays associate .jar files with the command java -jar +Jar file. which executes the .jar file.

Why debug mode?

like image 172
Captain Giraffe Avatar answered Jun 14 '26 03:06

Captain Giraffe