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

refactor(cli): command runner #4198

Merged
merged 3 commits into from
Oct 7, 2024
Merged

refactor(cli): command runner #4198

merged 3 commits into from
Oct 7, 2024

Conversation

ematipico
Copy link
Member

@ematipico ematipico commented Oct 7, 2024

Summary

This PR migrates the majority of commands to use the CommandRunner trait.

I also created a new trait called LoadEditorConfig to share the same logic only for the format, check and ci commands, where we load the .editorconfig file.

Test Plan

Current CI should work. Checked that the updated snapshots are correct.

@github-actions github-actions bot added A-CLI Area: CLI A-Linter Area: linter L-CSS Language: CSS labels Oct 7, 2024
@ematipico ematipico requested review from a team October 7, 2024 09:45
Copy link
Contributor

@arendjr arendjr left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Very nice cleanup! Love the structure this brings.

crates/biome_cli/src/commands/mod.rs Outdated Show resolved Hide resolved
crates/biome_cli/src/commands/check.rs Outdated Show resolved Hide resolved
Copy link

codspeed-hq bot commented Oct 7, 2024

CodSpeed Performance Report

Merging #4198 will improve performances by 7.29%

Comparing refactor/cli-commands (95b2409) with main (d5655e9)

Summary

⚡ 2 improvements
✅ 103 untouched benchmarks

Benchmarks breakdown

Benchmark main refactor/cli-commands Change
react.production.min_3378072959512366797.js[cached] 2 ms 1.9 ms +7.05%
db_17847247775464589309.json[uncached] 16.4 ms 15.3 ms +7.29%

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-CLI Area: CLI A-Linter Area: linter L-CSS Language: CSS
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants