improve setup of log command