add codereview-login command

R=r
CC=go-dev
http://go/go-review/1012007
diff --git a/lib/codereview/codereview.py b/lib/codereview/codereview.py
index f0092a3..8ee0a6b 100644
--- a/lib/codereview/codereview.py
+++ b/lib/codereview/codereview.py
@@ -722,6 +722,15 @@
 	modheads = repo.pull(other)
 	return commands.postincoming(ui, repo, modheads, True, "tip")
 
+def dologin(ui, repo, **opts):
+	"""log in to code review server
+	
+	Logs in to the code review server, saving a cookie in
+	a file in your home directory.
+	"""
+	MySend("/")
+
+
 def uisetup(ui):
 	if "^commit|ci" in commands.table:
 		commands.table["^commit|ci"] = (nocommit, [], "")
@@ -792,6 +801,12 @@
 		[],
 		"",
 	),
+	
+	"codereview-login": (
+		dologin,
+		[],
+		"",
+	),
 }