Skip to content

Commit

Permalink
Split contracts API doc into multiple files
Browse files Browse the repository at this point in the history
Having all the contracts documented in one common file turned out to be hard to
render by the GitBook. We're switching to documenting each contract file in a
separate Markdown file.
As the generated files will be much smaller now and GitBook has its own file `ON
THIS PAGE` section, we don't need to generate Table of Contents.
The one thing that we also change as part of this PR is `rsyncDelete` setting -
we'll have it set to `true`, in order to delete documentation of contracts which
get removed from the repo. As we're not working directly on a `main` branch,
this isn't dangerous (we'll see all the delitions in the PR diff).
  • Loading branch information
michalinacienciala committed Jun 28, 2023
1 parent 898dc9e commit 13ad2b2
Show file tree
Hide file tree
Showing 4 changed files with 8 additions and 2 deletions.
3 changes: 3 additions & 0 deletions .github/workflows/contracts-ecdsa-docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ jobs:
with:
projectDir: /solidity/ecdsa
publish: false
addTOC: false
commentPR: true
exportAsGHArtifacts: true

Expand Down Expand Up @@ -74,12 +75,14 @@ jobs:
with:
projectDir: /solidity/ecdsa
publish: true
addTOC: false
verifyCommits: true
destinationRepo: threshold-network/threshold
destinationFolder: ./docs/app-development/tbtc-v2/ecdsa-api
destinationBaseBranch: main
userEmail: [email protected]
userName: Valkyrie
rsyncDelete: true
secrets:
githubToken: ${{ secrets.THRESHOLD_DOCS_GITHUB_TOKEN }}
gpgPrivateKey: ${{ secrets.THRESHOLD_DOCS_GPG_PRIVATE_KEY_BASE64 }}
Expand Down
3 changes: 3 additions & 0 deletions .github/workflows/contracts-random-beacon-docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@ jobs:
with:
projectDir: /solidity/random-beacon
publish: false
addTOC: false
commentPR: true
exportAsGHArtifacts: true

Expand All @@ -63,12 +64,14 @@ jobs:
with:
projectDir: /solidity/random-beacon
publish: true
addTOC: false
verifyCommits: true
destinationRepo: threshold-network/threshold
destinationFolder: ./docs/app-development/random-beacon/random-beacon-api
destinationBaseBranch: main
userEmail: [email protected]
userName: Valkyrie
rsyncDelete: true
secrets:
githubToken: ${{ secrets.THRESHOLD_DOCS_GITHUB_TOKEN }}
gpgPrivateKey: ${{ secrets.THRESHOLD_DOCS_GPG_PRIVATE_KEY_BASE64 }}
Expand Down
2 changes: 1 addition & 1 deletion solidity/ecdsa/hardhat.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -225,7 +225,7 @@ const config: HardhatUserConfig = {
docgen: {
outputDir: "generated-docs",
templates: "docgen-templates",
pages: "single", // `single`, `items` or `files`
pages: "files", // `single`, `items` or `files`
exclude: ["./test"],
},
}
Expand Down
2 changes: 1 addition & 1 deletion solidity/random-beacon/hardhat.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@ const config: HardhatUserConfig = {
docgen: {
outputDir: "generated-docs",
templates: "docgen-templates",
pages: "single", // `single`, `items` or `files`
pages: "files", // `single`, `items` or `files`
exclude: ["./test"],
},
}
Expand Down

0 comments on commit 13ad2b2

Please sign in to comment.