Add commit message template

Review Request #6833 — Created Jan. 27, 2015 and discarded — Latest diff uploaded

rbtools, students

Some RBT commands, like patch/land, allow users to commit with a commit message. Previously, this commit message would be hard coded with python strings, however adding the option to specify a user defined template would be more helpful.

The added option is --template <template_directory_or_name>, which could be any of:
- the template's directory
- the template's directory within the "TEMPLATES_DIR" folder, as specified in .reviewboardrc
- the name of the template, as specified in .reviewboardrc

If no template is specified, a default template is selected.
If no template exists under the argument, the user will be prompted for the default template.
As template design is up to the user, the code is not responsible for handling misconfigured templates.

I've tested with (rbt patch):
--template <existing_template_path>
--template <non_existant_template_path>
--template <existing_template in TEMPLATES_DIR>
--template <variable name in .reviewboardrc>
--template with invalid syntax (like not closing the if statement)
--template attempting to access invalid variables
--commit (no --template, which should render the default template)

Unit tests are available as well, but I don't know if they make sense tested that way.