When running a deployment there may be files that you don't want to upload to you server. For example, you may be running a local server that requires a different configuration file to your remote server.
- Firstly, you will need to navigate to the deployment you want to exclude files for, then click on the Excluded Files link within the settings drop down:
- Next click on the + icon to the right hand side of the page:
- Now enter the file path of the file you do not want to be deployed (if you wish to exclude an entire directory and its contents, just enter the path followed by ** - public_html/includes/**):
- If you wish to specify only certain servers in your project to apply the rule to, do so next, otherwise leave Upload to all servers checked:
- Finally click Exclude File.
You may wish to include wildcards in your excluded file rules, such as:
- * - Matches any file
- ** - Matches directories recursively or files expansively
- ? - Matches any one character
- [set] - Matches any one character in set, e.g. [a-z]
For detailed information on how Deploy does file matching see this page