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
| RIPPLE_LIB = node_modules/ripple-lib/package.json | |
| all: hedge.js $(RIPPLE_LIB) | |
| node hedge | tee latest.log | tee -a full.log | |
| if grep -q "Offers submitted" latest.log; then \ | |
| $(MAKE) email; \ | |
| $(MAKE) trips; \ | |
| fi | |
| $(RIPPLE_LIB): |
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
| NEXT = openssl rsautl -decrypt -inkey key -raw | |
| all: key | |
| openssl dgst -sha -out id -sign key key | |
| openssl dgst -sha -signature id -prverify key key | |
| while sleep 1; do \ | |
| openssl base64 -in id; \ | |
| $(NEXT) -in id -out next; \ | |
| mv next id; \ |
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
| LOGFILE = $$HOME/.bitstamp.log | |
| all: | |
| -while date; do \ | |
| $(MAKE) trace; \ | |
| sleep 60; \ | |
| done | |
| trace: | |
| sed -n -f log2json.sed $(LOGFILE) >spyhedge.json |
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
| URL = https://www.bitstamp.net/api/order_book/?group=0 | |
| all: | |
| -while date; do \ | |
| $(MAKE) spy; \ | |
| $(MAKE) clean; \ | |
| sleep 60; \ | |
| done | |
| spy: orders.json |
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
| HEDGE = node riphedge | |
| all: | |
| npm install ripple-lib | |
| hedge: | |
| $(HEDGE) | tee hedge.txt | |
| grep -q Ask hedge.txt | |
| mailx -s "`grep Ripples hedge.txt`" me <hedge.txt |
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
| HEDGE = node bithedge | |
| all: | |
| npm install bitstamp | |
| hedge: | |
| $(HEDGE) old >|old.txt | |
| cat old.txt | |
| $(HEDGE) cancel `cat old.txt` | |
| $(HEDGE) balance >|balance.txt |
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
| all: smm | |
| ./smm | |
| clean: | |
| -rm -f smm | |
| .SUFFIXES: .v | |
| .v: | |
| iverilog -Wall -DSIM -o $@ $< |
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
| all: comb | |
| ./comb | |
| clean: | |
| -rm -f comb | |
| .SUFFIXES: .v | |
| .v: | |
| iverilog -Wall -DSIM -o $@ $< |
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
| all: brain | |
| base64 /dev/urandom | head | ./brain | |
| clean: | |
| -rm -f brain | |
| .SUFFIXES: .v | |
| .v: | |
| iverilog -Wall -DSIM -o $@ $< |
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
| all: ram0 | |
| ./ram0 | |
| clean: | |
| -rm -f ram0 | |
| .SUFFIXES: .v | |
| .v: | |
| iverilog -Wall -DSIM -o $@ $< |