Skip to content

Instantly share code, notes, and snippets.

@gdetrez
Last active December 15, 2015 10:29
Show Gist options
  • Save gdetrez/5245991 to your computer and use it in GitHub Desktop.
Save gdetrez/5245991 to your computer and use it in GitHub Desktop.
BNFC quick testing routine
# linux
cd `mktemp -d`
wget http://bnfc.digitalgrammars.com/download/bnfc-2.5.0rc1-linux.gz # Change me!
gzip -d bnfc-*.gz
chmod +x bnfc-*
wget https://raw.github.com/BNFC/bnfc/master/examples/Calc.cf
./bnfc-* -m Calc.cf
make
echo "2+3*4" | ./TestCalc
# CYGWIN
cd `mktemp -d`
wget http://bnfc.digitalgrammars.com/download/bnfc-2.5.0rc1-win.exe
chmod +x bnfc-*
wget --ca-directory=/usr/ssl/certs https://raw.github.com/BNFC/bnfc/master/examples/Calc.cf
./bnfc-* -m Calc.cf
make
echo "2+3*4" | ./TestCalc
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment