Skip to content

Commit

Permalink
Merge pull request #7 from rukai/build_script
Browse files Browse the repository at this point in the history
Move build script out of netlify
  • Loading branch information
benbromhead authored May 24, 2023
2 parents ede6e5c + a5b36b2 commit 84a567e
Show file tree
Hide file tree
Showing 2 changed files with 40 additions and 1 deletion.
14 changes: 13 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
@@ -1 +1,13 @@
# Shotover Blog
# Shotover Website contents

Contents for https://shotover.io

For changes to https://shotover.io work on `docs/index.html`.

For changes to docs, please see https://github.com/shotover/shotover-proxy

## Building

TODO: Fully document how to build this locally.

For now you should start with running the build.sh script
27 changes: 27 additions & 0 deletions build.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
#!/bin/bash

set -e
set -u

rm docs/docs/*.md
rm -rf docs/docs/examples
rm -rf docs/docs/user-guide
git clone https://github.com/shotover/shotover-proxy.git
mv shotover-proxy/docs/src/* docs/docs/
rm -rf shotover-proxy
cd docs/docs/
find . -type f -name "*.md" -exec sed -i 's/```YAML/```yaml/g' {} +
find . -type f -name "*.md" -exec sed -i 's/```console/```make/g' {} +
rm logo.png logo.svg index.md SUMMARY.md
cd ../../
npm install --frozen-lockfile
echo "<Footer />" | tee -a docs/blog/*.md
echo "<Footer />" | tee -a docs/docs/*.md
echo "<SocialButtons /><RelatedPosts /><Footer />" | tee -a docs/blog/**/*.md
echo "<Footer />" | tee -a docs/docs/**/*.md
npm run docs:build
cd docs/.vitepress/
mkdir shotover-blog
mv dist/* shotover-blog
mv shotover-blog dist/
mv dist/shotover-blog/index.html dist/

0 comments on commit 84a567e

Please sign in to comment.