No exclude rules are applied for --use-stdin files
Nobody has claimed this yet.
- Dominant language
- Swift
- Stars
- 19.7k
- Forks
- 2.3k
- Avg merge
- 1d 1h
- Merged PRs (30d)
- 11
Description
New Issue Checklist
- [V] Updated SwiftLint to the latest version
- [V] I searched for existing GitHub issues
Describe the bug
SwiftLint do not exclude a file provided via stdin event with --force-exclude flag.
Looks like no file exclusion is performed for stdin-provided data:

It would be nice if there is a way to provide a file-path along with the stdin data to participate in unified file exclusion logic according to config as expected.
Environment
- SwiftLint version: 0.46.5
- Installation method: download from releases
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by tracing the --use-stdin and --force-exclude entry points and how stdin-provided data is associated with a file. Determine how a file path can participate in the existing exclusion logic. Done means excluded stdin files are skipped or handled consistently with regular files when both flags are used.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- swift
- Domain
- cli, tooling
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100