sponsored links

Collapse

Announcement

Collapse
No announcement yet.

Hot to Zip files inside an IFS folder

Collapse
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • Hot to Zip files inside an IFS folder

    Hi all

    I would need to zip all files inside ans Ifs folder and get one zip so that
    when extract it , i see only the files and not also the folder that contains
    my files
    Example: if i run "jar -cf /myf/g/wrk/my.zip /myf/g/wrk/*

    Inside wrk, i have

    File1
    File2

    When i estract the zipped file , i see before MYF and META-INF folder, if i
    click on myf i see G folder , and then i see WRK folder and for the last i
    see my files .. i would see directcly file1 and file2

    How can i do it ?

    Thanks





  • #2
    The reason that is happening is because you are specifying the entire path to add to the archive. If you CD to the directory first (CD /myf/g/wrk) and then issue the java command (jar -cf *), that will add the files without the directory structure.
    BTW, do you need to include the manifest? You could use jar -cfM so the manifest is no included.

    Comment

    sponsored links

    Collapse

    Working...
    X