-
Notifications
You must be signed in to change notification settings - Fork 1.7k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add linters for consistent docs product language
Closes #19214 Maintaining a consistent language for talking about Teleport products is important for ensuring clarity in the documentation. This change adds rules to our Vale linting config for docs to help maintain a consistent product language: - **Teleport account URL examples:** Require `example.teleport.sh` unless the text is mentioning the status page. - **Service names:** Require these to be capitalized. - **Enforce consistency in other areas where we often get discrepancies:** e.g., "Auth Service instances" instead of "auth servers". This change also renames the `messaging` style rule to `consistent-terms` so we don't have a `messaging.messaging` rule. Note that these linters overlap with similar ones that we run from the `gravitational/docs` repo. The plan is to remove the latter once we merge the linters here.
- Loading branch information
Showing
6 changed files
with
59 additions
and
13 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,8 @@ | ||
extends: substitution | ||
message: "Incorrect example of a Teleport account URL. Use %s instead of %s." | ||
level: error | ||
scope: | ||
- raw | ||
ignorecase: true | ||
swap: | ||
- 'https://(?!status|example)\w+.teleport\.sh': 'example.teleport.sh (or status.teleport.sh for the status page)' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,21 @@ | ||
extends: existence | ||
scope: | ||
- heading | ||
- table | ||
- list | ||
- paragraph | ||
message: "Capitalize the names of Teleport services (%s is incorrect). See the Core Concepts page (https://goteleport.com/docs/core-concepts/) for service names." | ||
level: error | ||
ignorecase: false | ||
tokens: | ||
- machine id | ||
- database service | ||
- db service | ||
- 'app(lication) service' | ||
- desktop service | ||
- kubernetes service | ||
- ssh service | ||
- discovery service | ||
- auth service | ||
# Allow for mentions of a local proxy service, but not "proxy service". | ||
- '(?<!local )proxy service' |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,22 @@ | ||
# The consistent-terms rule ensures that terms with frequently used variations | ||
# appear consistently in the docs. | ||
extends: substitution | ||
scope: | ||
- heading | ||
- table | ||
- list | ||
- paragraph | ||
message: For consistent product messaging in the docs, use '%s' instead of '%s'. | ||
level: error | ||
# Ignoring case because this rule is about word choice, rather than its | ||
# presentation/format. | ||
ignorecase: true | ||
swap: | ||
2FA: MFA | ||
'second[ -]factor': multi-factor | ||
'auth and proxy': Auth Service and Proxy Service | ||
'auth server|auth node': \"Auth Service\" (or \"Auth Service instance\" for a specific node) | ||
'Auth Services': Auth Service instances | ||
'Teleport open source|open source Teleport': Teleport Community Edition | ||
'OSS Teleport|Teleport OSS': Teleport Community Edition | ||
'Teleport Cloud': \"Teleport Team\" or \"Teleport Enterprise Cloud\" |
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -5,4 +5,4 @@ MinAlertLevel = suggestion | |
mdx = md | ||
|
||
[*.md] | ||
BasedOnStyles = messaging | ||
BasedOnStyles = messaging,examples |