For Apache Maven I have found a izpack plugin and a NSIS plugin (for Win32).
Are there other Maven plugins available which allow to create software installers for Java applications, or are these the most popular and 'mature' tools?
It does not have to include a pretty GUI, even a simple command line installer could be helpful enough. Support for file permissions (executable flag for shell scripts) would be nice to have so that users on Linux don't have to set this flag manually.
If GUI is not an issue, you may want to look at maven assembly plugin
Related
So I installed Apache Netbeans. Installed some of the plugins and instead of just seeing the Java folder in the categories when I want to create a new Project, I see this:
What is Gradle, Ant, and Maven? I am not familiar with Java and wanted to study the language, but I have no idea of what these are.
I keep seeing that I need to have certain plug ins installed and active.
Here they are.
Ant, Maven and Gradle are Java build tools. You don't really need to know the exact differences though.
Java with Ant
The "Java with Ant" option uses NetBeans' own internal project format (based on Ant). In older NetBeans versions this category was simply called "Java"
If you don't need to share your project with non-NetBeans users, use that option.
You will have to manage dependent libraries yourself (download, add them to the project) unless you are only using libraries and frameworks that are bundled with NetBeans. The turnaround times (the time it takes between you hit "Run" and the application actually starts) are the shortest with this option, as Maven and Gradle add substantial overhead to that.
Java with Maven
Maven is a standardized dependency and build management tool. A project defined with Maven can be used by everybody else as it automatically manages (and downloads) any dependency.
Use that option if you know you need to share your project with other people (e.g. hand it in your school or university).
Java with Gradle
Gradle is yet another build tool, which also manages dependencies for your and has more flexibility than Maven. However the build scripts are less standardized than in Maven. But that is also a good option if you know that you need to share your project with other people.
Unless you are using NetBeans 11.1 (which is currently in Beta) I would not use this option as Gradle support in older versions is not as good as Ant or Maven support.
You might want to go through the tutorials on the NetBeans homepage:
http://netbeans.apache.org/help/index.html
do you know a highly configurable maven plugin for creating MS Windows installers?
The artifacts of my project are processed through a Maven Launch4j plugin, therefore I already have an executable (*.exe) file, but I need to install the other dependencies and resources as well: *.dll, images, the executable and so on. I also like to install the jre (if required), set some environment variables and so on.
Can you recomend a plugin?
Best regards.
I think you are looking for the nsis-maven-plugin
The nsis-maven-plugin enables Maven integration with the NSIS tools so
that Windows and Linux build machines can create Windows Installer
EXEs.
Sourceforge.net has a filter for Java projects, but I'm looking for a way to narrow them down to ones that are meant to be built in Eclipse.
Edit I'm using Eclipse Metrics and Omondo plug-ins to analyze open-source Java projects. I'm looking for a quick way to find Eclipse open-source projects that can build quickly in Eclipse, so I can use these tools on them for analysis.
I presume that a project that is "meant to be built in Eclipse" is one that has an Eclipse .project file and other stuff checked into the source repository.
First, checking in Eclipse-specific stuff can a bad idea because it is easy to include stuff (e.g. build pathnames, preferences) that are specific to the developer. You then get problems if there are multiple committers ...
Second, this should unnecessary. Most of the stuff in the .project file can be generated when you import the project. If that's not possible, then the project should provide instructions for setting up the buildpath etcetera. (Note that if the project uses Maven, this is all taken care of for you.)
Third, any project worth its salt will include build scripts of some kind that allow you to rebuild without using any IDE.
Finally, any project that only supports building using Eclipse is excluding the significant subset of developers who use other Java IDEs.
Note that neither Maven or Ant builds require Eclipse to work. Both of these build tools can run from the command line, or from other Java IDEs.
OK. I understand your requirements now. You don't actually care what the project is ... or that it is sound / worthwhile project. You just need it for testing your plugin. (I won't comment on the "validity" of doing this. It depends on what you hope to achieve.)
I suggest that you install the m2eclipse plugin and look for projects with a "pom.xml" file. The projects don't need to be eclipse specific. The m2eclipse plugin automatically creates the ".project", ".classpath" and so on based on the "pom.xml" file. There's no need to exclude any particular version control system, because the m2eclipse plugin can import Maven projects that you checked out from the command line.
does appcfg.sh compile servlets or olny deploy compiled project ? If it doesn't how can I compile whole project in the command line?
It's highly recommended to use an IDE to build Java web projects, especially GAE projects:
Eclipse with Google Plugin (free)
IDEA with GAE plugin (commercial)
If you dislike IDEs, then at least use maven with gae plugin.
You can do this by specifying the right dependencies in your master BUILD file:
The binary should depend on everything it needs to run.
You can create another target for deployment. That target should depend on the binary, and also on everything else needed to deploy it.
Google AppEngine supports Apache Ant for command-line builds. AppEngine Java SDK also includes Ant macros to run appcfg.sh tasks from Ant.
Lets say you created a little Java Desktop app with a jar and some dependencies and possibly a license text file. I know there are plenty of Ant tasks that can generate installers, executables and proper Mac OS X applications including packaging them as ".dmg" files. Examples would be JarBundler and Launch4j
Does similar things exist for Maven?
Thanks
OSX appbundle plugin
I also think launch4j has a maven plugin
To generate a windows executable in a maven build, you can use the launch4j-maven-plugin. I just answered a related question, Trying to integrate Launch4j in a Maven project using Alakai plugin, showing how to accomplish that. It's very easy, more than JSmooth, which always had a maven plugin.
Hope it helps!