Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
31 commits
Select commit Hold shift + click to select a range
67b3dc9
add vale-linter skeleton
nicoalba Dec 16, 2025
b0dfb4c
remove damn zone identifiers
nicoalba Dec 16, 2025
193f087
add new lines
nicoalba Dec 16, 2025
85b95b4
EOD
nicoalba Dec 23, 2025
feaf414
add mdx extension and microsoft package
nicoalba Dec 23, 2025
60c2e4f
adjust rules
nicoalba Dec 23, 2025
654f4bb
rule updates
nicoalba Dec 23, 2025
8aeb30c
vale working now
nicoalba Dec 23, 2025
8414c87
test pipelines cvale
nicoalba Dec 23, 2025
b57af5e
Add Vale CI workflow
nicoalba Dec 23, 2025
285d7f6
fix config to show develop
nicoalba Dec 23, 2025
ff8223e
Force CI trigger
nicoalba Dec 23, 2025
308c92f
Fix CI to target main branch
nicoalba Dec 23, 2025
7745e03
add no fail line for buiild
nicoalba Dec 23, 2025
b0780ed
add markdownlint step to container
nicoalba Dec 23, 2025
c650e93
new test
nicoalba Dec 23, 2025
371546a
remove tests
nicoalba Dec 23, 2025
0c61eac
EOD
nicoalba Dec 23, 2025
7e3bc19
Disable Microsoft.Vocab rule in Vale configuration
nicoalba Dec 24, 2025
f87fbea
Update .vale.ini
nicoalba Dec 24, 2025
deccf3b
Update .vale.ini
nicoalba Dec 24, 2025
b8025d8
Add TokenIgnores back to .vale.ini
nicoalba Dec 24, 2025
eb44f57
Disable SentenceLength and Adverbs checks in Vale
nicoalba Dec 26, 2025
d80bb8b
Add new terms to accept.txt vocabulary list
nicoalba Dec 26, 2025
b099098
Delete docs-linter/sanity-check.md
nicoalba Dec 26, 2025
b15d614
Update accept.txt
nicoalba Dec 26, 2025
36a8d5a
Add exclusions for technical writing in .vale.ini
nicoalba Dec 26, 2025
65858ab
Add terms 'plaintext', 'ciphertext', 'Keycloak', and 'IdP'
nicoalba Dec 26, 2025
33d2d57
updates
nicoalba Dec 26, 2025
6be32a6
updates to tokens
nicoalba Dec 26, 2025
b527908
remove unwanted microsoft files
nicoalba Dec 26, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 33 additions & 0 deletions .github/workflows/vale-check.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
name: Vale Linter Check

on:
push:
branches: [ main ]
pull_request:
branches: [ main ]

jobs:
vale-quality-check:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Install Vale
run: |
wget https://github.com/errata-ai/vale/releases/download/v3.9.0/vale_3.9.0_Linux_64-bit.tar.gz
tar -xvzf vale_3.9.0_Linux_64-bit.tar.gz
sudo mv vale /usr/local/bin/

- name: Run Vale Smoke Test
run: |
cd docs-linter
vale sync
vale smoke-test.md --no-exit

- name: Install Markdownlint
run: sudo npm install -g markdownlint-cli

- name: Run Markdownlint (Format Check)
run: |
cd docs-linter
markdownlint --config .markdownlint.json smoke-test.md || true
Empty file.
8 changes: 8 additions & 0 deletions docs-linter/.markdownlint.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"default": true,
"MD013": false,
"MD024": false,
"MD033": false,
"MD034": false,
"MD041": false
}
26 changes: 26 additions & 0 deletions docs-linter/.vale.ini
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
StylesPath = styles
MinAlertLevel = suggestion
Vocab = terms
Packages = Microsoft

[*.{md,mdx}]
BasedOnStyles = Vale, Microsoft, custom-rules
TokenIgnores = (https?://[^\s\)]+), (`.+?`), (\*\*.+?\*\*)
BlockIgnores = (?s)(^---\n.*?\n---)

# Disable noisy Microsoft rules
Microsoft.Accessibility = NO
Microsoft.Gender = NO
Microsoft.GenderBias = NO
Microsoft.Vocab = NO
Microsoft.Acronyms = NO
Microsoft.Foreign = NO
Microsoft.Avoid = NO
Microsoft.Terms = NO
Microsoft.Passive = NO
Microsoft.HeadingAcronyms = NO
Microsoft.GeneralURL = NO
Microsoft.SentenceLength = NO
Microsoft.Adverbs = NO
Microsoft.We = NO
Microsoft.FirstPerson = NO
16 changes: 16 additions & 0 deletions docs-linter/smoke-test.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
# Smoke Test File

This is a paragraph with trailing spaces at the end.
(That line has spaces, triggering MD009).

# A Second H1 Header (Violation: MD025)

#### Skipped Header Level (Violation: MD001 - H1 to H4)

Here is a list of Vale violations:

1. **Branding:** We use netfoundry and github in our daily work.
2. **Passive Voice:** The file was opened by the admin.
3. **Wordiness:** In order to login, you must utilize the key.
4. **First Person:** I decided to push the code myself.
5. **Spelling:** This is a testtoken for moret esting.
11 changes: 11 additions & 0 deletions docs-linter/styles/Microsoft/Auto.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
extends: existence
message: "In general, don't hyphenate '%s'."
link: https://docs.microsoft.com/en-us/style-guide/a-z-word-list-term-collections/a/auto
ignorecase: true
level: error
action:
name: convert
params:
- simple
tokens:
- 'auto-\w+'
14 changes: 14 additions & 0 deletions docs-linter/styles/Microsoft/ComplexWords.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
extends: substitution
message: "Consider using '%s' instead of '%s'"
level: warning
ignorecase: true
# This rule swaps complex words for simpler ones (e.g. utilize -> use)
swap:
utilize: use
utilization: use
facilitate: help
leverage: use
commence: start
terminate: end
subsequently: later

50 changes: 50 additions & 0 deletions docs-linter/styles/Microsoft/Contractions.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,50 @@
extends: substitution
message: "Use '%s' instead of '%s'."
link: https://docs.microsoft.com/en-us/style-guide/word-choice/use-contractions
level: error
ignorecase: true
action:
name: replace
swap:
are not: aren't
cannot: can't
could not: couldn't
did not: didn't
do not: don't
does not: doesn't
has not: hasn't
have not: haven't
how is: how's
is not: isn't

'it is(?!\.)': it's
'it''s(?=\.)': it is

should not: shouldn't

"that is(?![.,])": that's
'that''s(?=\.)': that is

'they are(?!\.)': they're
'they''re(?=\.)': they are

was not: wasn't

'we are(?!\.)': we're
'we''re(?=\.)': we are

'we have(?!\.)': we've
'we''ve(?=\.)': we have

were not: weren't

'what is(?!\.)': what's
'what''s(?=\.)': what is

'when is(?!\.)': when's
'when''s(?=\.)': when is

'where is(?!\.)': where's
'where''s(?=\.)': where is

will not: won't
13 changes: 13 additions & 0 deletions docs-linter/styles/Microsoft/Dashes.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
extends: existence
message: "Remove the spaces around '%s'."
link: https://docs.microsoft.com/en-us/style-guide/punctuation/dashes-hyphens/emes
ignorecase: true
nonword: true
level: error
action:
name: edit
params:
- trim
- " "
tokens:
- '\s[—–]\s|\s[—–]|[—–]\s'
8 changes: 8 additions & 0 deletions docs-linter/styles/Microsoft/DateFormat.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
extends: existence
message: Use 'July 31, 2016' format, not '%s'.
link: https://docs.microsoft.com/en-us/style-guide/a-z-word-list-term-collections/term-collections/date-time-terms
ignorecase: true
level: error
nonword: true
tokens:
- '\d{1,2} (?:Jan(?:uary)?|Feb(?:ruary)?|Mar(?:ch)?|Apr(?:il)|May|Jun(?:e)|Jul(?:y)|Aug(?:ust)|Sep(?:tember)?|Oct(?:ober)|Nov(?:ember)?|Dec(?:ember)?) \d{4}'
40 changes: 40 additions & 0 deletions docs-linter/styles/Microsoft/DateNumbers.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,40 @@
extends: existence
message: "Don't use ordinal numbers for dates."
link: https://docs.microsoft.com/en-us/style-guide/numbers#numbers-in-dates
level: error
nonword: true
ignorecase: true
raw:
- \b(?:Jan(?:uary)?|Feb(?:ruary)?|Mar(?:ch)?|Apr(?:il)|May|Jun(?:e)|Jul(?:y)|Aug(?:ust)|Sep(?:tember)?|Oct(?:ober)|Nov(?:ember)?|Dec(?:ember)?)\b\s*
tokens:
- first
- second
- third
- fourth
- fifth
- sixth
- seventh
- eighth
- ninth
- tenth
- eleventh
- twelfth
- thirteenth
- fourteenth
- fifteenth
- sixteenth
- seventeenth
- eighteenth
- nineteenth
- twentieth
- twenty-first
- twenty-second
- twenty-third
- twenty-fourth
- twenty-fifth
- twenty-sixth
- twenty-seventh
- twenty-eighth
- twenty-ninth
- thirtieth
- thirty-first
8 changes: 8 additions & 0 deletions docs-linter/styles/Microsoft/DateOrder.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
extends: existence
message: "Always spell out the name of the month."
link: https://docs.microsoft.com/en-us/style-guide/numbers#numbers-in-dates
ignorecase: true
level: error
nonword: true
tokens:
- '\b\d{1,2}/\d{1,2}/(?:\d{4}|\d{2})\b'
9 changes: 9 additions & 0 deletions docs-linter/styles/Microsoft/Ellipses.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
extends: existence
message: "In general, don't use an ellipsis."
link: https://docs.microsoft.com/en-us/style-guide/punctuation/ellipses
nonword: true
level: warning
action:
name: remove
tokens:
- '\.\.\.'
16 changes: 16 additions & 0 deletions docs-linter/styles/Microsoft/FirstPerson.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,16 @@
extends: existence
message: "Use first person (such as '%s') sparingly."
link: https://docs.microsoft.com/en-us/style-guide/grammar/person
ignorecase: true
level: warning
nonword: true
tokens:
- (?:^|\s)I(?=\s)
- (?:^|\s)I(?=,\s)
- \bI'd\b
- \bI'll\b
- \bI'm\b
- \bI've\b
- \bme\b
- \bmy\b
- \bmine\b
8 changes: 8 additions & 0 deletions docs-linter/styles/Microsoft/Gender.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
extends: existence
message: "Don't use '%s'."
link: https://github.com/MicrosoftDocs/microsoft-style-guide/blob/master/styleguide/grammar/nouns-pronouns.md#pronouns-and-gender
level: error
ignorecase: true
tokens:
- he/she
- s/he
8 changes: 8 additions & 0 deletions docs-linter/styles/Microsoft/HeadingColons.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
extends: existence
message: "Capitalize '%s'."
link: https://docs.microsoft.com/en-us/style-guide/punctuation/colons
nonword: true
level: error
scope: heading
tokens:
- ':\s[a-z]'
13 changes: 13 additions & 0 deletions docs-linter/styles/Microsoft/HeadingPunctuation.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
extends: existence
message: "Don't use end punctuation in headings."
link: https://docs.microsoft.com/en-us/style-guide/punctuation/periods
nonword: true
level: warning
scope: heading
action:
name: edit
params:
- trim_right
- ".?!"
tokens:
- "[a-z][.?!]$"
28 changes: 28 additions & 0 deletions docs-linter/styles/Microsoft/Headings.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
extends: capitalization
message: "'%s' should use sentence-style capitalization."
link: https://docs.microsoft.com/en-us/style-guide/capitalization
level: suggestion
scope: heading
match: $sentence
indicators:
- ':'
exceptions:
- Azure
- CLI
- Code
- Cosmos
- Docker
- Emmet
- I
- Kubernetes
- Linux
- macOS
- Marketplace
- MongoDB
- REPL
- Studio
- TypeScript
- URLs
- Visual
- VS
- Windows
14 changes: 14 additions & 0 deletions docs-linter/styles/Microsoft/Hyphens.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
extends: existence
message: "'%s' doesn't need a hyphen."
link: https://docs.microsoft.com/en-us/style-guide/punctuation/dashes-hyphens/hyphens
level: warning
ignorecase: false
nonword: true
action:
name: edit
params:
- regex
- "-"
- " "
tokens:
- '\b[^\s-]+ly-\w+\b'
13 changes: 13 additions & 0 deletions docs-linter/styles/Microsoft/Negative.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
extends: existence
message: "Form a negative number with an en dash, not a hyphen."
link: https://docs.microsoft.com/en-us/style-guide/numbers
nonword: true
level: error
action:
name: edit
params:
- regex
- "-"
- "–"
tokens:
- '(?<=\s)-\d+(?:\.\d+)?\b'
13 changes: 13 additions & 0 deletions docs-linter/styles/Microsoft/Ordinal.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
extends: existence
message: "Don't add -ly to an ordinal number."
link: https://docs.microsoft.com/en-us/style-guide/numbers
level: error
action:
name: edit
params:
- trim
- ly
tokens:
- firstly
- secondly
- thirdly
8 changes: 8 additions & 0 deletions docs-linter/styles/Microsoft/OxfordComma.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
extends: existence
message: "Use the Oxford comma in '%s'."
link: https://docs.microsoft.com/en-us/style-guide/punctuation/commas
scope: sentence
level: suggestion
nonword: true
tokens:
- '(?:[^\s,]+,){1,} \w+ (?:and|or) \w+[.?!]'
7 changes: 7 additions & 0 deletions docs-linter/styles/Microsoft/Percentages.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
extends: existence
message: "Use a numeral plus the units."
link: https://docs.microsoft.com/en-us/style-guide/numbers
nonword: true
level: error
tokens:
- '\b[a-zA-z]+\spercent\b'
7 changes: 7 additions & 0 deletions docs-linter/styles/Microsoft/Plurals.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
extends: existence
message: "Don't add '%s' to a singular noun. Use plural instead."
ignorecase: true
level: error
link: https://learn.microsoft.com/en-us/style-guide/a-z-word-list-term-collections/s/s-es
raw:
- '\(s\)|\(es\)'
Loading