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

chore: add vale rule to enforce colon usage #2441

Merged
merged 2 commits into from
Mar 21, 2024
Merged

chore: add vale rule to enforce colon usage #2441

merged 2 commits into from
Mar 21, 2024

Conversation

lennessyy
Copy link
Contributor

@lennessyy lennessyy commented Mar 21, 2024

Describe the Change

This PR ensures that colons are only used to introduce a list. It specifically looks for a colon, followed by two new line characters, and then any character that is not a dash or a new line. I think this is also the most frequent mistake for us which is to introduce a command with a colon.

It does not try to catch instances of inline colon usage such as There are three kinds of apples: fuji, honey crisp, and cosmic crisp, which I think is permissible and avoids flagging all the false positives in code blocks.

It is possible that this rule could lead to some false positives in code snippets, but there should be only very few of these, and i think we can usually remove the extra new line character if they occur.

Changed Pages

N/A

Jira Tickets

🎫 DOC-1114

Backports

Can this PR be backported?

  • Yes. Remember to add the relevant backport labels to your PR.

@lennessyy lennessyy added backport-version-4-0 Backport change to version 4.0 auto-backport Enable backport backport-version-3-4 Backport change to version 3.4 backport-version-4-1 Backport change to version 4.1 backport-version-4-2 Backport change to version 4.2 labels Mar 21, 2024
Copy link

netlify bot commented Mar 21, 2024

Deploy Preview for docs-spectrocloud ready!

Name Link
🔨 Latest commit 765ba29
🔍 Latest deploy log https://app.netlify.com/sites/docs-spectrocloud/deploys/65fcbb5afad69600086589af
😎 Deploy Preview https://deploy-preview-2441--docs-spectrocloud.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

@lennessyy lennessyy marked this pull request as ready for review March 21, 2024 22:56
@lennessyy lennessyy requested a review from a team as a code owner March 21, 2024 22:56
@@ -337,7 +337,7 @@ stages:

#### Invoke Custom Script

An example of applying logic after the device has booted by using the `boot.after` stage. <br />
An example of applying logic after the device has booted by using the `boot.after` stage:
Copy link
Contributor

Choose a reason for hiding this comment

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

🚫 [vale] reported by reviewdog 🐶
[spectrocloud.colon] Use colons only to introduce lists, unless in code blocks or inline code.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yay - this is working as intended

Copy link
Contributor

@karl-cardenas-coding karl-cardenas-coding left a comment

Choose a reason for hiding this comment

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

I tested it and it looks great

@lennessyy lennessyy merged commit c20feaf into master Mar 21, 2024
10 checks passed
@lennessyy lennessyy deleted the colon-vale branch March 21, 2024 23:23
@vault-token-factory-spectrocloud
Copy link
Contributor

💔 All backports failed

Status Branch Result
version-4-0 Backport failed because of merge conflicts

You might need to backport the following PRs to version-4-0:
- docs: updated URLs to use file path context
version-3-4 Backport failed because of merge conflicts

You might need to backport the following PRs to version-3-4:
- docs: updated URLs to use file path context
version-4-1 Backport failed because of merge conflicts

You might need to backport the following PRs to version-4-1:
- User Data Netplan (#1705)
version-4-2 Backport failed because of merge conflicts

You might need to backport the following PRs to version-4-2:
- replace caution with warning (#2039)

Manual backport

To create the backport manually run:

backport --pr 2441

Questions ?

Please refer to the Backport tool documentation and see the Github Action logs for details

@vault-token-factory-spectrocloud
Copy link
Contributor

🎉 This PR is included in version 4.2.1 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

@vault-token-factory-spectrocloud
Copy link
Contributor

🎉 This PR is included in version 4.2.1 🎉

The release is available on GitHub release

Your semantic-release bot 📦🚀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
auto-backport Enable backport backport-version-3-4 Backport change to version 3.4 backport-version-4-0 Backport change to version 4.0 backport-version-4-1 Backport change to version 4.1 backport-version-4-2 Backport change to version 4.2 released
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants