Skip to content
This repository has been archived by the owner on Mar 25, 2021. It is now read-only.

Indent rule option to allow spaces after tabs #1317

Closed
wants to merge 2 commits into from
Closed

Indent rule option to allow spaces after tabs #1317

wants to merge 2 commits into from

Conversation

JoshuaKGoldberg
Copy link
Contributor

Allows a configurable maximum number of spaces after tabs.

Fixes #1306.

Josh Goldberg added 2 commits June 19, 2016 05:15
Allows a configurable maximum number of spaces after tabs.

Fixes #1306.
@jkillian
Copy link
Contributor

jkillian commented Jun 22, 2016

Feeling a little hesitant on this, let's see what others think before going further. Worst case you can always make this a custom rule if needed in some of your projects

@olegstepura
Copy link

IMHO one should make a choice and never mix spaces with tabs.

@ChrisMBarr
Copy link
Contributor

Yeah I agree, I can't see a lot of people needing a rule to enforce tabs only, but also sometime allow a maximum of 3 spaces after that. Perhaps that makes sense for your team, but I cannot think of a good use case for that option.

Typically the choices are "tabs", "spaces", or "I don't care to enable this rule"

@JoshuaKGoldberg
Copy link
Contributor Author

@ChrisMBarr I've put a defense + use case in the other thread, #1306 (comment)

@jkillian
Copy link
Contributor

jkillian commented Jun 27, 2016

I understand where you're coming from @JoshuaKGoldberg, but mixing tabs and spaces doesn't seem like an idea we want to encourage, so I'm going to close this. I never enjoy closing PRs that people have put time and effort into, but in this case it seems like the best course of action.

@jkillian jkillian closed this Jun 27, 2016
@JoshuaKGoldberg
Copy link
Contributor Author

Makes sense, no worries! I appreciate you & the other participants taking the time to think it over and give feedback.

@vhakulinen
Copy link

I'll leave my (and probably my colleague's) two cents here and vouch for this opt-in feature. I can really relate to this comment: #1306 (comment) (already mentioned above by @JoshuaKGoldberg). Really useful when you're using tabs for indention but still want to line up arguments or conditions in if statement with the line above (after indention tabs).

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants