The sentry command is a requsite command that was in civ1 and civ2. I was shocked when it was not in civ3. It is very useful. If you senty a unit it will 'sleep' and you will not have to give it commands every turn. If a unit from another civ passes by it it will wake back up again for you to give commands to.
In PTW there's now a Shift-Y as well. It will sentry a unit so that it will only waken if an enemy unit approachs. Friendly foreign units will be ignored.