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

Comparison mode runs twice when in default branch #377

Closed
denny opened this issue Jan 16, 2021 · 2 comments
Closed

Comparison mode runs twice when in default branch #377

denny opened this issue Jan 16, 2021 · 2 comments

Comments

@denny
Copy link
Contributor

denny commented Jan 16, 2021

If you set a branch for comparisons, then run rubycritic while that branch is checked out, it runs against the same branch twice - which seems like wasted effort, unless I'm missing something.

I've added this as a separate issue from #287 because it's not about the file layout, but I'm tag-linking them in case somebody wants to tackle both at once 🙂

@rishijain
Copy link
Contributor

Yes, I imagine there is no logical need to compare same branches at all and it is most likely a mistake from the user. So may be it would be better to raise an error instead of running it once for the branch or continue running twice like it is now. I have created the above PR based on that it should raise a Runtime error rather than silently handling it.

@etagwerker
Copy link
Collaborator

I believe this was fixed by #471

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

No branches or pull requests

3 participants