I want to use rsync
to upload files to a server.
I'll default to exclude all.
Then I'll include the ones I need.
While doing so I realised sometimes I need to exclude a file within a folder but include the other folders.
I want to use a pattern to do so but I'm not sure what the pattern format should be in order to say "I want to include all subfolders except the one named demo
"
--include="models/" --include="models/!demo" --exclude="*"
I definetely don't want to be typing every single folder to include within a folder or every folder to exclude from my project.
I would like to exclude all by default. Then include based on pattern so I won't have to be forced to include the whole folder.
Any idea?