-
Notifications
You must be signed in to change notification settings - Fork 0
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
feat: add cspell common dictionary and example snippet #44
Closed
Closed
Changes from all commits
Commits
Show all changes
9 commits
Select commit
Hold shift + click to select a range
18422ec
feat: add cspell common dictionary and example snippet
michaeljaltamirano aa613b6
feat: expand dictionary
michaeljaltamirano 1fca425
feat: expand dictionary pt. 2
michaeljaltamirano f6dca7e
feat: add remaining global keywords for final steps of testing
michaeljaltamirano 913352c
feat: add plural of concats to dictionary
michaeljaltamirano 44d1d99
feat: add toggleable to dictionary
michaeljaltamirano 8fd7dbe
refactor: expand cspell.json ignorePaths for pre-commit repo
michaeljaltamirano 96c4438
refactor: alphabetize dictionaries and update README example
michaeljaltamirano f55d61a
fix: update release notes action to try and resolve CI error
michaeljaltamirano File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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
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 |
---|---|---|
@@ -0,0 +1,39 @@ | ||
{ | ||
"$schema": "https://raw.githubusercontent.com/streetsidesoftware/cspell/main/cspell.schema.json", | ||
"version": "0.2", | ||
"allowCompoundWords": false, | ||
"caseSensitive": true, | ||
"dictionaries": [ | ||
"bash", | ||
"css", | ||
"en-gb", | ||
"fonts", | ||
"go", | ||
"html", | ||
"node", | ||
"npm", | ||
"powershell", | ||
"python", | ||
"turo-dictionary", | ||
"typescript" | ||
], | ||
"dictionaryDefinitions": [ | ||
{ | ||
"addWords": true, | ||
"name": "turo-dictionary", | ||
"path": "./hooks/cspell/turo-dictionary.txt" | ||
} | ||
], | ||
"ignoreRegExpList": ["^.*TODO.*"], | ||
"ignorePaths": [ | ||
"./.gitignore", | ||
"./.pre-commit-hooks.yaml", | ||
"./containers/**", | ||
"./docs/**", | ||
"./hooks/**", | ||
"./licenses/**", | ||
"./README.md", | ||
"./script/**", | ||
"./versions.env" | ||
] | ||
} |
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,40 @@ | ||
# Cspell Dictionary | ||
|
||
This `hooks/cspell` directory is not an actual `pre-commit` hook to be referenced by `id`, but a common dictionary that can be extended in repos that use `pre-commit` to avoid duplicating frequent (and Turo-specific) terminology. | ||
|
||
```json | ||
// cspell.jsonc | ||
{ | ||
"$schema": "https://raw.githubusercontent.com/streetsidesoftware/cspell/main/cspell.schema.json", | ||
"version": "0.2", | ||
"allowCompoundWords": false, | ||
"caseSensitive": true, | ||
// https://cspell.org/docs/dictionaries/ | ||
"dictionaries": [ | ||
"bash", | ||
"css", | ||
"en-gb", | ||
"fonts", | ||
"go", | ||
"html", | ||
"node", | ||
"npm", | ||
"powershell", | ||
"python", | ||
"turo-dictionary", | ||
"typescript" | ||
], | ||
"dictionaryDefinitions": [ | ||
{ | ||
"addWords": true, | ||
"name": "turo-dictionary", | ||
// TODO (@michaeljaltamirano): Update path | ||
"path": "https://raw.githubusercontent.com/turo/pre-commit-hooks/spike/cspell-michael/hooks/cspell/turo-dictionary.txt", | ||
} | ||
], | ||
"ignoreRegExpList": ["^.*TODO.*"], | ||
"ignorePaths": ["./.gitignore"] | ||
} | ||
``` | ||
|
||
It's a requirement for the dictionary to be referenced at the project-level `cspell.json` file, so we cannot bake a Turo-specific configuration within this repo as a `pre-commit` hook. The next best option is making the dictionary available via HTTP GET to be pulled into repo-specific configurations. This repo has a file in `~/cspell.jsonc` that can be used as a reference. |
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,133 @@ | ||
# This is a comment | ||
# "Forbidden" syntax: !forbiddenword | ||
allstar | ||
appsflyer | ||
autofilled | ||
autofix | ||
backroads | ||
benn | ||
blocklisted | ||
bottomsheet | ||
bugsnag | ||
Bugsnag | ||
camelcase | ||
carculator | ||
carfax | ||
cargovan | ||
carplay | ||
centerpoint | ||
checkin | ||
checkins | ||
classname | ||
codegen | ||
cohorting | ||
cohosting | ||
cohosts | ||
commitlint | ||
concat | ||
concats | ||
cooldown | ||
datalayer | ||
datepicker | ||
datestring | ||
datetimes | ||
deeplink | ||
deeplinking | ||
devicer | ||
dropoff | ||
dtos | ||
EIGHTYFIVEPLAN | ||
EIGHTYPLAN | ||
expedia | ||
ezpass | ||
figma | ||
flagr | ||
gdpr | ||
giftcard | ||
giftcards | ||
grecaptcha | ||
iata | ||
Iata | ||
intercardinal | ||
itunes | ||
jfrog | ||
kustomer | ||
latlng | ||
librca | ||
lngs | ||
lurleen | ||
mastercard | ||
meineke | ||
miata | ||
millis | ||
MISNAP | ||
mitek | ||
multisave | ||
mvsc | ||
mweb | ||
NINETYPLAN | ||
nissay | ||
northpass | ||
onelink | ||
ouicar | ||
owntheadventure | ||
pageload | ||
pasteable | ||
paypal | ||
pois | ||
postmessage | ||
preapproval | ||
prechecked | ||
prechecked | ||
premade | ||
prereq | ||
prereqs | ||
preseeding | ||
pricepin | ||
pricepins | ||
pricings | ||
prohost | ||
promocode | ||
publically | ||
qrcode | ||
recaptcha | ||
refetches | ||
relayrides | ||
schemaorg | ||
schu | ||
schumi | ||
screenshotted | ||
SEVENTYFIVEPLAN | ||
SEVENTYPLAN | ||
signup | ||
SIXTYFIVEPLAN | ||
SIXTYPLAN | ||
smartcar | ||
snakecase | ||
socure | ||
storyblok | ||
sublocality | ||
subreason | ||
subreasons | ||
subroute | ||
subroutes | ||
subview | ||
swipeable | ||
teamcity | ||
testcafe | ||
timeframe | ||
toggleable | ||
totalloss | ||
traveller | ||
turo | ||
twilio | ||
twofactor | ||
uber | ||
unavailabilities | ||
underinsured | ||
unionpay | ||
upsell | ||
vals | ||
webcal | ||
yalc | ||
youtube |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is the dictionary where we can add terms we run into in stand-alone repos to be used across all repos. Anything Turo-specific or Engineering-specific or general terminology can go here.
Any terms that are more likely to be repo-specific can go in an array maintained in the repo itself: https://github.com/turo/web-schumacher-app/pull/9234/files#diff-303b67a39635355281d1863a42d6648fbaab26cc0ea8c4c5f3bff37eea65cabb