h48

A prototype for an optimal Rubik's cube solver, work in progress.
git clone https://git.tronto.net/h48
Download | Log | Files | Refs | README | LICENSE

genmovecode.sh (288B)


      1 #!/bin/sh
      2 
      3 cc -DDEBUG h48_to_lst.c ../src/nissy.c -o h48_to_lst
      4 
      5 gen() {
      6 	for f in cubes/move_??_*.txt; do
      7 		move="$(echo $f | sed 's/.*_// ; s/\.txt//')"
      8 		printf '#define _move_cube_%s fastcube( \\\n    ' "$move"
      9 		./h48_to_lst <"$f"
     10 		printf ')\n'
     11 	done
     12 }
     13 
     14 gen
     15 rm -f h48_to_lst invert