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

docs: add markdown linting and spellcheck #186

Merged
merged 20 commits into from
Jul 14, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
944b0fa
docs: lint markdown files
danceratopz Jul 4, 2023
f5bfba9
chore: add settings file for markdown lint
danceratopz Jun 30, 2023
78e355c
chore: recommend markdownlint in vscode extensions
danceratopz Jun 30, 2023
b2b880a
chore: add md environment to help lint markdown files
danceratopz Jun 30, 2023
e43088e
chore: lint markdown as part of test github action
danceratopz Jun 30, 2023
42218bb
chore: add & configure pyspelling, split whitelist.txt into wordlists
danceratopz Jun 30, 2023
26d4e27
chore: add docs spell-check to tox; account for whitelist refactor
danceratopz Jun 30, 2023
78207f6
docs: fix spelling
danceratopz Jun 30, 2023
ec4501f
chore: move markdownlint-cli2 to doc tox env; but don't force
danceratopz Jun 30, 2023
8310807
chore: add pyspelling to tox; redirect missing package output to stderr
danceratopz Jun 30, 2023
09296eb
docs: minor fixes to documentation dev doc
danceratopz Jun 30, 2023
aabe71e
chore: clean-up pyspelling config file
danceratopz Jul 4, 2023
b86153a
chore: install missing dependency (aspell) for spelling
danceratopz Jul 4, 2023
d3a2b6d
chore: add cross-platform scripts for spelling and linting
danceratopz Jul 4, 2023
3e1f279
chore: add new words from whitelist.txt to .wordlist.txt
danceratopz Jul 4, 2023
77689fc
chore: fix globs in markdownlint-cli2 action
danceratopz Jul 4, 2023
c2fb90e
chore: fix markdown linting by removing link definitions
danceratopz Jul 4, 2023
e84a91a
docs: update for md lint & spellcheck; add tox -e docs
danceratopz Jul 14, 2023
87e5b97
docs: add box to highlight conical flask in exploring tests
danceratopz Jul 14, 2023
156f747
chore: add new wordlists to vs code recommended settings
danceratopz Jul 14, 2023
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
10 changes: 9 additions & 1 deletion .github/workflows/test.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,15 @@ jobs:
wget -O $GITHUB_WORKSPACE/bin/solc https://binaries.soliditylang.org/linux-amd64/$RELEASE_NAME
chmod a+x $GITHUB_WORKSPACE/bin/solc
echo $GITHUB_WORKSPACE/bin >> $GITHUB_PATH
- name: Install Aspell
run: |
sudo apt-get install aspell aspell-en
- name: Install Tox and any other packages
run: pip install tox requests
run: pip install tox
- name: Run Tox (CPython)
run: tox
- uses: DavidAnson/markdownlint-cli2-action@v11
with:
globs: |
README.md
docs/**/*.md
4 changes: 3 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -58,4 +58,6 @@ verify_kzg_proof
.cache
_readthedocs
site
venv-docs/
venv-docs/
.pyspelling_en.dict
whitelist.txt
5 changes: 5 additions & 0 deletions .markdownlint.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
# All rules: https://github.com/DavidAnson/markdownlint#rules--aliases
default: true # Default state for all rules
MD013: false # line-length: We don't fill paragaraphs/limit line length
MD034: false # no-bare-urls - We use pymdownx.magiclink which allows bare urls
MD046: false # code-block-style - This doesn't play well with material's admonitions)
24 changes: 24 additions & 0 deletions .pyspelling.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
matrix:
- name: markdown
pipeline:
- pyspelling.filters.markdown:
- pyspelling.filters.html:
comments: false
attributes:
- title
- alt
ignores:
- code
- pre
- a
aspell:
lang: en
d: en_US
dictionary:
wordlists:
- .wordlist.txt
- .wordlist_opcodes.txt
- .wordlist_python_pytest.txt
output: .pyspelling_en.dict
sources:
- 'docs/**/*.md'
6 changes: 5 additions & 1 deletion .vscode/extensions.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,13 @@
"ms-python.flake8",
"ms-python.black-formatter",
"esbenp.prettier-vscode",
"njpwerner.autodocstring", // https://marketplace.visualstudio.com/items?itemName=njpwerner.autodocstring
"streetsidesoftware.code-spell-checker",
"tamasfe.even-better-toml",
"bierner.markdown-mermaid", // https://marketplace.visualstudio.com/items?itemName=bierner.markdown-mermaid
"bpruitt-goddard.mermaid-markdown-syntax-highlighting", // https://marketplace.visualstudio.com/items?itemName=bpruitt-goddard.mermaid-markdown-syntax-highlighting
"DavidAnson.vscode-markdownlint", // https://marketplace.visualstudio.com/items?itemName=DavidAnson.vscode-markdownlint
],
// List of extensions recommended by VS Code that should not be recommended for users of this workspace.
"unwantedRecommendations": []
}
}
13 changes: 13 additions & 0 deletions .vscode/settings.recommended.json
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,18 @@
"description": "Words used in this project",
"addWords": true
},
"opcodes": {
"name": "opcodes",
"path": "${workspaceRoot}/.wordlist_opcodes.txt",
"description": "List of EVM opcodes",
"addWords": true
},
"python_pytest": {
"name": "python_pytest",
"path": "${workspaceRoot}/.wordlist_python_pytest.txt",
"description": "List of python and pytest related words",
"addWords": true
},
"custom": true, // Enable the `custom` dictionary
"internal-terms": false // Disable the `internal-terms` dictionary
},
Expand All @@ -17,6 +29,7 @@
"source.organizeImports": true
}
},
"python.analysis.autoFormatStrings": true,
"python.linting.mypyEnabled": true,
"python.linting.flake8Enabled": true,
"python.testing.promptToConfigure": false,
Expand Down
270 changes: 270 additions & 0 deletions .wordlist.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1,270 @@
addr
address2
alloc
base64
big0
big1
blockchain
bls
bytecode
bytes8
bytes20
bytes32
calc
cli2
coinbase
coincurve
crypto
dao
dup
eip
eips
eth
ethash
ethereum
evm
evmone
fn
forkchoice
geth
hash32
instantiation
hasher
ispkg
keccak
keccak256
key2
kzg
kzgs
listdir
ommer
ommers
parseable
pathlib
petersburg
precompile
randao
rlp
secp256k1
sharding
cancun
t8n
trie
txs
wd
wds
u256
utils
util
validator
vm
gwei
wei
islice
0xaa

getmtime
byteorder
delitem
dirname
endianness
fromhex
getitem
metaclass
radd
setitem
splitext
textwrap
zfill

lll
lllc
solc
yul

address
at5
balance
origin
caller
callvalue
calldata
calldataload
calldatasize
calldatacopy
codesize
codecopy
gasprice
extcodesize
extcodecopy
initcode
returndatasize
returndatacopy
extcodehash
blockhash
coinbase
timestamp
time15k
number
difficulty
gaslimit
chainid
selfbalance
basefee
ommer
prevrandao

docstrings
hexsha
mkdocs
mkdocstrings
nav
repo

evaluatable

GHSA
danceratopz
Pomerantz

acl
api
bb
BlockchainTest
BlockchainTestFiller
blocknum
blueswen
br
cd
codeAddr
compilable
config
contractAddr
controlflow
cp
customizations
Customizations
danceratopz
datastructures
dev
dir
discordapp
EIPs
env
eof
esbenp
executables
fname
formatOnSave
formatter
func
GeneralStateTestsFiller
gh
github
Github
git's
glightbox
homebrew
html
https
ignoreRevsFile
img
incrementing
init
io
isort
isort's
itemName
jimporter
jq
json
JSON
len
linux
london
macos
mainnet
marioevz
markdownlint
md
Misspelled words:
mypy
namespace
ncheck
nexternal
nGo
nJSON
nop
NOP
NOPs
nPython
nSHA
opc
oprypin
pdb
png
ppa
ppas
pre
Pre
prepend
programmatically
px
py
pyspelling
pytest
Pytest
pytestArgs
pytest's
qGpsxSA
quickstart
readthedocs
repo's
repos
runtime
sandboxed
sha
SHA
soliditylang
spencertaylorbrown
spencertb
squidfunk
src
stackoverflow
StateTest
StateTestFiller
stExample
str
streetsidesoftware
subdirectories
subdirectory
subgraph
substring
sudo
tamasfe
TestAddress
TestMultipleWithdrawalsSameAddress
toml
tox
Tox
tx
txt
ty
typehints
ubuntu
ukiyo
uncomment
venv
visualstudio
vscode
vv
wikipedia
wordlist
www
xF
xFA
xFD
xFF
yaml
YAML
yml
Loading
Loading