Add markdown docs generation (#2437)

### Description

Adds markdown doc generation to solidity and token package

May be preferable to our gitbook contract API docs
dan/aggregation-ism-rc
Yorke Rhodes 1 year ago committed by GitHub
parent 7ff83bbd0b
commit e92d3410fc
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
  1. 1
      solidity/.gitignore
  2. 10
      solidity/README.md
  3. 4
      solidity/package.json
  4. 5
      typescript/token/.gitignore
  5. 7
      typescript/token/foundry.toml
  6. 6
      typescript/token/package.json
  7. 3
      typescript/token/remappings.txt

@ -10,3 +10,4 @@ coverage.json
# Foundry # Foundry
out out
forge-cache forge-cache
docs

@ -4,10 +4,12 @@ On-chain implementations of Hyperlane in Solidity.
## Setup ## Setup
- `npm install --dev` - `yarn install`
- `brew install jq`   OR   `sudo apt-get install jq`
## Build ## Build
- `npm run compile` - `yarn build`
- `npm run test`
## Test
- `yarn test`

@ -32,7 +32,8 @@
"files": [ "files": [
"/dist", "/dist",
"/contracts", "/contracts",
"/interfaces" "/interfaces",
"/docs"
], ],
"homepage": "https://www.hyperlane.xyz", "homepage": "https://www.hyperlane.xyz",
"keywords": [ "keywords": [
@ -47,6 +48,7 @@
"lint": "solhint contracts/**/*.sol", "lint": "solhint contracts/**/*.sol",
"clean": "hardhat clean && rm -rf ./dist ./cache", "clean": "hardhat clean && rm -rf ./dist ./cache",
"coverage": "hardhat coverage && forge coverage --report lcov", "coverage": "hardhat coverage && forge coverage --report lcov",
"docs": "forge doc",
"prettier": "prettier --write ./contracts ./test", "prettier": "prettier --write ./contracts ./test",
"test": "hardhat test && yarn test:forge", "test": "hardhat test && yarn test:forge",
"test:forge": "forge test -vvv", "test:forge": "forge test -vvv",

@ -6,4 +6,7 @@ dist/
coverage/ coverage/
coverage.json coverage.json
*.swp *.swp
.yarn/install-state.gz .yarn/install-state.gz
# foundry
docs
out

@ -0,0 +1,7 @@
[profile.default]
src = "contracts"
out = "out"
libs = ["lib"]
allow_paths = ["../../node_modules", "../../solidity"]
# See more config options https://github.com/foundry-rs/foundry/tree/master/config

@ -35,7 +35,8 @@
}, },
"files": [ "files": [
"/dist", "/dist",
"/contracts" "/contracts",
"/docs"
], ],
"homepage": "https://www.hyperlane.xyz", "homepage": "https://www.hyperlane.xyz",
"keywords": [ "keywords": [
@ -51,7 +52,8 @@
"url": "https://github.com/hyperlane-xyz/hyperlane-token" "url": "https://github.com/hyperlane-xyz/hyperlane-token"
}, },
"scripts": { "scripts": {
"clean": "hardhat clean && rm -rf dist cache src/types", "clean": "hardhat clean && rm -rf dist cache src/types && forge clean",
"docs": "forge doc",
"build": "hardhat compile && tsc", "build": "hardhat compile && tsc",
"coverage": "hardhat coverage", "coverage": "hardhat coverage",
"lint": "solhint contracts/**/*.sol && eslint . --ext .ts", "lint": "solhint contracts/**/*.sol && eslint . --ext .ts",

@ -0,0 +1,3 @@
@openzeppelin=../../node_modules/@openzeppelin
@hyperlane-xyz=../../node_modules/@hyperlane-xyz
forge-std/=lib/forge-std/src/
Loading…
Cancel
Save