There is an easy solution to that!
You simply select Barracks and put it in group 0(CTRL + 0).
Then while you are doing the fighting you can order more troops, and you watch the map for enemies.
Also you want to put your battlemachine in group 1(CTRL + 1) and the other units with him on group 2(CTRL + 2).
Ok so your watching your army and the battlemachine kick the enemies butts, OH SHiiiiiiiiiiiiiiiucks my base is getting attacked(I said shucks not sh*t).
You simply select your Barracks from afar, and beam me up Scottie! No actually just hit the spacebar, but if you want to use the transporters go ahead.