Announcement

Collapse
No announcement yet.

How to unzip files with Windows-style path (with \ separator) ?

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    How to unzip files with Windows-style path (with \ separator) ?

    Hi,

    Often, I have to extract files from archives files created by Windows users.
    Unfortunately, most have pathname including \ separator instead of /.

    Today, I'm using a Windows XP system to extract files, remove directory path and send files back to Kubuntu.

    Is there anything more convenient ?
    I couldn't find any option allowing me to tell 7z or unzip to treat \ as /.
    Did I miss something ?

    Regards

    #2
    Re: How to unzip files with Windows-style path (with \ separator) ?

    I've been able to open Windows Zips with folders and stuff in them with Ark just fine. Have you tried Ark?

    Comment


      #3
      Re: How to unzip files with Windows-style path (with \ separator) ?

      I just went to my windows drive to a .zip file right clicked and selected "extract to" and it worked perfectly.

      eriefisher
      ~$sudo make me a sandwich

      Comment


        #4
        Re: How to unzip files with Windows-style path (with \ separator) ?

        I should have told this in the first place :

        I'm using Ark 2.6.4 with Kubuntu 7.04
        I don't how Windows zip files are exactly produced.

        Using 7zip on Windows XP SP2, I created 3 files. Then I got :
        - I could open 2 files : 1 inside top level directory and the other inside a subdirectory
        - when I added another file with non-ASCII letters, I had : "filename not matched"

        Using the very same Ark with zip files containing files with names like FOO\BAR.TXT, I have this "filename not matched".
        I'm not able yet with 7zip or QuickZip to produce myself archives with FOO\BAR.TXT.

        I'll try again later ...

        Comment


          #5
          Re: How to unzip files with Windows-style path (with \ separator) ?

          Directory structure is preserved in Linux just as it would be in Windows (assuming that option is left on).

          Please explain, from the beginning, what exactly you're trying to do.
          For external use only.

          Comment


            #6
            Re: How to unzip files with Windows-style path (with \ separator) ?

            Let say you receive by email the file toto.zip
            You have no clue about the way it was created.

            You open toto.zip with Ark and the files :
            FOO\BAR1.TXT
            FOO\BAR2.TXT

            You single click on FOO\BAR1.TXT to open it : it fails with message "filename not matched".

            I thought error message poped up because you have a \ separator but I have no way to prove it as I'm unable to produce any archive file with files with names such as FOO\BAR1.TXT

            Have you ever opened (with Ark) any zip archive including FOO\BAR1.TXT files ?

            Regards

            Comment


              #7
              Re: How to unzip files with Windows-style path (with \ separator) ?

              Ah... I see.
              I think the problem is with Ark (or rather, with the command it's passing to unzip). My guess is the backslash isn't being escaped, so it can't find the file (i.e. it's being sent "foo\bar", when it should be being sent "foo\\bar").

              I guess there's no solution for what you're trying to do (at least not right now). I suggest extracting the files, then editing them.

              I'm also going to submit a bug report.

              EDIT: bug report here.
              For external use only.

              Comment


                #8
                Re: How to unzip files with Windows-style path (with \ separator) ?

                Thanks for filing this bug.

                As I'm new to Ark, I thought opening archives files with such foo\bar filenames was so common that I did have miss an option somewhere.

                I think another bug report should filed with files with non-ASCII names.
                I'll check if this have not be done before, before doing anything.

                Regards

                Comment


                  #9
                  Re: How to unzip files with Windows-style path (with \ separator) ?

                  Non-ASCII filenames are probably supported. Most things use UTF-8.
                  For external use only.

                  Comment


                    #10
                    Re: How to unzip files with Windows-style path (with \ separator) ?

                    To help me to test, how can I, using Kubuntu tools, create a zip archive that includes foo\bar.txt files in the first place ?

                    As I told before, I don't know how those foo\bar.txt archives are created.
                    Guessing from \ separator presence, I suppose those files come from Windows systems but I have no certainty.

                    How should I proceed to create my own sample ?
                    I've got plenty of examples but I can't send them to anyone, for privacy.

                    Comment


                      #11
                      Re: How to unzip files with Windows-style path (with \ separator) ?

                      Just create a file named foo\bar.txt, then compress it as a ZIP archive with Ark.

                      You can probably get an example here, assuming my server's running.
                      For external use only.

                      Comment

                      Working...
                      X