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

Added require-const-for-all-caps option to variable-name #2936

Merged
merged 20 commits into from
Mar 12, 2019
Merged

Added require-const-for-all-caps option to variable-name #2936

merged 20 commits into from
Mar 12, 2019

Conversation

JoshuaKGoldberg
Copy link
Contributor

@JoshuaKGoldberg JoshuaKGoldberg commented Jun 20, 2017

PR checklist

Overview of change:

Adds an const-only-for-caps option to variable-name. Any variable whose name is UPPER_CASE should be const.

CHANGELOG.md entry:

[new-rule-option] require-const-for-all-caps for variable-name rule

@JoshuaKGoldberg
Copy link
Contributor Author

Ping @ajafff since you seem to be very active in reviewing?

ajafff
ajafff previously requested changes Dec 3, 2017
src/rules/variableNameRule.ts Outdated Show resolved Hide resolved
src/rules/variableNameRule.ts Outdated Show resolved Hide resolved
src/rules/variableNameRule.ts Outdated Show resolved Hide resolved
@JoshuaKGoldberg
Copy link
Contributor Author

Ping @giladgray - is this ready to be merged in?

@giladgray
Copy link

@JoshuaKGoldberg please update this branch for a green build, or close it if no longer relevant. we will close this if we do not hear from you in two weeks.

Copy link

@giladgray giladgray left a comment

Choose a reason for hiding this comment

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

almost there

src/rules/variableNameRule.ts Outdated Show resolved Hide resolved
test/rules/variable-name/const-only-for-caps/test.ts.lint Outdated Show resolved Hide resolved
@JoshuaKGoldberg JoshuaKGoldberg changed the title Added an all-caps-for-const option to variable-name Added a const-only-for-caps option to variable-name Nov 6, 2018
Copy link
Contributor

@adidahiya adidahiya left a comment

Choose a reason for hiding this comment

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

sorry for coming in after multiple rounds of review, but I think the naming needs to be more clear. I think the clearest rule option would be require-const-for-all-caps. the code symbols should reflect this new name.

@adidahiya adidahiya merged commit 40120a2 into palantir:master Mar 12, 2019
@adidahiya adidahiya changed the title Added a const-only-for-caps option to variable-name Added require-const-for-all-caps option to variable-name Mar 12, 2019
@JoshuaKGoldberg JoshuaKGoldberg deleted the variable-name-caps branch March 12, 2019 11:34
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants