Simple script that changes N number of occurrences of "lose" to "loose"
./bartle-test [filename] [number of occurrences to change]
e.g. ./bartle-test game-design.tex 2
Oh and this doesn't overwrite your original file so remember to pipe it to a new file
./bartle-test game-design.tex 2 > final.tex