I have recently developed an application and created the jar file. One of my classes creates an output directory, populating it with files from its resource. My code is something like this: Unfortunately this doesn’t work. I tried the following without luck: Using Streams to solve similar stuff on other classes but it doesn’t work with dirs. Code was similar
Tag: jar
Find a class somewhere inside dozens of JAR files?
How would you find a particular class name inside lots of jar files? (Looking for the actual class name, not the classes that reference it.) Answer Eclipse can do it, just create a (temporary) project and put your libraries on the projects classpath. Then you can easily find the classes. Another tool, that comes to my mind, is Java Decompiler.
Modifying a file inside a jar
I would like to modify a file inside my jar. Is it possible to do this without extracting and re jarring, from within my application? File i want to modify are configuration files, mostly xml based. The reason i am interested in not un jarring is that the application is wrapped with launch4j if i unjar it i can’t create
How to build jars from IntelliJ properly?
I have a project that contains a single module, and some dependencies. I’d like to create a jar, in a separate directory, that contains the compiled module. In addition, I’d like to have the dependencies present beside my module. No matter how I twist IntelliJ’s “build jar” process, the output of my module appears empty (besides a META-INF file). Answer
“Invalid signature file” when attempting to run a .jar
My java program is packaged in a jar file and makes use of an external jar library, bouncy castle. My code compiles fine, but running the jar leads to the following error: Exception in thread “main” java.lang.SecurityException: Invalid signature file digest for Manifest main attributes I’ve googled for over an hour searching for an explanation and found very little of
How do I access a config file inside the jar?
I’m using FlatPack to parse and load data from flat files. This requires loading a config file that stores mappings of the columns of the flat file. I have a constant to define the location of the mapping file: I have a parse(File dataFile) method that actually does the parsing: When I jar up everything and run it as a