Ignore all files except *.pdf

Hi, Can someone please help me to set up a basic ignore pattern

I simply want to ignore all files accept files ending with .pdf

Thanks

You can not easily do this for a whole directory tree, sorry.

To do it in a single directory, you can:

!somedirectory/*.pdf
somedirectory/*

Hi, here is mine. Be carefull of difference between PDF and pdf, Pdf…

// Allow specific file BookList20180102.TxT tested is OK
(?i)!BookList2018????.txt
//(?i)!/English/user/folder1/*.pdf
//(?i)/English/user/folder1/*
//(?i)!/English/user/folder1
//(?i)!/English/user/folder0
//(?i)/English/user/*
//(?i)!/English/user
(?i)!/English/*.pdf
(?i)/English/*
(?i)!/English
(?i)!/French/*.pdf
(?i)/French/*
(?i)!/French
(?i)!/Dutch/*.pdf
(?i)/Dutch/*
(?i)!/Dutch
(?i)!/Deutsch/*.pdf
(?i)/Deutsch/*
(?i)!/Deutsch
(?i)!/Other/*.pdf
(?i)/Other/*
(?i)!/Other
(?i)!*.pdf
*

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.