Tldr: Token inconsistency: quotes inside/outside tokens

Created on 26 Sep 2020  路  8Comments  路  Source: tldr-pages/tldr

Hi! The goal of this issue is to discuss one of the inconsistencies I listed here a couple of years ago, namely, whether to place quotes {{"inside"}} or "{{outside}}" a token.

Running a search in the codebase, there are by far more quotes outside than inside. Besides this, I'd argue that putting quotes outside is the best strategy for two other reasons:

  1. It removes any ambiguity on what is replaceable and what not within the token - that is, are the quotes necessary or not to preserve?
  2. It allows for more appropriate use of the quotes within the token, like for the gist command: {{echo "hello world"}} | gist

What do you think? :)

Most helpful comment

If you all agree, I can work on this issue in the next days

All 8 comments

Hi @glenacota, thanks for flagging this up. I agree that putting quotes outside is the best strategy. 馃憤馃徎

Nice! I can work on this during the week.
What would be the best way to proceed? I think a bulk update is preferable, with a single, consistent PR. Maybe one could split the changes into several commits by, e.g., localisation.

I think a single bulk PR makes sense, I guess it depends on how many pages there are that require changes. 馃

Great spot! A single bulk PR would be preferable. Personally I prefer quotes outside.

We'll need to look closely at it though when reviewing, because it's possible that in some circumstances there will be a reason for the way it has been done. We should also be careful to keep the same type of quotes (e.g. sing vs double), because it's possible they will also have meaning (e.g. single are best when specifying a regular expression, for example).

If you all agree, I can work on this issue in the next days

Yep, I think we can agree that outside quotes are the best approach @glenacota. Thanks for the assistance! :D

Great find.
I will review the PR you've opened.

Solved with #4431. Thanks, everyone :)

Was this page helpful?
0 / 5 - 0 ratings

Related issues

pascaliske picture pascaliske  路  3Comments

phpmaple picture phpmaple  路  3Comments

GabLeRoux picture GabLeRoux  路  3Comments

TobiasRoland picture TobiasRoland  路  3Comments

endearingyoungcharms picture endearingyoungcharms  路  3Comments