Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enumerate scripts in parallel #68

Merged
merged 2 commits into from
Jul 19, 2019
Merged

Enumerate scripts in parallel #68

merged 2 commits into from
Jul 19, 2019

Conversation

soutaro
Copy link
Owner

@soutaro soutaro commented Jul 19, 2019

Using parallel gem, ScriptEnumerator#each yields Script objects concurrently, in threads. You can pass --threads command line option to specify number of threads for check, console, and find commands.

If your config has preprocessor definition and your source files contain many preprocessed files, this patch improves the performance up to ~#of threads in your processor. I tested on my Core i5, 4 threads iMac, --threads=4 runs about three times faster than --threads=1 for HAML files.

@soutaro soutaro merged commit 9a8b26b into master Jul 19, 2019
@soutaro soutaro deleted the parallel-enumerate branch July 19, 2019 08:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant