cortav  Artifact [053a3467a6]

Artifact 053a3467a6d94ae3164ab5a46399f27d77d3bab614737c2ebfdf9c56bf10c47f:


# note that this file lacks a shebang. there is no compatible way
# to write a shebang that works across distros, so we're generating
# the shebang and inserting it into the script at build time.
# we also do something similar with the path to cortav, in case the
# executable isn't in $PATH

out=$(mktemp --suffix=.html)

"$cortav_exec" "$1" -o "$out" $cortav_flags

if test "$BROWSER" != ""; then
	"$BROWSER" "file://$out"
else
	xdg-open "$out"
fi

# clean up when the browser closes
sleep 1 # in case of tricksiness
rm "$out"