create logrun: a simple function to log the running info of an bash command