Ignore directories or files

Once you type $ foundry go into your terminal Foundry starts watching files with your code. Every time you save your files, Foundry CLI gets notified to upload your code to the cloud development environment you are connected to. Sometimes though, you don't want Foundry to watch or upload some directories or files. A typical example might be a node_modules directory inside a JavaScript project.

To have Foundry ignore some of your data you can use the field ignore inside your foundry.yaml configuration file. The ignore field is an array of glob patterns.

Here is an example of default values you get from $ foundry init:

ignore:
# Skip all node_modules directories
- "**/node_modules"
# Skip the whole .git directory
- .git
# Skip all temp files ending with number
- "**/*.*[0-9]"
# Skip all hidden files
- "**/.*"
# Skip Vim's temp files
- "**/*~"

If you modify the ignore field you must restart your current session for it to take an effect

‚Äč