Windows 7 Forums
Welcome to Windows 7 Forums. Our forum is dedicated to helping you find support and solutions for any problems regarding your Windows 7 PC be it Dell, HP, Acer, Asus or a custom build. We also provide an extensive Windows 7 tutorial section that covers a wide range of tips and tricks.

Windows 7: Setting WinRAR to exclude specified files from being extracted

22 Apr 2011   #1

Windows 7 Ultimate, 64-bit
Setting WinRAR to exclude specified files from being extracted

I would like to ask how to set WinRAR to exclude files with the exact filenames: 'thumbs.db' or '.DS_Store' (without the quotes, ignore case) from being extracted from an archive.

Ex. Files with these filenames should not be extracted:

while files with these filenames should be extracted:

Abcd thumbs.db.txt
In 'Settings->Security->Prohibited file types->File types to exclude from extracting', if I just type in 'thumbs.db .DS_Store' (without the quotes) in the field, will it work the way I described?

Also, does anyone know if WinRAR has a syntax guide for the Prohibited file types list in case I'd like to add more filenames or be flexible with the rules I need?

The reason for this question, is I'd like to not extract unnecessary files from ZIP, RAR or 7z archives in Windows 7 - files like Windows 2000/XP's Thumbs.db file (Thumbnail cache) and Mac OS X' .DS_Store file (Desktop Services Store), while not being too strict and also not extracting files which just contain 'Thumbs.db' or '.DS_Store' in its filename.

My System SpecsSystem Spec

22 Apr 2011   #2

Windows 8.1 ; Windows 7 x86 (Dec2008-Jan2013)

Yes, it should work.

Here is a piece from WinRar 4.0 Help file
Files to exclude
File masks and file names to exclude from the archiving operation. Wildcards are supported both in path and name parts of masks. If you need to specify several masks, separate them by spaces. If mask contains spaces, enclose it in quotes. For example, you may enter:

c:\temp\info.txt *.bak *.tmp *\temp\

to skip c:\temp\info.txt file, all .bak and .tmp files, all temp folders and all files in temp folders. You may enter file names manually or use "Append" button to browse for file to exclude.

Detailed information about exclusion masks syntax is provided in description of switch -x. This switch uses the same format of exclusion masks as "Files to exclude" field.
My System SpecsSystem Spec
23 May 2011   #3

Windows 7 Ultimate, 64-bit

Quote   Quote: Originally Posted by Neutron16 View Post
Yes, it should work.

Here is a piece from WinRar 4.0 Help file
Thanks for that!

I have an issue with this not working on certain types of ZIP/RAR/7z files, though.

I've entered `thumbs.db .DS_Store` in the prohibited file list. I have encountered a ZIP file that has a `.DS_Store` file in a 2nd level directory. ( > Parent Directory > Directory where .DS_Store is stored). When I extract this ZIP file, WinRAR still extracts the `.DS_Store` file. Changing `.DS_Store` to `*.DS_Store` fixes this. The same issue happens with thumbs.db files.

So now, my prohibited files list is now `*thumbs.db *.DS_Store` (without the quotes). Know why the previous entry didn't work in this case? Also, is there a better entry in the Prohibited files list that will work to exclude only thumbs.db and .DS_Store for all directory levels in a ZIP/RAR/7z file?
My System SpecsSystem Spec


 Setting WinRAR to exclude specified files from being extracted

Thread Tools

Similar help and support threads for2: Setting WinRAR to exclude specified files from being extracted
Thread Forum
Solved Delay Showing Extracted Files General Discussion
Solved show hidden files folders (exclude files) General Discussion
Are these files safe to exclude from a backup? Backup and Restore
Zip - Extracted Files Window - Enable or Disable Tutorials
Extracted files on desktop General Discussion
Need Help with Extracted Game Files Gaming

Our Sites

Site Links

About Us

Find Us

Windows 7 Forums is an independent web site and has not been authorized, sponsored, or otherwise approved by Microsoft Corporation. "Windows 7" and related materials are trademarks of Microsoft Corp.

Designer Media Ltd

All times are GMT -5. The time now is 07:07 PM.
Twitter Facebook Google+

Windows 7 Forums

Seven Forums Android App Seven Forums IOS App

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33