models.main: manage 'head' from within set_mode() only
commit1af564f2a013ddeb47a3ba64cd28a5133afe23c3
authorDavid Aguilar <davvid@gmail.com>
Fri, 25 Oct 2013 09:52:10 +0000 (25 02:52 -0700)
committerDavid Aguilar <davvid@gmail.com>
Fri, 25 Oct 2013 10:02:14 +0000 (25 03:02 -0700)
tree052e7aca224e650e74c1a25fefa56f16de059ee0
parent4cc2bb4d29304047463687adf039e5911de3e5b8
models.main: manage 'head' from within set_mode() only

Remove the set_head() method and simplify callers by making set_mode()
manage the 'head' variable.  This is simpler since its value is always
tied to the mode (amend = 'HEAD^', all others = 'HEAD').

Signed-off-by: David Aguilar <davvid@gmail.com>
cola/cmds.py
cola/models/main.py