How to create single jar file from github tree?

Hristo Hristov picture Hristo Hristov · Nov 28, 2011 · Viewed 13.1k times · Source

For example, the Java API for pubnub is at https://github.com/pubnub/pubnub-api/tree/master/java

I want to create a single jar file from all the java files in the subfolders.

What is the most straight-forward way to do that?

Answer

gigadot picture gigadot · Nov 28, 2011

Since Pubnub provided no build file, you need to create a new java project in your favourite IDE and then import the downloaded java code. Next, you can compile and package the project into jar file using the IDE.

Note: it is also possible to create a build script yourself but it is more complicated.