![]() The linked tutorial describes that process. trying to download Biomes O Plenty, and recieved a zipped folder instead of a executable. If you want to create a runnable JAR, you can create a manifest file that has the main class and other options in it. Converting Mod Folders into Executable jar files. You can read an official tutorial on it here: Creating JAR Files. The JDK comes with a jar utility to create JAR files. ![]() Is there something wrong with: jar cf my-application.jar folder1 folder2 folder3 etc If you are using Java 7 and you know your users are too you can also use Files.walkFileTree() with a FileVisitor that adds entries to the JAR as it visits files. You could either build a list of files then just use code like in the above example, or you could recursively scan files and add them to the JAR as you go. ![]() ![]() Furthermore, each computer program handles file extensions in a different manner. There is an example at this link that contains code to create a JAR file given a File containing all the input files.Īs for creating the list of files given a starting input path, see Recursively list files in Java. File Extension conversion from JAR to BAT is the conversion of computer file extensions from Java Archive File to MS-DOS Batch File. Given that you want to create the JAR through code you can use JarOutputStream for that. ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |