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

CamelCase and organize config variables #933

Open
Denton-L opened this issue Apr 15, 2021 · 0 comments
Open

CamelCase and organize config variables #933

Denton-L opened this issue Apr 15, 2021 · 0 comments

Comments

@Denton-L
Copy link
Member

This obviously does not have to be part of this miniseries, but I
wonder if we should have a list of all the configuration variables
in one place that we can use to record the canonical spelling of
these variables. As

$ git grep -h -E -i
-e '^[a-z][-a-z0-9].[a-z][-a-z0-9]::'
-e '^[a-z][-a-z0-9].(*|<?[a-z][-a-z0-9]>?).(*|<?[a-z][-a-z0-9]*>?)::'
Documentation/config

gives many hits with camelCased names, it might be a good place to
start.

Pretending that the above gives a good "canonical list" (it does not
yet, if you look at the hits), I got curious how far we can go.

Massaging the output from the above into config-variables.lst

$ ... above command ... |
sed -e 's/::$//' |
sort -u >config-variables.lst

and then to extract use of these tokens in the main part of the
documentation like this:

$ git grep -h -o -i -F -f config-variables.lst --
Documentation/ ':!Documentation/RelNotes/' |
sort -u >config-usage.lst

gives us something we can compare with the "canonical" usage list.

$ comm -3 config-usage.lst config-variables.lst
blame.blankboundary
core.excludesfile
core.filemode
core.gitproxy
core.ignorestat
core.logallrefupdates
core.repositoryformatversion
core.trustCtime
http.sslverify
http.sslversion
i18n.commitencoding
push.pushoption
remote..partialCloneFilter
remote.pushdefault
repack.UseDeltaBaseOffset
sendemail.aliasesfile
showbranch.default
transfer.hiderefs
uploadArchive.allowUnreachable

Some of them may be false hits, some may be showing that the copy in
Documentation/config/ are spelled in all lowercase, but the majority
of the hits above seem to be genuine errors similar to what you fixed
in your patch.

Thanks.

https://lore.kernel.org/git/[email protected]/

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

1 participant