magit-read-file-from-rev: allow selecting a tree

Teach `magit-read-file-from-rev' to offer
trees, not only blobs, for completion.
magit-diff-with-mark: only one argument RANGE

Replace `magit-diff-with-mark's MARKED and COMMIT arguments with just
RANGE, making it consistent with other diff commands.  Keeping these
arguments for non-interactive use would not make sense since the marked
commit is determined inside `interactive'.  Except for that part it
behaves the same ad `magit-diff', the latter should therefor be used
non-interactively.
git-am action --- apply mbox from within magit

This patch defines the git-am action and the `magit-apply-mailbox'
function and binds them to "j".

The existing interactive rebase machinery is extended to handle "git am"
mailbox applications.  Git shares structure between "git rebase" and
"git am", (e.g., they both use the .git/rebase-apply directory) so this
is a natural extension.
Merge branch 'pr/git-am'
magit-diff: fix regression

Since 4bb6cb07b9dab950742f3edd7cfa38afe1721839 `magit-diff', when the
diff buffer already existed, did not use the current `default-directory'
but that of the buffer.  Now it resets the local value again.
delimit sections with markers

Store markers instead of positions in the BEGINNING and END slots of
section structs.  This makes it possible change text before a section
after it has been washed.  Once case in which this is useful is when
washing a section properly requires information that isn't available
until another section that textually comes later has been washed.

The BEGINNING marker is initially set to not advance when text is
inserted at the place it points to (or nothing would ever become part
of the section), but once washing is done it is changed to advance.
optionally append the number of children to section headings

Close #548.
Merge branch 'pr/count'
magit-insert-section: only show child count if heading ends in colon
add commands magit-diff-{un,}staged
bind magit-diff-staged in git-commit-mode-map
Merge branch 'pr/staged'
bind magit-diff-staged to C-c C-d

For consistency with other bindings.
bind magit-diff-staged in git-commit-mode-map
magit-refresh-diff-buffer: make WORKING and ARGS optional

Close #1015.
magit-version: fix typo in comment, remove another
magit-version: fix another comment typo
don't repeatedly refresh when evaluating magit.el

Or any other library that uses `magit-set-variable-and-refresh'
or `magit-set-default-diff-options' to set an option.
magit-describe-item: move definition

Move the definition of `magit-describe-item' to the new "Maintenance
Tools" subsection of toplevel "Miscellaneous".  This new section will
soon contain more such things.

Rename the subsection of "Acting" where `magit-describe-item' from, from
"Describe" to "Kill".  The name previously was wrong because it also
contained and still does, the unrelated `magit-copy-item-as-kill'.

Now that it has been mostly cleaned up, we should probably lose the
subsections of the second "Acting" section, and rename it to something
like "Item Commands".  But that's another issue.
loading magit.el now calls git-commit-auto-mode-enable

Loading `magit.el' now calls `git-commit-auto-mode-enable', unless
library `magit-log-edit' is on the `load-path', in which case that
is loaded instead.