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

help: Exchange all indentations to spaces and remove trailing ws #3193

Merged
merged 4 commits into from
Mar 22, 2024

Conversation

JoeKar
Copy link
Collaborator

@JoeKar JoeKar commented Mar 18, 2024

To hopefully cleanup the mess.
It can be discussed, if tabs are preferred.

@JoeKar
Copy link
Collaborator Author

JoeKar commented Mar 18, 2024

Argh, crap...duplicates #3190.
@dustdfg Please decide which one to take.
Sorry for that. :(

@dustdfg
Copy link
Contributor

dustdfg commented Mar 18, 2024

  1. I see you did spaces for default values strings but you used indentation 2 spaces when it was 4. I think default value should be indented with 4 spaces to be more noticeable in contrast of other text which use only 2

  2. Sorry for images but not links because I don't know how to make links for diffs. It is what you missed:
    screen-1710786383
    screen-1710786363

  3. Currently most of the lines use following indentation:

* 'word' wooooooord
   word

Your PR use:

* 'word' woooooord
  word

I just sticked to the most used format but format of your PR is easier to write (at least for me). It is the reason why yours PR shows +494 −493 it modifies the most used lines and my +45 −45

  1. You used spaces for the json blocks in the options file

  2. It is also possible to convert all plain text key bindings to back quoted:
    back quotes: Ctrl-e
    plain text: Ctrl-e

@JoeKar
Copy link
Collaborator Author

JoeKar commented Mar 18, 2024

  1. I see you did spaces for default values strings but you used indentation 2 spaces when it was 4. I think default value should be indented with 4 spaces to be more noticeable in contrast of other text which use only 2

Yes and before it was a wild mixture of different approaches. The reason for using 2 spaces instead of 3 was it has base 2, which helps in the moment you work with detectindent and try to indent within the code parts. But we can use 4 or even tabs as well. It's just a matter of preferences.

  1. Currently most of the lines use following indentation:

Yes and this in combination with detectindent can cause issues in the moment you extend the code parts.

  1. You used spaces for the json blocks in the options file

I used spaces in the whole file to keep it consistent. In case of trouble we can change it again.

  1. It is also possible to convert all plain text key bindings to back quoted:

Done.

@dmaluka
Copy link
Collaborator

dmaluka commented Mar 18, 2024

@JoeKar

Yes and this in combination with detectindent can cause issues in the moment you extend the code parts.

I don't think this is enough justification for changing the existing style.

@dustdfg

I just sticked to the most used format but format of your PR is easier to write (at least for me).

While the currently used format (with 3 spaces) is easier to read (at least for me).

Honestly I see no reasons why need to change the current style.

@dustdfg
Copy link
Contributor

dustdfg commented Mar 18, 2024

It is not always 3 sometimes it is 2. If first word started from ` it will be 3 otherwise 2

@JoeKar
Copy link
Collaborator Author

JoeKar commented Mar 18, 2024

Honestly I see no reasons why need to change the current style.

Consistency.
To be honest, for me it doesn't really matter for which indentation type and width we vote...we just need to be consistent at least within one file. AFAIK this wasn't the case. :)

@dmaluka
Copy link
Collaborator

dmaluka commented Mar 18, 2024

If first word started from ` it will be 3 otherwise 2

Yes, and it makes sense for readability actually.

@dmaluka
Copy link
Collaborator

dmaluka commented Mar 18, 2024

Thanks, now this PR does just what it says in the title, no extra ambitious changes.
Could you also squash the 3rd patch into the 1st one? For the ease of review, obviously.

@JoeKar JoeKar force-pushed the fix/help-indentations branch from 7b929fa to 3440172 Compare March 18, 2024 23:17
runtime/help/commands.md Outdated Show resolved Hide resolved
@JoeKar JoeKar force-pushed the fix/help-indentations branch from 3440172 to 3f5a274 Compare March 19, 2024 17:11
runtime/help/options.md Outdated Show resolved Hide resolved
runtime/help/options.md Outdated Show resolved Hide resolved
runtime/help/options.md Show resolved Hide resolved
runtime/help/plugins.md Outdated Show resolved Hide resolved
JoeKar and others added 4 commits March 21, 2024 20:50
Co-authored-by: Jöran Karl <[email protected]>
- removed some superfluous whitespaces
- add a line break in before an link
- corrected one typo
@JoeKar JoeKar force-pushed the fix/help-indentations branch from 3f5a274 to 3186e07 Compare March 21, 2024 19:50
@JoeKar JoeKar merged commit bb1f4da into zyedidia:master Mar 22, 2024
3 checks passed
@JoeKar JoeKar deleted the fix/help-indentations branch March 22, 2024 16:58
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

Successfully merging this pull request may close these issues.

3 participants