Answer the question
In order to leave comments, you need to log in
How to check that there are no compilation errors?
Hello. I use sublime. I wrote my own build system, but it does not take into account that the program may have errors and runs the old version.
errors=$(javac -d debug App.java 2>&1)
if [$errors != ""]
then exit
Answer the question
In order to leave comments, you need to log in
Swears, they say "syntax error: unexpected end of file". Tell me what I'm doing wrong
if [$errors != ""]
then exit
fi
Just use Maven, Gradle or the like. This is not only a build system, these are tools for full project life cycle management: dependency autoloading, build, packaging, deployment, a bunch of plugins for different needs.
In the sublime for the build, specify the line "maven clean compile run:run" or "maven clean package run:run" , there are many options. Well, or use an IDE, for large projects (especially in java), the sublime is not suitable.
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question