Uploaded image for project: 'JDK'
  1. JDK
  2. JDK-8321618

jar command always extracts to current directory.

XMLWordPrintable

    • Icon: Enhancement Enhancement
    • Resolution: Duplicate
    • Icon: P4 P4
    • None
    • None
    • tools
    • None
    • jar

      The system jar command always extracts into the current directory.

      While this may be tolerable (albeit somewhat inconvenient) when executed from a shell or via `Process.exec` such that the current directory can be changed, it is not possible to control the output directory when the `jar` command is invoked via the `ToolProvider` SPI, as in
          var jarTool = ToolProvider.findFirst("jar");

      The workaround is that one has to exec the command in order to set the output directory.

            Unassigned Unassigned
            jjg Jonathan Gibbons
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: