egui/sh/start_server.sh

17 lines
488 B
Bash
Raw Normal View History

2020-04-12 10:07:51 +00:00
#!/bin/bash
set -eu
2021-05-09 11:28:24 +00:00
script_path=$( cd "$(dirname "${BASH_SOURCE[0]}")" ; pwd -P )
cd "$script_path/.."
2020-04-12 10:07:51 +00:00
2021-02-28 18:51:22 +00:00
# Starts a local web-server that serves the contents of the `doc/` folder,
2021-02-21 09:12:08 +00:00
# i.e. the web-version of `egui_demo_app`.
echo "ensuring basic-http-server is installed…"
2021-02-21 09:12:08 +00:00
cargo install basic-http-server
echo "starting server…"
echo "serving at http://localhost:8888"
2021-02-21 09:12:08 +00:00
(cd docs && basic-http-server --addr 127.0.0.1:8888 .)
# (cd docs && python3 -m http.server 8888 --bind 127.0.0.1)