#!/bin/sh

set -e

FILE=license

rm -f $FILE.html
sed '1,/include file="ghc-std/ { /include file="/ ! p }; d' $FILE.shtml >> $FILE.html
cat ghc-std.html >> $FILE.html
sed '/include file="ghc-std/,/include file="ghc-footer/ { /include file="/ ! p }; d' $FILE.shtml >> $FILE.html
cat ghc-footer.html >> $FILE.html
sed '/include file="ghc-footer/,$ { /include file="/ ! p }; d' $FILE.shtml >> $FILE.html


