ChatGPT File ignore

I wanted to ask is there a possibility to have an ignore file for specific files on XCode 26 like all of the other AI IDE's have?

It's somewhat impossible to use the feature without this type of functionality on the platform.

If not possible, will it be available sometime in the future?

Answered by Engineer in 861099022

The intelligence features in Xcode have a feature for exactly this starting in Xcode 26!

To ask the context search tools to avoid specific files or parts of your project, you can put a file called .contextignore next to the workspace or project file for your project and use .gitignore-style syntax to describe "globs" to match relative paths against.

This should work in a very similar way to how other, similar code editing environments with intelligence features support ignoring files.

Accepted Answer

The intelligence features in Xcode have a feature for exactly this starting in Xcode 26!

To ask the context search tools to avoid specific files or parts of your project, you can put a file called .contextignore next to the workspace or project file for your project and use .gitignore-style syntax to describe "globs" to match relative paths against.

This should work in a very similar way to how other, similar code editing environments with intelligence features support ignoring files.

Works as expeced, thank you!

@Engineer this is not working for me.

I have placed a .contextignore file next to my .xcworkspace file, it's contents look like this:

CHANGELOG.md
*.generated.swift
*.mockingbird.swift

However I'm still getting files that match these globs in my project context requests

ChatGPT File ignore
 
 
Q