From 89738cecaa261e4626bb4507990f12a95c9419f2 Mon Sep 17 00:00:00 2001 From: Nicholas O'Connor Date: Wed, 22 Mar 2017 20:31:46 -0700 Subject: [PATCH] bootstrap now runs cogs on relevant files --- bootstrap | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/bootstrap b/bootstrap index dc68b4d..0fbd4b5 100644 --- a/bootstrap +++ b/bootstrap @@ -4,4 +4,19 @@ if [ ! -d "m4" ]; then mkdir m4 fi +export COG=$(command -v cog) +[ -z "$COG"] && export COG=$(command -v cog.py) + +if [ -z "$COG" ]; then + echo "Please install the Cog code generator, probably with pip install cogapp" + return 1 +fi + +echo "cog found at $COG" +for cogfile in $(find src -name "*.cog"); do + decogged=${cogfile%.cog} + echo "greasing cog for ${decogged}..." + $COG -d -o ${decogged} ${cogfile} +done + autoreconf --install