mirror of
https://github.com/0glabs/0g-chain.git
synced 2024-11-10 10:05:18 +00:00
1ffe763f90
* remove link to old migration docs * update readmes to latest version
50 lines
1.1 KiB
Bash
Executable File
50 lines
1.1 KiB
Bash
Executable File
#!/usr/bin/env bash
|
|
|
|
# Clone each module's markdown files
|
|
mkdir -p Modules
|
|
|
|
for D in ../x/*; do
|
|
if [ -d "${D}" ]; then
|
|
rm -rf "Modules/$(echo $D | awk -F/ '{print $NF}')"
|
|
mkdir -p "Modules/$(echo $D | awk -F/ '{print $NF}')" && cp -r $D/spec/* "$_"
|
|
fi
|
|
done
|
|
|
|
baseGitUrl="https://raw.githubusercontent.com/Kava-Labs"
|
|
|
|
# Client docs (JavaScript SDK)
|
|
clientGitRepo="javascript-sdk"
|
|
clientDir="building"
|
|
|
|
mkdir -p "./${clientDir}"
|
|
curl "${baseGitUrl}/${clientGitRepo}/master/README.md" -o "./${clientDir}/${clientGitRepo}.md"
|
|
echo "---
|
|
parent:
|
|
order: false
|
|
---" > "./${clientDir}/readme.md"
|
|
|
|
# Kava Tools docs
|
|
toolsGitRepo="kava-tools"
|
|
toolsDir="tools"
|
|
toolDocs=("auction" "oracle")
|
|
|
|
mkdir -p "./${toolsDir}"
|
|
for T in ${toolDocs[@]}; do
|
|
curl "${baseGitUrl}/${toolsGitRepo}/master/${T}/README.md" -o "./${toolsDir}/${T}.md"
|
|
done
|
|
|
|
# Add Go tools
|
|
goToolsGitRepo="go-tools"
|
|
goToolsDocs=("sentinel")
|
|
|
|
for T in ${goToolsDocs[@]}; do
|
|
curl "${baseGitUrl}/${goToolsGitRepo}/master/${T}/README.md" -o "./${toolsDir}/${T}.md"
|
|
done
|
|
|
|
# Copy the community tools
|
|
cp communitytools.md "./${toolsDir}/community.md"
|
|
echo "---
|
|
parent:
|
|
order: false
|
|
---" > "./${toolsDir}/readme.md"
|