Add :exec prompt command and inline test commands that uses key bindings

This also documents :save-display, :script and :exec in the manual.
Fix the test editor script to optionally read the line number argument

Passing a non-number argument to printf(1)'s "%d" format on Mac OS X
(Yosemite) causes an error.
Fix and improve status on-branch information

Add a test for the different on-branch "modes" based on whether
git-rebase, git-am or git-merge is in progress or whether a detached
head has been checked out.

This also changes status view refreshing to only reload the current
branch information and not all refs as suggested in #341. Note that it
actually reloads all repo information to get both the symbolic ref
pointed to by HEAD as well as the HEAD id.
Use load_repo_head() when reloading refs

This ensures that the HEAD and HEAD ID is always in sync.