realm / realm/SwiftLint

Script input files are much slower then explicit passing the paths

Open
#6,031 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

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

Description

New Issue Checklist
Bug Description

I found that calling swiftlint lint with 5000 files via SCRIPT_INPUT_FILE_N takes much longer time to lint than passing the paths explicitly:

# export SCRIPT_INPUT_FILE_N...
swiftlint lint --no-cache --use-script-input-files --progress

vs

swiftlint lint <paths> --no-cache --progress

The problem is not the timing of the linting itself, but the preparatory work that happens before anything starts.

Environment
  • SwiftLint version 0.58.2
  • Xcode version 16.2
  • Installation method used mise-en-place

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 with the swiftlint lint --use-script-input-files entry point and compare its preparatory work with swiftlint lint <paths> using 5,000 files and --no-cache --progress. Done means the script-input-files path no longer spends substantially longer preparing before linting begins.

Written by the indexing model from the issue text.

Assessment

Tech stack
swift
Domain
cli, performance, tooling
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
45/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.