chore: fix/remove broken vale rules

Signed-off-by: David Karlsson <35727626+dvdksn@users.noreply.github.com>
This commit is contained in:
David Karlsson 2023-09-14 11:39:07 +02:00
parent e6301f1ba2
commit a910fdb6dc
17 changed files with 102 additions and 170 deletions

8
.github/vale/.vale-config/0-Hugo.ini vendored Normal file
View File

@ -0,0 +1,8 @@
[*.md]
# Exclude `{{< ... >}}`, `{{% ... %}}`, [Who]({{< ... >}})
TokenIgnores = ({{[%<] .* [%>]}}.*?{{[%<] ?/.* [%>]}}), \
(\[.+\]\({{< .+ >}}\))
# Exclude `{{< myshortcode `This is some <b>HTML</b>, ... >}}`
BlockIgnores = (?sm)^({{[%<] [^{]*? [%>]}})\n$, \
(?s) *({{< highlight [^>]* ?>}}.*?{{< ?/ ?highlight >}})

View File

@ -4,3 +4,4 @@ ignorecase: true
level: warning level: warning
tokens: tokens:
- Please - Please
- At this time

View File

@ -1,8 +0,0 @@
# Checks for use of bold that doesn't start with a capital letter
# which might indicate a reference to something other than a UI label
extends: existence
message: "Only use bold for UI elements."
link: https://docs.docker.com/contribute/checklist/
level: suggestion
scope: strong
raw: "^[^A-Z].*"

View File

@ -1,12 +0,0 @@
extends: existence
message: "Indent nested code blocks by 3 spaces and double-nested code blocks by 5 spaces."
link: https://docs.docker.com/contribute/style/formatting/#best-practice-for-commands
level: warning
scope: raw
# check for 1, 2, 4, 6 or more spaces at start of line before code fence (```)
# If not indented by 3 spaces at first level or 5 spaces at second level, then a hidden space is inserted and copied by the copy code feature.
raw:
- '(?m:^[ ]{1}\`\`\`)|'
- '(?m:^[ ]{2}\`\`\`)|'
- '(?m:^[ ]{4}\`\`\`)|'
- '(?m:^[ ]{6,}\`\`\`)'

View File

@ -22,7 +22,7 @@ swap:
should not: shouldn't should not: shouldn't
'that is(?!\.)': that's 'that is(?!\.,)': that's
'that''s(?=\.)': that is 'that''s(?=\.)': that is
'they are(?!\.)': they're 'they are(?!\.)': they're

View File

@ -1,8 +0,0 @@
extends: existence
message: "Avoid using words like '%s', the docs should describe the product as is."
link: https://docs.docker.com/contribute/style/recommended-words/
level: warning
ignorecase: true
tokens:
- At this time
- Currently

View File

@ -2,9 +2,7 @@ extends: existence
message: "Avoid generic calls to action: '%s'" message: "Avoid generic calls to action: '%s'"
link: https://docs.docker.com/contribute/style/formatting/#links link: https://docs.docker.com/contribute/style/formatting/#links
level: warning level: warning
scope: link scope: raw
ignorecase: true ignorecase: true
tokens: raw:
- click here - \[(click here|(find out|learn) more)\]
- find out more
- learn more

View File

@ -1,20 +0,0 @@
# This catch-all pattern uses raw which means it
# will match in code, too. Kept for reference.
#
# extends: existence
# message: Use italics sparingly.
# level: suggestion
# scope: raw
# raw:
# - '[\*_]'
# - '.*?'
# - '[\*_]'
# - '(?=[$\s])'
extends: existence
message: Use italics sparingly.
level: suggestion
scope: emphasis
tokens:
- "[^-]+"
# This is strange, but vale would match front matter section
# as italics if I just used a .* pattern

View File

@ -1,7 +0,0 @@
extends: occurrence
message: "Try to keep link text short (< 5 words)."
scope: link
link: https://docs.docker.com/contribute/style/formatting/#links
level: suggestion
max: 5
token: \b(\w+)\b

View File

@ -1,8 +0,0 @@
extends: existence
message: "Don't use end punctuation in links."
link: https://docs.docker.com/contribute/style/formatting/#links
nonword: true
level: warning
scope: link
tokens:
- '[a-z0-9][.?!](?:\s|$)'

View File

@ -4,4 +4,4 @@ scope: sentence
level: suggestion level: suggestion
nonword: true nonword: true
tokens: tokens:
- '(?:[^\s,]+,){1,} \w+ (?:and|or) \w+[.?!]' - '(?:[^\s,]+,){1,}\s\w+\s(?:and|or)\s\w+[.?!]'

View File

@ -6,4 +6,3 @@ match: $sentence
exceptions: exceptions:
- Vocab/Docker/accept.txt - Vocab/Docker/accept.txt
- Vocab/Technology/accept.txt - Vocab/Technology/accept.txt
- Vocab/Industry/accept.txt

View File

@ -6,11 +6,19 @@ level: suggestion
action: action:
name: replace name: replace
swap: swap:
'(?<!Docker)\s Hub': Docker Hub
'(?<!Docker)\sScout': Docker Scout
k8s: Kubernetes
'\b(?:eg|e\.g\.)[\s,]': for example
'\b(?:ie|i\.e\.)[\s,]': that is
(?:account name|accountname|user name): username
(?:drop down|dropdown): drop-down
(?:log out|logout): sign out
(?:sign on|log on|log in|logon|login): sign in
above: previous above: previous
adaptor: adapter adaptor: adapter
(?:account name|accountname|user name): username
administrate: administer
admin: administrator admin: administrator
administrate: administer
afterwards: afterward afterwards: afterward
allow: let allow: let
allows: lets allows: lets
@ -28,24 +36,20 @@ swap:
click: select click: select
deselect: clear deselect: clear
disable: turn off|toggle off disable: turn off|toggle off
(?:drop down|dropdown): drop-down
'\b(?:eg|e\.g\.)[\s,]': for example
enable: turn on|toggle on enable: turn on|toggle on
ergo: therefore ergo: therefore
execute: run execute: run
gb: GB gb: GB
gbps: Gbps gbps: Gbps
'\b(?:ie|i\.e\.)[\s,]': that is
kb: KB kb: KB
keypress: keystroke keypress: keystroke
(?:log out|logout): sign out
mb: MB mb: MB
mutices: mutexes mutices: mutexes
paas: PaaS paas: PaaS
pb: PB pb: PB
repo: repository repo: repository
scan: analyze
scroll: navigate scroll: navigate
(?:sign on|log on|log in|logon|login): sign in
tb: TB tb: TB
vs: versus vs: versus
wish: want wish: want

View File

@ -1,12 +0,0 @@
extends: substitution
message: "Consider using '%s' instead of '%s'"
link: https://docs.docker.com/contribute/style/terminology/
level: suggestion
action:
name: replace
swap:
'(?<!Docker )[Hh]ub': Docker Hub
'(?<!Docker )[Ss]cout': Docker Scout
scan: analyze
Scan: Analyze
'[Kk]8[Ss]': Kubernetes

View File

@ -1,74 +0,0 @@
ARM
AWS
Amazon
Ambassador
Anchore
Apple
Artifactory
Azure( Blob Storage)?
BusyBox
CentOS
Ceph
CloudFront
CNCF
Codefresh
CouchDB
Couchbase
Ddosify
Django
Fargate
Fedora
Flink
Gefyra
GeoNetwork
GitHub( Actions)?
Google
Intel
JFrog
JetBrains
Kubernetes
LTS
Lightstreamer
Linux
Logstash
Mac
Mail(chimp|gun)
Microsoft
MySQL
Nginx
Nuxeo
OAuth
OCI
Okta
Postgres
PowerShell
Python
QEMU
RHEL
Raspbian
S3
SBOMs?
SLES
SLSA
SPDX
SQLite
Slack
Snyk
Solr
SonarQube
Syft
Telepresence
TLS
Twilio
Ubuntu
WSL
Wasm
Windows
XWiki
Zsh
kubefwd
ktunnel
macOS
minikube
sandbox
sandboxed

View File

@ -1,27 +1,94 @@
APIs? APIs?
ARM
AWS
Amazon
Ambassador
Anchore
Apple
Artifactory
Azure( Blob Storage)?
BusyBox
CNCF
CVEs? CVEs?
CentOS
Ceph
CloudFront
Codefresh
CouchDB
Couchbase
DHCP DHCP
DNS DNS
Ddosify
Django
Ethernet Ethernet
Fargate
Fedora
Flink
GPG GPG
GRUB GRUB
GeoNetwork
Git Git
GitHub( Actions)?
Google
HTTP HTTP
IPs? IPs?
IPv[46] IPv[46]
IPvlan IPvlan
Intel
JFrog
JPEG JPEG
JetBrains
Kubernetes
LTS
Lightstreamer
Linux
Logstash
MAC MAC
RPM Mac
Mail(chimp|gun)
Microsoft
MySQL
Nginx
Nuxeo
OAuth
OCI
Okta
PNG PNG
Postgres
PowerShell
Python
QEMU
RHEL
RPM
Raspbian
S3
SARIF SARIF
SBOMs?
SDKs? SDKs?
SLES
SLSA
SPDX
SQLite
SSO SSO
Slack
Snyk
Solr
SonarQube
Syft
TCP TCP
TLS
Telepresence
Twilio
UDP UDP
Ubuntu
Unix Unix
VLAN VLAN
VM VM
WSL
Wasm
Windows
XWiki
Zsh
[Ll]oopback [Ll]oopback
[Nn]ameserver [Nn]ameserver
[Nn]amespace [Nn]amespace
@ -31,18 +98,21 @@ containerd
deserialization deserialization
deserialize deserialize
filepath filepath
firewalld
filetype filetype
firewalld
glibc glibc
goroutine goroutine
hostname hostname
inotify inotify
iptables iptables
kubectl kubectl
kubefwd
kubelet kubelet
lookup lookup
macOS
macvlan macvlan
mfsymlinks mfsymlinks
minikube
musl musl
osquery osquery
osxfs osxfs
@ -51,6 +121,7 @@ proxying
real-time real-time
runc runc
runtime runtime
sandbox(ed)?
stdin stdin
stdout stdout
subnet subnet

View File

@ -1,9 +1,9 @@
StylesPath = .github/vale StylesPath = .github/vale
MinAlertLevel = suggestion MinAlertLevel = suggestion
Vocab = Docker, Industry, Technology Vocab = Docker, Technology
Packages = Hugo
[*.md] [*.md]
BasedOnStyles = Vale, Docker BasedOnStyles = Vale, Docker
TokenIgnores = ({%.*%}), \
({:(?:.|\n)*?})