realm / realm/SwiftLint

No exclude rules are applied for --use-stdin files

Open
#3,913 4 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

discussion enhancement
Dominant language
Swift
Stars
19.7k
Forks
2.3k
Avg merge
1d 1h
Merged PRs (30d)
11

Description

New Issue Checklist
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:
Screenshot 2022-03-22 at 12 47 05

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

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. 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

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.