add a global variable while the shell is in record mode
Merge pull request #47 from rainu/issue-46-record-mode

Record mode