Specific file types for sync and ignore all others?

I have been reading on the .stignore and a couple of entries on #include (not sure if that is implemented?) but I think I am making this more complicated than it need be. I have four file types - .pdf, .jpg, .bmp and .ps. I want to ignore everything else and just transfer these. Is there a way to specify these for transfer and ignore everything else?

Thanks in advance!

Docs on Ignoring Files. #include is indeed implemented, and works.

To achieve what you want, use this in .stignore. If you’re using a case-sensitive filesystem you may want to use the case ignore prefix e.g. (?!)!.bmp.

!.bmp
!.jpg
!.pdf
!.ps
*

This means “don’t ignore bmp, jpg…ignore everything”. The first matching pattern is applied, hence the order is key.

1 Like

Thank you! I thought I was making this way too complicated!

1 Like

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