fixed up bash part (at least i think)
oops, forgot the other psi stuff