a336893116
* first pass redoc apis * new landing + component update * added intro * new structure * link list * add sandbox sdk * remove theme colours * revert credit to ticket & ticketbook and actually get all the instances to replace * Max/zknym doc tweak (#5223) * revert credit to ticket & ticketbook * revert credit to ticket & ticketbook and actually get all the instances to replace * theme tweak to widen text area * theme redoc component * tweak padding topbar * modified socks5 page to be in line with websocket client * modify h size of autodoc generated command info * tweak script to build from master * add autodoc to workspace * auto commit generated command files * clean autodoc-generated-markdown in script * auto commit generated command files * tweak works * clippy * fix borked toml from cherrypick * remove rm command * auto commit generated command files * blow away images * auto commit generated command files * remove redoc for nymapi for the moment but retain everything else * fix double paste * temp remove sandbox
31 lines
1.4 KiB
Bash
Executable File
31 lines
1.4 KiB
Bash
Executable File
#!/bin/bash
|
|
|
|
# this script is run by the `generate:commands` script in docs/package.json
|
|
|
|
set -o errexit
|
|
set -o nounset
|
|
set -o pipefail
|
|
|
|
# make sure we have all the binaries built from master
|
|
CURRENT_BRANCH=$(git rev-parse --abbrev-ref HEAD) && git checkout master &&
|
|
cd ../../ && cargo build --release && cd tools/nym-cli && cargo build --release && cd ../../ && git checkout $CURRENT_BRANCH &&
|
|
|
|
# run autodoc script
|
|
cd documentation/autodoc/ && cargo run --release &&
|
|
mv autodoc-generated-markdown/nym-cli-commands.md ../docs/pages/developers/tools/nym-cli/commands.mdx &&
|
|
mv autodoc-generated-markdown/nym-client-commands.md ../docs/pages/developers/clients/websocket/commands.mdx &&
|
|
mv autodoc-generated-markdown/nym-socks5-client-commands.md ../docs/pages/developers/clients/socks5/commands.mdx &&
|
|
mv autodoc-generated-markdown/commands/* ../docs/components/outputs/command-outputs/ &&
|
|
|
|
# commit files to git: needed for remote deployment from branch
|
|
if ! git diff --quiet -- "../docs/pages/developers/tools" "../docs/pages/developers/clients/websocket" "../docs/pages/developers/clients/socks5" "../docs/components/outputs/command-outputs/"; then
|
|
printf "commiting changes"
|
|
git add ../docs/pages/developers/ ../docs/components/outputs/command-outputs/
|
|
git commit -m "auto commit generated command files"
|
|
git push origin HEAD
|
|
else
|
|
printf "nothing to commit"
|
|
fi
|
|
|
|
cd ../docs
|