diff --git a/.github/workflows/vale-lint-action.yml b/.github/workflows/vale-lint-action.yml new file mode 100644 index 00000000..e9ce91c9 --- /dev/null +++ b/.github/workflows/vale-lint-action.yml @@ -0,0 +1,37 @@ +name: Check Docusaurus docs with Vale linter + +on: [pull_request] + +jobs: + vale: + name: Vale doc linter + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v4.1.1 + + # Set up Vale Action + - uses: errata-ai/vale-action@v2.1.1 + with: + # Filter mode can be set to: added, diff_context, file, nofilter + filter_mode: nofilter + # Set the reporter to display the output: github-pr-check, github-pr-review, github-check + reporter: github-pr-check + # Fails the action if there are errors + fail_on_error: true + # Lint the files in the "versioned_docs/version-2.0.0/" directory + files: 'versioned_docs/version-2.0.0/**/*.md' + # Specify the Vale version + version: 3.0.3 + env: + # GitHub token for authentication, automatically set by GitHub Actions + GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}} + + # Ensure that the Vale styles are set correctly + - name: Set up Vale styles + run: | + mkdir -p ~/.vale/styles + cp -r vale_styles/* ~/.vale/styles/ + + # Run Vale Linter without generating a .txt file + - name: Run Vale Linter + run: vale --config=.vale.ini 'versioned_docs/version-2.0.0/**/*.md' diff --git a/.vale.ini b/.vale.ini new file mode 100644 index 00000000..3bb7088a --- /dev/null +++ b/.vale.ini @@ -0,0 +1,25 @@ +# vale.ini + +StylesPath = vale_styles # Update this path to where your styles are stored. +MinAlertLevel = error # Set the minimum alert level to display (suggestion, warning, or error). +Vocab = Base + +[*.md] +# Enable Markdown-specific styles. +BasedOnStyles = Vale, Google + +# Customize specific rules based on your needs. +List.Capitalization = YES + +# Override some rules: +Vale.Spelling = YES +Google.PassiveVoice = NO # Disable passive voice rule if unnecessary +Google.We = NO # Disable first-person plural flagging +Google.Will = NO # Allow "will" usage +Google.Exclamation = NO # Allow exclamation points +Google.Ellipses = NO # Allow ellipses in text +Google.Latin = NO # Allow "e.g." and "i.e." instead of "for example" + +# Allow specific terms: +Vale.Terms=NO + diff --git a/vale-output.txt b/vale-output.txt new file mode 100644 index 00000000..926ef952 --- /dev/null +++ b/vale-output.txt @@ -0,0 +1,362 @@ + + versioned_docs/version-2.0.0/ci-cd/github.md + 24:257 error Did you really mean 'yout'? Vale.Spelling + 24:296 error Did you really mean 'worflow'? Vale.Spelling + 125:240 error Did you really mean 'unde'? Vale.Spelling + 126:240 error Did you really mean 'unde'? Vale.Spelling + + + versioned_docs/version-2.0.0/ci-cd/jenkins.md + 22:3 error Did you really mean 'Sudo'? Vale.Spelling + 24:56 error Did you really mean 'sudoers'? Vale.Spelling + + + versioned_docs/version-2.0.0/concepts/installation.md + 67:3 error Did you really mean 'Wohoo'? Vale.Spelling + 101:3 error Did you really mean Vale.Spelling + 'Prequisites'? + + + versioned_docs/version-2.0.0/concepts/reference/glossary/ai-test-completion.md + 16:41 error Did you really mean 'LLM's'? Vale.Spelling + + + versioned_docs/version-2.0.0/concepts/reference/glossary/black-box-testing.md + 56:4 error Did you really mean 'Whate'? Vale.Spelling + 67:73 error Did you really mean Vale.Spelling + 'invaliduser'? + + + versioned_docs/version-2.0.0/concepts/reference/glossary/cucumber-testing.md + 78:5 error Did you really mean Vale.Spelling + 'Reusability'? + 92:4 error Did you really mean 'Behat'? Vale.Spelling + + + versioned_docs/version-2.0.0/concepts/reference/glossary/functional-testing.md + 196:98 error Did you really mean Vale.Spelling + 'anonymized'? + + + versioned_docs/version-2.0.0/concepts/reference/glossary/integration-testing.md + 147:155 error Did you really mean 'PHPUnit'? Vale.Spelling + + + versioned_docs/version-2.0.0/concepts/reference/glossary/manual-testing.md + 48:3 error Did you really mean Vale.Spelling + 'Reusability'? + + + versioned_docs/version-2.0.0/concepts/reference/glossary/software-testing-life-cycle.md + 70:24 error Did you really mean Vale.Spelling + 'accelrating'? + + + versioned_docs/version-2.0.0/concepts/reference/glossary/stubs.md + 47:20 error Did you really mean Vale.Spelling + 'Challeges'? + + + versioned_docs/version-2.0.0/concepts/reference/glossary/unit-test-automation.md + 46:3 error Did you really mean 'RSpec'? Vale.Spelling + 46:17 error Did you really mean 'RSpec'? Vale.Spelling + 46:195 error Did you really mean 'RSpec'? Vale.Spelling + 48:280 error Did you really mean 'Chai'? Vale.Spelling + + + versioned_docs/version-2.0.0/concepts/reference/glossary/unit-testing.md + 44:3 error Did you really mean 'PHPUnit'? Vale.Spelling + 67:86 error Did you really mean 'PHPUnit'? Vale.Spelling + 109:103 error Did you really mean 'PHPUnit'? Vale.Spelling + + + versioned_docs/version-2.0.0/concepts/reference/glossary/white-box-testing.md + 103:19 error Did you really mean Vale.Spelling + 'Whitebox'? + 117:6 error Did you really mean Vale.Spelling + 'ontinuous'? + + + versioned_docs/version-2.0.0/concepts/what-are-keploy-features.md + 59:1 error Did you really mean 'shopify'? Vale.Spelling + + + versioned_docs/version-2.0.0/dependencies/http.md + 38:5 error Did you really mean 'http'? Vale.Spelling + 42:386 error Did you really mean 'respnse'? Vale.Spelling + + + versioned_docs/version-2.0.0/dependencies/mongo.md + 25:32 error Did you really mean Vale.Spelling + 'wiremessage'? + 54:260 error Did you really mean Vale.Spelling + 'isMaster'? + + + versioned_docs/version-2.0.0/gsoc/contribution-guide.md + 86:9 error Did you really mean Vale.Spelling + 'Autogenerate'? + + + versioned_docs/version-2.0.0/hacktoberfest/contribution-guide.md + 23:11 error Did you really mean Vale.Spelling + 'Contributribution'? + + + versioned_docs/version-2.0.0/keploy-cloud/deduplication.md + 45:5 error 'the' is repeated! Vale.Repetition + 45:55 error Did you really mean 'js'? Vale.Spelling + 61:128 error Did you really mean 'dedup'? Vale.Spelling + 176:113 error Did you really mean 'dedup'? Vale.Spelling + + + versioned_docs/version-2.0.0/keploy-cloud/keploy-console.md + 71:93 error Did you really mean 'param'? Vale.Spelling + + + versioned_docs/version-2.0.0/keploy-cloud/mock-registry.md + 18:182 error Did you really mean Vale.Spelling + 'performant'? + + + versioned_docs/version-2.0.0/keploy-cloud/testgeneration.md + 419:46 error 'create' is repeated! Vale.Repetition + + + versioned_docs/version-2.0.0/keploy-cloud/time-freezing.md + 49:13 error 'the' is repeated! Vale.Repetition + + + versioned_docs/version-2.0.0/keploy-explained/debugger-guide.md + 93:78 error Did you really mean 'args'? Vale.Spelling + + + versioned_docs/version-2.0.0/keploy-explained/dev-guide.md + 51:29 error Did you really mean 'repo'? Vale.Spelling + + + versioned_docs/version-2.0.0/keploy-explained/docs-dev-guide.md + 23:45 error Did you really mean 'repo'? Vale.Spelling + 32:32 error Did you really mean 'repo'? Vale.Spelling + 32:176 error Did you really mean 'repo'? Vale.Spelling + 147:41 error Did you really mean 'repo'? Vale.Spelling + + + versioned_docs/version-2.0.0/keploy-explained/faq.md + 22:12 error Did you really mean 'nada'? Vale.Spelling + 32:71 error Did you really mean 'eg'? Vale.Spelling + + + versioned_docs/version-2.0.0/keploy-explained/mac-linux.md + 7:52 error Did you really mean 'linux'? Vale.Spelling + 7:58 error Did you really mean 'env'? Vale.Spelling + 38:41 error Did you really mean 'Zsh'? Vale.Spelling + 44:12 error Did you really mean 'zsh'? Vale.Spelling + 44:157 error Did you really mean Vale.Spelling + 'globbing'? + 58:55 error Did you really mean 'zsh'? Vale.Spelling + 101:19 error Did you really mean 'sudoers'? Vale.Spelling + + + versioned_docs/version-2.0.0/keploy-explained/testing-guide.md + 72:151 error Spell out all ordinal numbers Google.Ordinal + ('4th') in text. + 138:102 error Did you really mean Vale.Spelling + 'hardcoded'? + + + versioned_docs/version-2.0.0/keploy-explained/why-keploy.md + 31:127 error Don't put a space before or Google.EmDash + after a dash. + 31:128 error Use an em dash ('—') instead Google.EnDash + of '–'. + + + versioned_docs/version-2.0.0/operation/browser-extension.md + 59:34 error Put a nonbreaking space Google.Units + between the number and the + unit in '1s'. + 59:34 error Spell out all ordinal numbers Google.Ordinal + ('1st') in text. + 78:71 error Did you really mean 'oss'? Vale.Spelling + 91:49 error Did you really mean 'moc'? Vale.Spelling + + + versioned_docs/version-2.0.0/operation/record.md + 22:5 error Did you really mean 'KTest'? Vale.Spelling + + + versioned_docs/version-2.0.0/operation/test.md + 12:8 error Did you really mean 'KTests'? Vale.Spelling + + + versioned_docs/version-2.0.0/quickstart/express-postgresql-prisma.md + 23:167 error Did you really mean 'Prisma'? Vale.Spelling + 130:8 error Did you really mean Vale.Spelling + 'walkthrough'? + + + versioned_docs/version-2.0.0/quickstart/flask-redis.md + 126:47 error Did you really mean 'cli'? Vale.Spelling + + + versioned_docs/version-2.0.0/quickstart/go-mux-mysql.md + 25:75 error Did you really mean 'Mux'? Vale.Spelling + + + versioned_docs/version-2.0.0/quickstart/go-mux-sql.md + 25:34 error Did you really mean 'catelog'? Vale.Spelling + 25:89 error Did you really mean 'Mux'? Vale.Spelling + 372:87 error Did you really mean 'Mux'? Vale.Spelling + + + versioned_docs/version-2.0.0/quickstart/java-spring-postgres.md + 28:11 error Did you really mean Vale.Spelling + 'petclinic'? + 149:163 error Put a nonbreaking space Google.Units + between the number and the + unit in '10s'. + + + versioned_docs/version-2.0.0/quickstart/node-express-mongoose.md + 45:31 error Did you really mean 'mongoDb'? Vale.Spelling + + + versioned_docs/version-2.0.0/quickstart/node-jwt-sql.md + 178:54 error Did you really mean 'mins'? Vale.Spelling + 178:109 error Put a nonbreaking space Google.Units + between the number and the + unit in '10min'. + 179:54 error Did you really mean 'mins'? Vale.Spelling + 179:109 error Put a nonbreaking space Google.Units + between the number and the + unit in '10min'. + 322:54 error Did you really mean 'mins'? Vale.Spelling + 322:109 error Put a nonbreaking space Google.Units + between the number and the + unit in '10min'. + + + versioned_docs/version-2.0.0/quickstart/sample-rust-crud-mongo.md + 71:56 error Did you really mean 'VSCode'? Vale.Spelling + 98:4 error Did you really mean Vale.Spelling + 'peformed'? + + + versioned_docs/version-2.0.0/quickstart/sample-ts.md + 122:31 error Did you really mean 'yaml'? Vale.Spelling + + + versioned_docs/version-2.0.0/quickstart/samples-echo.md + 130:1 error Commas and periods go inside Google.Quotes + quotation marks. + 179:4 error Did you really mean Vale.Spelling + 'genereate'? + + + versioned_docs/version-2.0.0/quickstart/samples-express-mongoose.md + 41:41 error Did you really mean 'mongodb'? Vale.Spelling + 45:78 error Did you really mean 'mongodb'? Vale.Spelling + + + versioned_docs/version-2.0.0/quickstart/samples-go-gin-mongo.md + 24:30 error Did you really mean Vale.Spelling + 'shorteners'? + 42:31 error Did you really mean 'mongoDb'? Vale.Spelling + + + versioned_docs/version-2.0.0/quickstart/samples-go-sse-svelte.md + 47:49 error Did you really mean 'mongodb'? Vale.Spelling + 62:18 error Did you really mean Vale.Spelling + 'applicaiton'? + + + versioned_docs/version-2.0.0/quickstart/samples-java.md + 58:27 error Did you really mean 'sudo'? Vale.Spelling + + + versioned_docs/version-2.0.0/quickstart/samples-node-mongo.md + 24:4 error Did you really mean Vale.Spelling + 'Intoduction'? + 43:3 error Did you really mean 'Wohoo'? Vale.Spelling + + + versioned_docs/version-2.0.0/quickstart/sanic-mongo.md + 29:73 error Did you really mean 'Sanic'? Vale.Spelling + 71:21 error Did you really mean 'sanic'? Vale.Spelling + 161:67 error Did you really mean 'Sanic'? Vale.Spelling + + + versioned_docs/version-2.0.0/running-keploy/cli-commands.md + 55:82 error Commas and periods go inside Google.Quotes + quotation marks. + 110:200 error Did you really mean 'yaml'? Vale.Spelling + 134:82 error Commas and periods go inside Google.Quotes + quotation marks. + 154:111 error Commas and periods go inside Google.Quotes + quotation marks. + 250:34 error Did you really mean 'llm'? Vale.Spelling + 254:40 error Did you really mean 'llm'? Vale.Spelling + 290:110 error Don't use plurals in Google.OptionalPlurals + parentheses such as in + 'testset(s)'. + 326:120 error Commas and periods go inside Google.Quotes + quotation marks. + + + versioned_docs/version-2.0.0/running-keploy/docker-tls.md + 50:101 error Did you really mean 'KTests'? Vale.Spelling + + + versioned_docs/version-2.0.0/running-keploy/keploy-passthrough.md + 19:11 error Did you really mean Vale.Spelling + 'Passthrough'? + + + versioned_docs/version-2.0.0/running-keploy/keploy-templatize.md + 17:1 error Did you really mean 'eg'? Vale.Spelling + 19:477 error Did you really mean Vale.Spelling + 'subequent'? + 29:106 error Did you really mean 'testset'? Vale.Spelling + + + versioned_docs/version-2.0.0/running-keploy/rename-testcases.md + 37:144 error Did you really mean Vale.Spelling + 'renametest'? + + + versioned_docs/version-2.0.0/running-keploy/unit-test-generator.md + 41:25 error Did you really mean 'litellm'? Vale.Spelling + 52:61 error Did you really mean Vale.Spelling + 'coberuta'? + 124:16 error Did you really mean Vale.Spelling + 'dependecies'? + 124:102 error Did you really mean 'dommand'? Vale.Spelling + 159:279 error Did you really mean 'litellm'? Vale.Spelling + + + versioned_docs/version-2.0.0/server/linux/installation.md + 37:42 error Did you really mean 'linux'? Vale.Spelling + + + versioned_docs/version-2.0.0/server/macos/installation.md + 110:100 error Did you really mean 'KTests'? Vale.Spelling + + + versioned_docs/version-2.0.0/server/sdk-installation/java.md + 31:60 error Did you really mean Vale.Spelling + 'subcommand'? + + + versioned_docs/version-2.0.0/server/sdk-installation/javascript.md + 32:8 error Did you really mean Vale.Spelling + 'javascript'? + 32:27 error Did you really mean 'nyc'? Vale.Spelling + + + versioned_docs/version-2.0.0/server/sdk-installation/python.md + 35:106 error Did you really mean 'becuase'? Vale.Spelling + 35:245 error Did you really mean Vale.Spelling + 'overwritting'? + +✖ 126 errors, 0 warnings and 0 suggestions in 113 files. diff --git a/vale_styles/Google/AMPM.yml b/vale_styles/Google/AMPM.yml new file mode 100644 index 00000000..fbdc6e4f --- /dev/null +++ b/vale_styles/Google/AMPM.yml @@ -0,0 +1,9 @@ +extends: existence +message: "Use 'AM' or 'PM' (preceded by a space)." +link: 'https://developers.google.com/style/word-list' +level: error +nonword: true +tokens: + - '\d{1,2}[AP]M' + - '\d{1,2} ?[ap]m' + - '\d{1,2} ?[aApP]\.[mM]\.' diff --git a/vale_styles/Google/Acronyms.yml b/vale_styles/Google/Acronyms.yml new file mode 100644 index 00000000..f41af018 --- /dev/null +++ b/vale_styles/Google/Acronyms.yml @@ -0,0 +1,64 @@ +extends: conditional +message: "Spell out '%s', if it's unfamiliar to the audience." +link: 'https://developers.google.com/style/abbreviations' +level: suggestion +ignorecase: false +# Ensures that the existence of 'first' implies the existence of 'second'. +first: '\b([A-Z]{3,5})\b' +second: '(?:\b[A-Z][a-z]+ )+\(([A-Z]{3,5})\)' +# ... with the exception of these: +exceptions: + - API + - ASP + - CLI + - CPU + - CSS + - CSV + - DEBUG + - DOM + - DPI + - FAQ + - GCC + - GDB + - GET + - GPU + - GTK + - GUI + - HTML + - HTTP + - HTTPS + - IDE + - JAR + - JSON + - JSX + - LESS + - LLDB + - NET + - NOTE + - NVDA + - OSS + - PATH + - PDF + - PHP + - POST + - RAM + - REPL + - RSA + - SCM + - SCSS + - SDK + - SQL + - SSH + - SSL + - SVG + - TBD + - TCP + - TODO + - URI + - URL + - USB + - UTF + - XML + - XSS + - YAML + - ZIP diff --git a/vale_styles/Google/Colons.yml b/vale_styles/Google/Colons.yml new file mode 100644 index 00000000..99363fbd --- /dev/null +++ b/vale_styles/Google/Colons.yml @@ -0,0 +1,8 @@ +extends: existence +message: "'%s' should be in lowercase." +link: 'https://developers.google.com/style/colons' +nonword: true +level: warning +scope: sentence +tokens: + - ':\s[A-Z]' diff --git a/vale_styles/Google/Contractions.yml b/vale_styles/Google/Contractions.yml new file mode 100644 index 00000000..95234987 --- /dev/null +++ b/vale_styles/Google/Contractions.yml @@ -0,0 +1,30 @@ +extends: substitution +message: "Feel free to use '%s' instead of '%s'." +link: 'https://developers.google.com/style/contractions' +level: suggestion +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 + should not: shouldn't + that is: that's + they are: they're + was not: wasn't + we are: we're + we have: we've + were not: weren't + what is: what's + when is: when's + where is: where's + will not: won't diff --git a/vale_styles/Google/DateFormat.yml b/vale_styles/Google/DateFormat.yml new file mode 100644 index 00000000..e9d227fa --- /dev/null +++ b/vale_styles/Google/DateFormat.yml @@ -0,0 +1,9 @@ +extends: existence +message: "Use 'July 31, 2016' format, not '%s'." +link: 'https://developers.google.com/style/dates-times' +ignorecase: true +level: error +nonword: true +tokens: + - '\d{1,2}(?:\.|/)\d{1,2}(?:\.|/)\d{4}' + - '\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}' diff --git a/vale_styles/Google/Ellipses.yml b/vale_styles/Google/Ellipses.yml new file mode 100644 index 00000000..1e070517 --- /dev/null +++ b/vale_styles/Google/Ellipses.yml @@ -0,0 +1,9 @@ +extends: existence +message: "In general, don't use an ellipsis." +link: 'https://developers.google.com/style/ellipses' +nonword: true +level: warning +action: + name: remove +tokens: + - '\.\.\.' diff --git a/vale_styles/Google/EmDash.yml b/vale_styles/Google/EmDash.yml new file mode 100644 index 00000000..1befe72a --- /dev/null +++ b/vale_styles/Google/EmDash.yml @@ -0,0 +1,12 @@ +extends: existence +message: "Don't put a space before or after a dash." +link: 'https://developers.google.com/style/dashes' +nonword: true +level: error +action: + name: edit + params: + - remove + - ' ' +tokens: + - '\s[—–]\s' diff --git a/vale_styles/Google/EnDash.yml b/vale_styles/Google/EnDash.yml new file mode 100644 index 00000000..b314dc4e --- /dev/null +++ b/vale_styles/Google/EnDash.yml @@ -0,0 +1,13 @@ +extends: existence +message: "Use an em dash ('—') instead of '–'." +link: 'https://developers.google.com/style/dashes' +nonword: true +level: error +action: + name: edit + params: + - replace + - '-' + - '—' +tokens: + - '–' diff --git a/vale_styles/Google/Exclamation.yml b/vale_styles/Google/Exclamation.yml new file mode 100644 index 00000000..3e15181b --- /dev/null +++ b/vale_styles/Google/Exclamation.yml @@ -0,0 +1,7 @@ +extends: existence +message: "Don't use exclamation points in text." +link: 'https://developers.google.com/style/exclamation-points' +nonword: true +level: error +tokens: + - '\w!(?:\s|$)' diff --git a/vale_styles/Google/FirstPerson.yml b/vale_styles/Google/FirstPerson.yml new file mode 100644 index 00000000..0b7b8828 --- /dev/null +++ b/vale_styles/Google/FirstPerson.yml @@ -0,0 +1,13 @@ +extends: existence +message: "Avoid first-person pronouns such as '%s'." +link: 'https://developers.google.com/style/pronouns#personal-pronouns' +ignorecase: true +level: warning +nonword: true +tokens: + - (?:^|\s)I\s + - (?:^|\s)I,\s + - \bI'm\b + - \bme\b + - \bmy\b + - \bmine\b diff --git a/vale_styles/Google/Gender.yml b/vale_styles/Google/Gender.yml new file mode 100644 index 00000000..c8486181 --- /dev/null +++ b/vale_styles/Google/Gender.yml @@ -0,0 +1,9 @@ +extends: existence +message: "Don't use '%s' as a gender-neutral pronoun." +link: 'https://developers.google.com/style/pronouns#gender-neutral-pronouns' +level: error +ignorecase: true +tokens: + - he/she + - s/he + - \(s\)he diff --git a/vale_styles/Google/GenderBias.yml b/vale_styles/Google/GenderBias.yml new file mode 100644 index 00000000..261cfb66 --- /dev/null +++ b/vale_styles/Google/GenderBias.yml @@ -0,0 +1,45 @@ +extends: substitution +message: "Consider using '%s' instead of '%s'." +link: 'https://developers.google.com/style/inclusive-documentation' +ignorecase: true +level: error +swap: + (?:alumna|alumnus): graduate + (?:alumnae|alumni): graduates + air(?:m[ae]n|wom[ae]n): pilot(s) + anchor(?:m[ae]n|wom[ae]n): anchor(s) + authoress: author + camera(?:m[ae]n|wom[ae]n): camera operator(s) + chair(?:m[ae]n|wom[ae]n): chair(s) + congress(?:m[ae]n|wom[ae]n): member(s) of congress + door(?:m[ae]|wom[ae]n): concierge(s) + draft(?:m[ae]n|wom[ae]n): drafter(s) + fire(?:m[ae]n|wom[ae]n): firefighter(s) + fisher(?:m[ae]n|wom[ae]n): fisher(s) + fresh(?:m[ae]n|wom[ae]n): first-year student(s) + garbage(?:m[ae]n|wom[ae]n): waste collector(s) + lady lawyer: lawyer + ladylike: courteous + landlord: building manager + mail(?:m[ae]n|wom[ae]n): mail carriers + man and wife: husband and wife + man enough: strong enough + mankind: human kind + manmade: manufactured + manpower: personnel + men and girls: men and women + middle(?:m[ae]n|wom[ae]n): intermediary + news(?:m[ae]n|wom[ae]n): journalist(s) + ombuds(?:man|woman): ombuds + oneupmanship: upstaging + poetess: poet + police(?:m[ae]n|wom[ae]n): police officer(s) + repair(?:m[ae]n|wom[ae]n): technician(s) + sales(?:m[ae]n|wom[ae]n): salesperson or sales people + service(?:m[ae]n|wom[ae]n): soldier(s) + steward(?:ess)?: flight attendant + tribes(?:m[ae]n|wom[ae]n): tribe member(s) + waitress: waiter + woman doctor: doctor + woman scientist[s]?: scientist(s) + work(?:m[ae]n|wom[ae]n): worker(s) diff --git a/vale_styles/Google/HeadingPunctuation.yml b/vale_styles/Google/HeadingPunctuation.yml new file mode 100644 index 00000000..b538be5b --- /dev/null +++ b/vale_styles/Google/HeadingPunctuation.yml @@ -0,0 +1,13 @@ +extends: existence +message: "Don't put a period at the end of a heading." +link: 'https://developers.google.com/style/capitalization#capitalization-in-titles-and-headings' +nonword: true +level: warning +scope: heading +action: + name: edit + params: + - remove + - '.' +tokens: + - '[a-z0-9][.]\s*$' diff --git a/vale_styles/Google/Headings.yml b/vale_styles/Google/Headings.yml new file mode 100644 index 00000000..a5330133 --- /dev/null +++ b/vale_styles/Google/Headings.yml @@ -0,0 +1,29 @@ +extends: capitalization +message: "'%s' should use sentence-style capitalization." +link: 'https://developers.google.com/style/capitalization#capitalization-in-titles-and-headings' +level: warning +scope: heading +match: $sentence +indicators: + - ':' +exceptions: + - Azure + - CLI + - Code + - Cosmos + - Docker + - Emmet + - gRPC + - I + - Kubernetes + - Linux + - macOS + - Marketplace + - MongoDB + - REPL + - Studio + - TypeScript + - URLs + - Visual + - VS + - Windows diff --git a/vale_styles/Google/Latin.yml b/vale_styles/Google/Latin.yml new file mode 100644 index 00000000..d91700de --- /dev/null +++ b/vale_styles/Google/Latin.yml @@ -0,0 +1,11 @@ +extends: substitution +message: "Use '%s' instead of '%s'." +link: 'https://developers.google.com/style/abbreviations' +ignorecase: true +level: error +nonword: true +action: + name: replace +swap: + '\b(?:eg|e\.g\.)[\s,]': for example + '\b(?:ie|i\.e\.)[\s,]': that is diff --git a/vale_styles/Google/LyHyphens.yml b/vale_styles/Google/LyHyphens.yml new file mode 100644 index 00000000..ac8f557a --- /dev/null +++ b/vale_styles/Google/LyHyphens.yml @@ -0,0 +1,14 @@ +extends: existence +message: "'%s' doesn't need a hyphen." +link: 'https://developers.google.com/style/hyphens' +level: error +ignorecase: false +nonword: true +action: + name: edit + params: + - replace + - '-' + - ' ' +tokens: + - '\s[^\s-]+ly-' diff --git a/vale_styles/Google/OptionalPlurals.yml b/vale_styles/Google/OptionalPlurals.yml new file mode 100644 index 00000000..f858ea6f --- /dev/null +++ b/vale_styles/Google/OptionalPlurals.yml @@ -0,0 +1,12 @@ +extends: existence +message: "Don't use plurals in parentheses such as in '%s'." +link: 'https://developers.google.com/style/plurals-parentheses' +level: error +nonword: true +action: + name: edit + params: + - remove + - '(s)' +tokens: + - '\b\w+\(s\)' diff --git a/vale_styles/Google/Ordinal.yml b/vale_styles/Google/Ordinal.yml new file mode 100644 index 00000000..d1ac7d27 --- /dev/null +++ b/vale_styles/Google/Ordinal.yml @@ -0,0 +1,7 @@ +extends: existence +message: "Spell out all ordinal numbers ('%s') in text." +link: 'https://developers.google.com/style/numbers' +level: error +nonword: true +tokens: + - \d+(?:st|nd|rd|th) diff --git a/vale_styles/Google/OxfordComma.yml b/vale_styles/Google/OxfordComma.yml new file mode 100644 index 00000000..b9ba21eb --- /dev/null +++ b/vale_styles/Google/OxfordComma.yml @@ -0,0 +1,7 @@ +extends: existence +message: "Use the Oxford comma in '%s'." +link: 'https://developers.google.com/style/commas' +scope: sentence +level: warning +tokens: + - '(?:[^,]+,){1,}\s\w+\s(?:and|or)' diff --git a/vale_styles/Google/Parens.yml b/vale_styles/Google/Parens.yml new file mode 100644 index 00000000..3b8711d0 --- /dev/null +++ b/vale_styles/Google/Parens.yml @@ -0,0 +1,7 @@ +extends: existence +message: "Use parentheses judiciously." +link: 'https://developers.google.com/style/parentheses' +nonword: true +level: suggestion +tokens: + - '\(.+\)' diff --git a/vale_styles/Google/Passive.yml b/vale_styles/Google/Passive.yml new file mode 100644 index 00000000..3265890e --- /dev/null +++ b/vale_styles/Google/Passive.yml @@ -0,0 +1,184 @@ +extends: existence +link: 'https://developers.google.com/style/voice' +message: "In general, use active voice instead of passive voice ('%s')." +ignorecase: true +level: suggestion +raw: + - \b(am|are|were|being|is|been|was|be)\b\s* +tokens: + - '[\w]+ed' + - awoken + - beat + - become + - been + - begun + - bent + - beset + - bet + - bid + - bidden + - bitten + - bled + - blown + - born + - bought + - bound + - bred + - broadcast + - broken + - brought + - built + - burnt + - burst + - cast + - caught + - chosen + - clung + - come + - cost + - crept + - cut + - dealt + - dived + - done + - drawn + - dreamt + - driven + - drunk + - dug + - eaten + - fallen + - fed + - felt + - fit + - fled + - flown + - flung + - forbidden + - foregone + - forgiven + - forgotten + - forsaken + - fought + - found + - frozen + - given + - gone + - gotten + - ground + - grown + - heard + - held + - hidden + - hit + - hung + - hurt + - kept + - knelt + - knit + - known + - laid + - lain + - leapt + - learnt + - led + - left + - lent + - let + - lighted + - lost + - made + - meant + - met + - misspelt + - mistaken + - mown + - overcome + - overdone + - overtaken + - overthrown + - paid + - pled + - proven + - put + - quit + - read + - rid + - ridden + - risen + - run + - rung + - said + - sat + - sawn + - seen + - sent + - set + - sewn + - shaken + - shaven + - shed + - shod + - shone + - shorn + - shot + - shown + - shrunk + - shut + - slain + - slept + - slid + - slit + - slung + - smitten + - sold + - sought + - sown + - sped + - spent + - spilt + - spit + - split + - spoken + - spread + - sprung + - spun + - stolen + - stood + - stridden + - striven + - struck + - strung + - stuck + - stung + - stunk + - sung + - sunk + - swept + - swollen + - sworn + - swum + - swung + - taken + - taught + - thought + - thrived + - thrown + - thrust + - told + - torn + - trodden + - understood + - upheld + - upset + - wed + - wept + - withheld + - withstood + - woken + - won + - worn + - wound + - woven + - written + - wrung diff --git a/vale_styles/Google/Periods.yml b/vale_styles/Google/Periods.yml new file mode 100644 index 00000000..d24a6a6c --- /dev/null +++ b/vale_styles/Google/Periods.yml @@ -0,0 +1,7 @@ +extends: existence +message: "Don't use periods with acronyms or initialisms such as '%s'." +link: 'https://developers.google.com/style/abbreviations' +level: error +nonword: true +tokens: + - '\b(?:[A-Z]\.){3,}' diff --git a/vale_styles/Google/Quotes.yml b/vale_styles/Google/Quotes.yml new file mode 100644 index 00000000..3cb6f1ab --- /dev/null +++ b/vale_styles/Google/Quotes.yml @@ -0,0 +1,7 @@ +extends: existence +message: "Commas and periods go inside quotation marks." +link: 'https://developers.google.com/style/quotation-marks' +level: error +nonword: true +tokens: + - '"[^"]+"[.,?]' diff --git a/vale_styles/Google/Ranges.yml b/vale_styles/Google/Ranges.yml new file mode 100644 index 00000000..3ec045e7 --- /dev/null +++ b/vale_styles/Google/Ranges.yml @@ -0,0 +1,7 @@ +extends: existence +message: "Don't add words such as 'from' or 'between' to describe a range of numbers." +link: 'https://developers.google.com/style/hyphens' +nonword: true +level: warning +tokens: + - '(?:from|between)\s\d+\s?-\s?\d+' diff --git a/vale_styles/Google/Semicolons.yml b/vale_styles/Google/Semicolons.yml new file mode 100644 index 00000000..bb8b85b4 --- /dev/null +++ b/vale_styles/Google/Semicolons.yml @@ -0,0 +1,8 @@ +extends: existence +message: "Use semicolons judiciously." +link: 'https://developers.google.com/style/semicolons' +nonword: true +scope: sentence +level: suggestion +tokens: + - ';' diff --git a/vale_styles/Google/Slang.yml b/vale_styles/Google/Slang.yml new file mode 100644 index 00000000..63f4c248 --- /dev/null +++ b/vale_styles/Google/Slang.yml @@ -0,0 +1,11 @@ +extends: existence +message: "Don't use internet slang abbreviations such as '%s'." +link: 'https://developers.google.com/style/abbreviations' +ignorecase: true +level: error +tokens: + - 'tl;dr' + - ymmv + - rtfm + - imo + - fwiw diff --git a/vale_styles/Google/Spacing.yml b/vale_styles/Google/Spacing.yml new file mode 100644 index 00000000..27f7ca2b --- /dev/null +++ b/vale_styles/Google/Spacing.yml @@ -0,0 +1,8 @@ +extends: existence +message: "'%s' should have one space." +link: 'https://developers.google.com/style/sentence-spacing' +level: error +nonword: true +tokens: + - '[a-z][.?!] {2,}[A-Z]' + - '[a-z][.?!][A-Z]' diff --git a/vale_styles/Google/Spelling.yml b/vale_styles/Google/Spelling.yml new file mode 100644 index 00000000..57acb884 --- /dev/null +++ b/vale_styles/Google/Spelling.yml @@ -0,0 +1,8 @@ +extends: existence +message: "In general, use American spelling instead of '%s'." +link: 'https://developers.google.com/style/spelling' +ignorecase: true +level: warning +tokens: + - '(?:\w+)nised?' + - '(?:\w+)logue' diff --git a/vale_styles/Google/Units.yml b/vale_styles/Google/Units.yml new file mode 100644 index 00000000..379fad6b --- /dev/null +++ b/vale_styles/Google/Units.yml @@ -0,0 +1,8 @@ +extends: existence +message: "Put a nonbreaking space between the number and the unit in '%s'." +link: 'https://developers.google.com/style/units-of-measure' +nonword: true +level: error +tokens: + - \d+(?:B|kB|MB|GB|TB) + - \d+(?:ns|ms|s|min|h|d) diff --git a/vale_styles/Google/We.yml b/vale_styles/Google/We.yml new file mode 100644 index 00000000..c7ac7d36 --- /dev/null +++ b/vale_styles/Google/We.yml @@ -0,0 +1,11 @@ +extends: existence +message: "Try to avoid using first-person plural like '%s'." +link: 'https://developers.google.com/style/pronouns#personal-pronouns' +level: warning +ignorecase: true +tokens: + - we + - we'(?:ve|re) + - ours? + - us + - let's diff --git a/vale_styles/Google/Will.yml b/vale_styles/Google/Will.yml new file mode 100644 index 00000000..128a9183 --- /dev/null +++ b/vale_styles/Google/Will.yml @@ -0,0 +1,7 @@ +extends: existence +message: "Avoid using '%s'." +link: 'https://developers.google.com/style/tense' +ignorecase: true +level: warning +tokens: + - will diff --git a/vale_styles/Google/WordList.yml b/vale_styles/Google/WordList.yml new file mode 100644 index 00000000..bb711517 --- /dev/null +++ b/vale_styles/Google/WordList.yml @@ -0,0 +1,80 @@ +extends: substitution +message: "Use '%s' instead of '%s'." +link: 'https://developers.google.com/style/word-list' +level: warning +ignorecase: false +action: + name: replace +swap: + '(?:API Console|dev|developer) key': API key + '(?:cell ?phone|smart ?phone)': phone|mobile phone + '(?:dev|developer|APIs) console': API console + '(?:e-mail|Email|E-mail)': email + '(?:file ?path|path ?name)': path + '(?:kill|terminate|abort)': stop|exit|cancel|end + '(?:OAuth ?2|Oauth)': OAuth 2.0 + '(?:ok|Okay)': OK|okay + '(?:WiFi|wifi)': Wi-Fi + '[\.]+apk': APK + '3\-D': 3D + 'Google (?:I\-O|IO)': Google I/O + 'tap (?:&|and) hold': touch & hold + 'un(?:check|select)': clear + above: preceding + account name: username + action bar: app bar + admin: administrator + Ajax: AJAX + Android device: Android-powered device + android: Android + API explorer: APIs Explorer + application: app + approx\.: approximately + authN: authentication + authZ: authorization + autoupdate: automatically update + cellular data: mobile data + cellular network: mobile network + chapter: documents|pages|sections + check box: checkbox + check: select + CLI: command-line tool + click on: click|click in + Cloud: Google Cloud Platform|GCP + Container Engine: Kubernetes Engine + content type: media type + curated roles: predefined roles + data are: data is + Developers Console: Google API Console|API Console + disabled?: turn off|off + ephemeral IP address: ephemeral external IP address + fewer data: less data + file name: filename + firewalls: firewall rules + functionality: capability|feature + Google account: Google Account + Google accounts: Google Accounts + Googling: search with Google + grayed-out: unavailable + HTTPs: HTTPS + in order to: to + ingest: import|load + k8s: Kubernetes + long press: touch & hold + network IP address: internal IP address + omnibox: address bar + open-source: open source + overview screen: recents screen + regex: regular expression + SHA1: SHA-1|HAS-SHA1 + sign into: sign in to + sign-?on: single sign-on + static IP address: static external IP address + stylesheet: style sheet + synch: sync + tablename: table name + tablet: device + touch: tap + url: URL + vs\.: versus + World Wide Web: web diff --git a/vale_styles/Google/meta.json b/vale_styles/Google/meta.json new file mode 100644 index 00000000..a5da2a84 --- /dev/null +++ b/vale_styles/Google/meta.json @@ -0,0 +1,4 @@ +{ + "feed": "https://github.com/errata-ai/Google/releases.atom", + "vale_version": ">=1.0.0" +} diff --git a/vale_styles/Google/vocab.txt b/vale_styles/Google/vocab.txt new file mode 100644 index 00000000..e69de29b diff --git a/vale_styles/config/vocabularies/Base/accept.txt b/vale_styles/config/vocabularies/Base/accept.txt new file mode 100644 index 00000000..a2361fb0 --- /dev/null +++ b/vale_styles/config/vocabularies/Base/accept.txt @@ -0,0 +1,68 @@ +[Kk]eploy +GitHub +APIs +Idempotency +Deduplication +UTGen +Testim +Applitools +Functionize +mabl +Pytest +Unittest +JBehave +JUnit +Reqnroll +NUnit +Spotify +Appium +JMeter +Mockaroo +Asana +LLMs +Woohoo +graphql +Docusaurus +Onboarding +Hoppscotch +DBs +Redis +Testcases +Testcase +containerName +UUIDs +Auditability +Arkade +Twilio +Hasura +Nhost +Postgres +Cobertura +Jacoco +signin +mock +borderRadius +dockerfile +html +npm +api +API +params +Cmd +respository +Hacktoberfest +wsl +WSL +testsets +Testrun +YAMLs +SDK +config +realtime +testmode +timeFreezing +templatize +wiremessages +middleware +distros +url \ No newline at end of file diff --git a/vale_styles/config/vocabularies/Base/reject.txt b/vale_styles/config/vocabularies/Base/reject.txt new file mode 100644 index 00000000..e69de29b diff --git a/vale_styles/xcode-line.tmpl b/vale_styles/xcode-line.tmpl new file mode 100644 index 00000000..a5c9d4fe --- /dev/null +++ b/vale_styles/xcode-line.tmpl @@ -0,0 +1,6 @@ +{{range .Files}} +{{- $path := .Path -}} +{{- range .Alerts -}} +{{$path}}:{{.Line}}:{{index .Span 0}}: {{.Severity}}: {{.Check}}:{{.Message}} +{{end -}} +{{end -}}