Last active
April 22, 2018 11:57
-
-
Save purplesyringa/3a27a7516fc50b5b8b2595b8af2d571e to your computer and use it in GitHub Desktop.
PDP11/BK0010 compiler script
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env bash | |
cd "$(dirname "$0")" | |
echo Compiling $1 | |
./compiler "$1" >_log | |
if [ $? -ne 0 ]; then | |
cat _log | python -c "import sys; print sys.stdin.read().decode('utf-8', 'ignore').encode('utf-8')" | tail -2 | head -1 | |
exit | |
fi | |
echo Saved! |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment