phabricator: add the DiffChangeType and DiffFileType constants
These are used in Phabricator change objects.
There are more values but so far as I can tell we don't need them.
Differential Revision: https://phab.mercurial-scm.org/D7041
--- a/hgext/phabricator.py Sun Oct 06 03:30:00 2019 -0400
+++ b/hgext/phabricator.py Sun Oct 06 13:50:32 2019 +0100
@@ -448,6 +448,23 @@
return output.getvalue()
+class DiffChangeType(object):
+ ADD = 1
+ CHANGE = 2
+ DELETE = 3
+ MOVE_AWAY = 4
+ COPY_AWAY = 5
+ MOVE_HERE = 6
+ COPY_HERE = 7
+ MULTICOPY = 8
+
+
+class DiffFileType(object):
+ TEXT = 1
+ IMAGE = 2
+ BINARY = 3
+
+
def creatediff(ctx):
"""create a Differential Diff"""
repo = ctx.repo()