optimise history saving

* only save commands since shell start
* only `git add` files that I expect to have changed
* TODO: amalgamate history on shell start or shell stop?