🔔 WARNING !!! 7-Zip trims spaces in the @ file list !!! Request to add file list %UFQ %WFQ with quotes !!!!!!!!!!!!!!!!

English support forum

Moderators: Hacker, petermad, Stefan2, white

Post Reply
PiotrMPPL
Junior Member
Junior Member
Posts: 60
Joined: 2018-10-26, 07:04 UTC

🔔 WARNING !!! 7-Zip trims spaces in the @ file list !!! Request to add file list %UFQ %WFQ with quotes !!!!!!!!!!!!!!!!

Post by *PiotrMPPL »

Hi

WARNING !!! 7-Zip trims spaces in the @ file list.
Wildcards or filenames with spaces must be quoted!!!

You may lose files when compressing data with 7-Zip width file list %UF %WF!!!

ex @ list of files %UF %WF

Code: Select all

 Test\
 Image.jpg
You should be like that:

Code: Select all

" Test\"
" Image.jpg"
If you use 7-Zip as your ZIP packer, you will lose files whose names start with a space!!!!

Request to add file list %UFQ %WFQ with quotes
Last edited by PiotrMPPL on 2023-07-18, 05:40 UTC, edited 6 times in total.
Fla$her
Power Member
Power Member
Posts: 2998
Joined: 2020-01-18, 04:03 UTC

Re: 🔔 WARNING !!! 7-Zip trims spaces in the @ file list !!! You may lose files when compressing data with 7-Zip !!!

Post by *Fla$her »

Why not turn to Igor Pavlov with this?
Although I don't see any problems on version 23.01. Which one do you have?
Last edited by Fla$her on 2023-07-16, 16:16 UTC, edited 1 time in total.
Overquoting is evil! 👎
User avatar
ghisler(Author)
Site Admin
Site Admin
Posts: 50532
Joined: 2003-02-04, 09:46 UTC
Location: Switzerland
Contact:

Re: 🔔 WARNING !!! 7-Zip trims spaces in the @ file list !!! You may lose files when compressing data with 7-Zip !!!

Post by *ghisler(Author) »

Just to clarify, when you configure 7zip as the packer in menu Configuration - Options - ZIP packer, then Total Commander automatically adds quotes around names with spaces. Files and directories with spaces at the start will be packed correctly.
Author of Total Commander
https://www.ghisler.com
PiotrMPPL
Junior Member
Junior Member
Posts: 60
Joined: 2018-10-26, 07:04 UTC

Re: 🔔 WARNING !!! 7-Zip trims spaces in the @ file list !!! You may lose files when compressing data with 7-Zip !!!

Post by *PiotrMPPL »

ghisler(Author) wrote: 2023-07-16, 07:03 UTC Just to clarify, when you configure 7zip as the packer in menu Configuration - Options - ZIP packer, then Total Commander automatically adds quotes around names with spaces. Files and directories with spaces at the start will be packed correctly.
The error is in the file lists %UL %UF %WL %WF generated by TC!!!!
There are no quotation marks in these lists!!!
User avatar
Horst.Epp
Power Member
Power Member
Posts: 6973
Joined: 2003-02-06, 17:36 UTC
Location: Germany

Re: 🔔 WARNING !!! 7-Zip trims spaces in the @ file list !!! You may lose files when compressing data with 7-Zip !!!

Post by *Horst.Epp »

2PiotrMPPL
I have configured the Zip Packer like this:
"C:\Program Files\7-Zip\7zg.exe" -mcu=on
I works with all sort of files and dirs containing spaces and spaces on the beginning of names.

Using the Total7zip plugin there is also no problems with such names.

Finally, the following button creates archives with correct handling of spaces on all places.
It contains %UL as you can see.

Code: Select all

TOTALCMD#BAR#DATA
"C:\Program Files\7-Zip\7z.exe"
a %T"%B"_%|$DATE:YMD_hm| @%UL -aoa -mmt -mx9 -ssw -stl -ssp -y
C:\Program Files\7-Zip\7zFM.exe
Pack selected

0
-1
Windows 11 Home, Version 24H2 (OS Build 26100.4061)
TC 11.55 RC2 x64 / x86
Everything 1.5.0.1391a (x64), Everything Toolbar 1.5.2.0, Listary Pro 6.3.2.88
QAP 11.6.4.4 x64
Post Reply