CLI: How to browse contents in a jar file? [duplicate]

You could use the command unzip -l [filename] to list the contents of the jar archive file.

First, you might need to install unzip: sudo apt install unzip

Example of unzip usage on the file gettext.jar:

username@ubuntu-server:~$ unzip -l /usr/share/java/gettext.jar
Archive:  /usr/share/java/gettext.jar
  Length      Date    Time    Name
---------  ---------- -----   ----
        0  2019-03-06 23:31   META-INF/
       66  2019-03-06 23:31   META-INF/MANIFEST.MF
     5657  2019-03-06 23:31   gnu/gettext/DumpResource.class
      699  2019-03-06 23:31   gnu/gettext/GetURL$1.class
     1579  2019-03-06 23:31   gnu/gettext/GetURL.class
---------                     -------
     8001                     5 files

Alternatively, you could use the Java JDK's jar command to view the contents of a jar file: jar -tf [filename]. (See https://stackoverflow.com/questions/320510/viewing-contents-of-a-jar-file)