Is there a quick and easy way to associate winzip (or windows built in extractor) with jar files? [closed]

StackOverflow https://stackoverflow.com/questions/16022723

  •  04-04-2022
  •  | 
  •  

Question

A couple of libraries I'm working with provide "sources", but the sources are actually a series of nested jar files and it's a bit of a pain finding individual files I need to review.

As it stands, I'm renaming the .jar to .zip and opening it up in winzip. I don't want to extract everything - just locate the one file I want and review it.

I can right-click and choose "open with winzip" on any zip file, or "extract to here" to extract an entire archive to the current directory.

I would like those options to appear for jar files as well, so that I don't have to rename them.

I would still like the primary "open" for jar files to remain the same.

I am working with Windows 7.

Install location is D:\Program Files\WinZip

Was it helpful?

Solution

Right-click and choose Open With...->Choose Default Program... to open the Open With dialog box. Choose Winzip from the list (or Browse to it if it isn't listed.) Be sure to select "Always use the selected program to open this kind of file" before clicking ok. This will change your default program settings!

Alternatively, you could create a shorcut to Winzip on your desktop and drag-and-drop files onto it to open them.

You could also add another entry to the context menu by editing the registry. You can copy the settings from one of the working file types and adapt it for .jar files pretty easily. The following .reg file should do the trick if you're running 64-bit Windows.

Windows Registry Editor Version 5.00

[HKEY_CLASSES_ROOT\jarfile\shell\winzip]
@="Open with WinZip"

[HKEY_CLASSES_ROOT\jarfile\shell\winzip\command]
@="\"C:\\Program Files\\WinZip\\WINZIP64.EXE\" \"%1\""

OTHER TIPS

I would recommend installing WinRAR. It adds options when right-clicking a file in Windows. enter image description here.

As you can see, the jar launcher is the default program, but you now have the option to directly extract files. Also, I doubt you need to rename it to .zip to open it with WinZip. In binary, it has the correct zip format.

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top