Some more command improvements and fixes.
More command improvements and small bugfixes.