commit 10010f8178f1eaaea8bc372d65c93b28d85725e5 Author: Trevor Slocum Date: Sun May 30 10:52:35 2021 -0700 Initial commit diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..1269488 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +data diff --git a/README.md b/README.md new file mode 100644 index 0000000..c9b2f52 --- /dev/null +++ b/README.md @@ -0,0 +1,14 @@ +# cview-integration-test + +Download and run several cview-based applications + +## Applications + +* [makeworld-the-better-one/amfora](https://github.com/makeworld-the-better-one/amfora) - Gemini browser +* [tslocum/netris](https://code.rocketnine.space/tslocum/netris) - Tetris clone + +## Usage + +``` +cview.sh [path to local cview] +``` diff --git a/cview.sh b/cview.sh new file mode 100755 index 0000000..ab441d1 --- /dev/null +++ b/cview.sh @@ -0,0 +1,44 @@ +#!/bin/bash +# +# Usage: cview.sh [path] +# +# Description: Download and run several cview-based applications +# You may optionally provide a path to a local copy of cview + +set -e + +mkdir -p data +cd data + +# Amfora - Gemini browser +if [ ! -d amfora ] +then + git clone https://github.com/makeworld-the-better-one/amfora + cd amfora +else + cd amfora + git pull +fi +if [ ! -z "$1" ]; then + go mod edit -replace code.rocketnine.space/tslocum/cview="$1" +fi +make clean +make +./amfora + +# netris - Tetris clone +cd ../ +if [ ! -d netris ] +then + git clone https://code.rocketnine.space/tslocum/netris + cd netris +else + cd netris + git pull +fi +if [ ! -z "$1" ]; then + go mod edit -replace code.rocketnine.space/tslocum/cview="$1" +fi +cd cmd/netris +go build +./netris