This is covered in NL Theroy and Practice by Miller and Sklansky. In the chart below, the right-most column tells you the maximize stack size it is profitable to move all in with in $1/$2 NL.
http://www2.decf.berkeley.edu/~chubukov/rankings.html
But of course moving all in preflop with most hands is just usually going to get everyone to fold unless they have you beat. But it is much better to just learn how to play poker after the flop.
I think Miller's Intro to NL book deals with how to play a short stack. But you should really play with a bigger stack or people you play with will hate you.