##// END OF EJS Templates
hgweb: add error template to json so it won't crash
Yuya Nishihara -
r39505:1a786fe0 default
parent child Browse files
Show More
@@ -1,243 +1,246 b''
1 default = 'shortlog'
1 default = 'shortlog'
2 mimetype = 'application/json'
2 mimetype = 'application/json'
3
3
4 filerevision = '\{
4 filerevision = '\{
5 "node": {node|json},
5 "node": {node|json},
6 "path": {file|json},
6 "path": {file|json},
7 "date": {date|json},
7 "date": {date|json},
8 "desc": {desc|utf8|json},
8 "desc": {desc|utf8|json},
9 "branch": {if(branch, branch%changesetbranch, "default"|json)},
9 "branch": {if(branch, branch%changesetbranch, "default"|json)},
10 "bookmarks": [{join(bookmarks%changelistentryname, ", ")}],
10 "bookmarks": [{join(bookmarks%changelistentryname, ", ")}],
11 "tags": [{join(tags%changelistentryname, ", ")}],
11 "tags": [{join(tags%changelistentryname, ", ")}],
12 "user": {author|utf8|json},
12 "user": {author|utf8|json},
13 "parents": [{join(parent%changesetparent, ", ")}],
13 "parents": [{join(parent%changesetparent, ", ")}],
14 "phase": {phase|json},
14 "phase": {phase|json},
15 "lines": [{join(text%lineentry, ", ")}]
15 "lines": [{join(text%lineentry, ", ")}]
16 }'
16 }'
17 lineentry = '\{
17 lineentry = '\{
18 "line": {line|json}
18 "line": {line|json}
19 }'
19 }'
20 search = '\{
20 search = '\{
21 "node": {node|json},
21 "node": {node|json},
22 "query": {query|json},
22 "query": {query|json},
23 "entries": [{join(entries%changelistentry, ", ")}]
23 "entries": [{join(entries%changelistentry, ", ")}]
24 }'
24 }'
25 # changelog and shortlog are the same web API but with different
25 # changelog and shortlog are the same web API but with different
26 # number of entries.
26 # number of entries.
27 changelog = changelist.tmpl
27 changelog = changelist.tmpl
28 shortlog = changelist.tmpl
28 shortlog = changelist.tmpl
29 graph = graph.tmpl
29 graph = graph.tmpl
30 changelistentry = '\{
30 changelistentry = '\{
31 "node": {node|json},
31 "node": {node|json},
32 "date": {date|json},
32 "date": {date|json},
33 "desc": {desc|utf8|json},
33 "desc": {desc|utf8|json},
34 "branch": {if(branch, branch%changesetbranch, "default"|json)},
34 "branch": {if(branch, branch%changesetbranch, "default"|json)},
35 "bookmarks": [{join(bookmarks%changelistentryname, ", ")}],
35 "bookmarks": [{join(bookmarks%changelistentryname, ", ")}],
36 "tags": [{join(tags%changelistentryname, ", ")}],
36 "tags": [{join(tags%changelistentryname, ", ")}],
37 "user": {author|utf8|json},
37 "user": {author|utf8|json},
38 "phase": {phase|json},
38 "phase": {phase|json},
39 "parents": [{if(allparents, join(allparents%changesetparent, ", "),
39 "parents": [{if(allparents, join(allparents%changesetparent, ", "),
40 join(parent%changesetparent, ", "))}]
40 join(parent%changesetparent, ", "))}]
41 }'
41 }'
42 graphentry = '\{
42 graphentry = '\{
43 "node": {node|json},
43 "node": {node|json},
44 "date": {date|json},
44 "date": {date|json},
45 "desc": {desc|utf8|json},
45 "desc": {desc|utf8|json},
46 "branch": {if(branch, branch%changesetbranch, "default"|json)},
46 "branch": {if(branch, branch%changesetbranch, "default"|json)},
47 "bookmarks": [{join(bookmarks%changelistentryname, ", ")}],
47 "bookmarks": [{join(bookmarks%changelistentryname, ", ")}],
48 "tags": [{join(tags%changelistentryname, ", ")}],
48 "tags": [{join(tags%changelistentryname, ", ")}],
49 "user": {author|utf8|json},
49 "user": {author|utf8|json},
50 "phase": {phase|json},
50 "phase": {phase|json},
51 "col": {col|json},
51 "col": {col|json},
52 "row": {row|json},
52 "row": {row|json},
53 "color": {color|json},
53 "color": {color|json},
54 "edges": {edges|json},
54 "edges": {edges|json},
55 "parents": [{if(allparents, join(allparents%changesetparent, ", "),
55 "parents": [{if(allparents, join(allparents%changesetparent, ", "),
56 join(parent%changesetparent, ", "))}]
56 join(parent%changesetparent, ", "))}]
57 }'
57 }'
58 changelistentryname = '{name|utf8|json}'
58 changelistentryname = '{name|utf8|json}'
59 changeset = '\{
59 changeset = '\{
60 "node": {node|json},
60 "node": {node|json},
61 "date": {date|json},
61 "date": {date|json},
62 "desc": {desc|utf8|json},
62 "desc": {desc|utf8|json},
63 "branch": {if(branch, branch%changesetbranch, "default"|json)},
63 "branch": {if(branch, branch%changesetbranch, "default"|json)},
64 "bookmarks": [{join(changesetbookmark, ", ")}],
64 "bookmarks": [{join(changesetbookmark, ", ")}],
65 "tags": [{join(changesettag, ", ")}],
65 "tags": [{join(changesettag, ", ")}],
66 "user": {author|utf8|json},
66 "user": {author|utf8|json},
67 "parents": [{join(parent%changesetparent, ", ")}],
67 "parents": [{join(parent%changesetparent, ", ")}],
68 "phase": {phase|json}
68 "phase": {phase|json}
69 }'
69 }'
70 changesetbranch = '{name|utf8|json}'
70 changesetbranch = '{name|utf8|json}'
71 changesetbookmark = '{bookmark|utf8|json}'
71 changesetbookmark = '{bookmark|utf8|json}'
72 changesettag = '{tag|utf8|json}'
72 changesettag = '{tag|utf8|json}'
73 changesetparent = '{node|json}'
73 changesetparent = '{node|json}'
74 manifest = '\{
74 manifest = '\{
75 "node": {node|json},
75 "node": {node|json},
76 "abspath": {path|json},
76 "abspath": {path|json},
77 "directories": [{join(dentries%direntry, ", ")}],
77 "directories": [{join(dentries%direntry, ", ")}],
78 "files": [{join(fentries%fileentry, ", ")}],
78 "files": [{join(fentries%fileentry, ", ")}],
79 "bookmarks": [{join(bookmarks%name, ", ")}],
79 "bookmarks": [{join(bookmarks%name, ", ")}],
80 "tags": [{join(tags%name, ", ")}]
80 "tags": [{join(tags%name, ", ")}]
81 }'
81 }'
82 name = '{name|utf8|json}'
82 name = '{name|utf8|json}'
83 direntry = '\{
83 direntry = '\{
84 "abspath": {path|json},
84 "abspath": {path|json},
85 "basename": {basename|json},
85 "basename": {basename|json},
86 "emptydirs": {emptydirs|json}
86 "emptydirs": {emptydirs|json}
87 }'
87 }'
88 fileentry = '\{
88 fileentry = '\{
89 "abspath": {file|json},
89 "abspath": {file|json},
90 "basename": {basename|json},
90 "basename": {basename|json},
91 "date": {date|json},
91 "date": {date|json},
92 "size": {size|json},
92 "size": {size|json},
93 "flags": {permissions|json}
93 "flags": {permissions|json}
94 }'
94 }'
95 tags = '\{
95 tags = '\{
96 "node": {node|json},
96 "node": {node|json},
97 "tags": [{join(entriesnotip%tagentry, ", ")}]
97 "tags": [{join(entriesnotip%tagentry, ", ")}]
98 }'
98 }'
99 tagentry = '\{
99 tagentry = '\{
100 "tag": {tag|utf8|json},
100 "tag": {tag|utf8|json},
101 "node": {node|json},
101 "node": {node|json},
102 "date": {date|json}
102 "date": {date|json}
103 }'
103 }'
104 bookmarks = '\{
104 bookmarks = '\{
105 "node": {node|json},
105 "node": {node|json},
106 "bookmarks": [{join(entries%bookmarkentry, ", ")}]
106 "bookmarks": [{join(entries%bookmarkentry, ", ")}]
107 }'
107 }'
108 bookmarkentry = '\{
108 bookmarkentry = '\{
109 "bookmark": {bookmark|utf8|json},
109 "bookmark": {bookmark|utf8|json},
110 "node": {node|json},
110 "node": {node|json},
111 "date": {date|json}
111 "date": {date|json}
112 }'
112 }'
113 branches = '\{
113 branches = '\{
114 "branches": [{join(entries%branchentry, ", ")}]
114 "branches": [{join(entries%branchentry, ", ")}]
115 }'
115 }'
116 branchentry = '\{
116 branchentry = '\{
117 "branch": {branch|utf8|json},
117 "branch": {branch|utf8|json},
118 "node": {node|json},
118 "node": {node|json},
119 "date": {date|json},
119 "date": {date|json},
120 "status": {status|json}
120 "status": {status|json}
121 }'
121 }'
122 shortlogentry = '{changelistentry}'
122 shortlogentry = '{changelistentry}'
123 summary = '\{
123 summary = '\{
124 "node": {node|json},
124 "node": {node|json},
125 "lastchange": {lastchange|json},
125 "lastchange": {lastchange|json},
126 "bookmarks": [{join(bookmarks%bookmarkentry, ", ")}],
126 "bookmarks": [{join(bookmarks%bookmarkentry, ", ")}],
127 "branches": [{join(branches%branchentry, ", ")}],
127 "branches": [{join(branches%branchentry, ", ")}],
128 "shortlog": [{join(shortlog%shortlogentry, ", ")}],
128 "shortlog": [{join(shortlog%shortlogentry, ", ")}],
129 "tags": [{join(tags%tagentry, ", ")}],
129 "tags": [{join(tags%tagentry, ", ")}],
130 "archives": [{join(archives%archiveentry, ", ")}],
130 "archives": [{join(archives%archiveentry, ", ")}],
131 "labels": {labels|json}
131 "labels": {labels|json}
132 }'
132 }'
133 archiveentry = '\{
133 archiveentry = '\{
134 "node": {node|json},
134 "node": {node|json},
135 "extension": {extension|json},
135 "extension": {extension|json},
136 "type": {type|json},
136 "type": {type|json},
137 "url": {"{urlbase}{url}archive/{node}{extension}"|json}
137 "url": {"{urlbase}{url}archive/{node}{extension}"|json}
138 }'
138 }'
139 filediff = '\{
139 filediff = '\{
140 "path": {file|json},
140 "path": {file|json},
141 "node": {node|json},
141 "node": {node|json},
142 "date": {date|json},
142 "date": {date|json},
143 "desc": {desc|utf8|json},
143 "desc": {desc|utf8|json},
144 "author": {author|utf8|json},
144 "author": {author|utf8|json},
145 "parents": [{join(parent%changesetparent, ", ")}],
145 "parents": [{join(parent%changesetparent, ", ")}],
146 "children": [{join(child%changesetparent, ", ")}],
146 "children": [{join(child%changesetparent, ", ")}],
147 "diff": [{join(diff, ", ")}]
147 "diff": [{join(diff, ", ")}]
148 }'
148 }'
149 diffblock = '\{
149 diffblock = '\{
150 "blockno": {blockno|json},
150 "blockno": {blockno|json},
151 "lines": [{join(lines, ", ")}]
151 "lines": [{join(lines, ", ")}]
152 }'
152 }'
153 difflineplus = '\{
153 difflineplus = '\{
154 "t": "+",
154 "t": "+",
155 "n": {lineno|json},
155 "n": {lineno|json},
156 "l": {line|json}
156 "l": {line|json}
157 }'
157 }'
158 difflineminus = '\{
158 difflineminus = '\{
159 "t": "-",
159 "t": "-",
160 "n": {lineno|json},
160 "n": {lineno|json},
161 "l": {line|json}
161 "l": {line|json}
162 }'
162 }'
163 difflineat = '\{
163 difflineat = '\{
164 "t": "@",
164 "t": "@",
165 "n": {lineno|json},
165 "n": {lineno|json},
166 "l": {line|json}
166 "l": {line|json}
167 }'
167 }'
168 diffline = '\{
168 diffline = '\{
169 "t": "",
169 "t": "",
170 "n": {lineno|json},
170 "n": {lineno|json},
171 "l": {line|json}
171 "l": {line|json}
172 }'
172 }'
173 filecomparison = '\{
173 filecomparison = '\{
174 "path": {file|json},
174 "path": {file|json},
175 "node": {node|json},
175 "node": {node|json},
176 "date": {date|json},
176 "date": {date|json},
177 "desc": {desc|utf8|json},
177 "desc": {desc|utf8|json},
178 "author": {author|utf8|json},
178 "author": {author|utf8|json},
179 "parents": [{join(parent%changesetparent, ", ")}],
179 "parents": [{join(parent%changesetparent, ", ")}],
180 "children": [{join(child%changesetparent, ", ")}],
180 "children": [{join(child%changesetparent, ", ")}],
181 "leftnode": {leftnode|json},
181 "leftnode": {leftnode|json},
182 "rightnode": {rightnode|json},
182 "rightnode": {rightnode|json},
183 "comparison": [{join(comparison, ", ")}]
183 "comparison": [{join(comparison, ", ")}]
184 }'
184 }'
185 comparisonblock = '\{
185 comparisonblock = '\{
186 "lines": [{join(lines, ", ")}]
186 "lines": [{join(lines, ", ")}]
187 }'
187 }'
188 comparisonline = '\{
188 comparisonline = '\{
189 "t": {type|json},
189 "t": {type|json},
190 "ln": {leftlineno|json},
190 "ln": {leftlineno|json},
191 "ll": {leftline|json},
191 "ll": {leftline|json},
192 "rn": {rightlineno|json},
192 "rn": {rightlineno|json},
193 "rl": {rightline|json}
193 "rl": {rightline|json}
194 }'
194 }'
195 fileannotate = '\{
195 fileannotate = '\{
196 "abspath": {file|json},
196 "abspath": {file|json},
197 "node": {node|json},
197 "node": {node|json},
198 "author": {author|utf8|json},
198 "author": {author|utf8|json},
199 "date": {date|json},
199 "date": {date|json},
200 "desc": {desc|utf8|json},
200 "desc": {desc|utf8|json},
201 "parents": [{join(parent%changesetparent, ", ")}],
201 "parents": [{join(parent%changesetparent, ", ")}],
202 "children": [{join(child%changesetparent, ", ")}],
202 "children": [{join(child%changesetparent, ", ")}],
203 "permissions": {permissions|json},
203 "permissions": {permissions|json},
204 "annotate": [{join(annotate%fileannotation, ", ")}]
204 "annotate": [{join(annotate%fileannotation, ", ")}]
205 }'
205 }'
206 fileannotation = '\{
206 fileannotation = '\{
207 "node": {node|json},
207 "node": {node|json},
208 "author": {author|utf8|json},
208 "author": {author|utf8|json},
209 "desc": {desc|utf8|json},
209 "desc": {desc|utf8|json},
210 "abspath": {file|json},
210 "abspath": {file|json},
211 "targetline": {targetline|json},
211 "targetline": {targetline|json},
212 "line": {line|json},
212 "line": {line|json},
213 "lineno": {lineno|json},
213 "lineno": {lineno|json},
214 "revdate": {revdate|json}
214 "revdate": {revdate|json}
215 }'
215 }'
216 filelog = '\{
216 filelog = '\{
217 "entries": [{join(entries%changelistentry, ", ")}]
217 "entries": [{join(entries%changelistentry, ", ")}]
218 }'
218 }'
219 helptopics = '\{
219 helptopics = '\{
220 "topics": [{join(topics%helptopicentry, ", ")}],
220 "topics": [{join(topics%helptopicentry, ", ")}],
221 "earlycommands": [{join(earlycommands%helptopicentry, ", ")}],
221 "earlycommands": [{join(earlycommands%helptopicentry, ", ")}],
222 "othercommands": [{join(othercommands%helptopicentry, ", ")}]
222 "othercommands": [{join(othercommands%helptopicentry, ", ")}]
223 }'
223 }'
224 helptopicentry = '\{
224 helptopicentry = '\{
225 "topic": {topic|utf8|json},
225 "topic": {topic|utf8|json},
226 "summary": {summary|utf8|json}
226 "summary": {summary|utf8|json}
227 }'
227 }'
228 help = '\{
228 help = '\{
229 "topic": {topic|utf8|json},
229 "topic": {topic|utf8|json},
230 "rawdoc": {doc|utf8|json}
230 "rawdoc": {doc|utf8|json}
231 }'
231 }'
232 filenodelink = ''
232 filenodelink = ''
233 filenolink = ''
233 filenolink = ''
234 index = '\{
234 index = '\{
235 "entries": [{join(entries%indexentry, ", ")}]
235 "entries": [{join(entries%indexentry, ", ")}]
236 }'
236 }'
237 indexentry = '\{
237 indexentry = '\{
238 "name": {name|utf8|json},
238 "name": {name|utf8|json},
239 "description": {description|utf8|json},
239 "description": {description|utf8|json},
240 "contact": {contact|utf8|json},
240 "contact": {contact|utf8|json},
241 "lastchange": {lastchange|json},
241 "lastchange": {lastchange|json},
242 "labels": {labels|json}
242 "labels": {labels|json}
243 }'
243 }'
244 error = '\{
245 "error": {error|utf8|json}
246 }'
@@ -1,2209 +1,2219 b''
1 #require serve
1 #require serve
2
2
3 $ request() {
3 $ request() {
4 > get-with-headers.py --json localhost:$HGPORT "$1"
4 > get-with-headers.py --json localhost:$HGPORT "$1"
5 > }
5 > }
6
6
7 $ hg init test
7 $ hg init test
8 $ cd test
8 $ cd test
9 $ mkdir da
9 $ mkdir da
10 $ echo foo > da/foo
10 $ echo foo > da/foo
11 $ echo foo > foo
11 $ echo foo > foo
12 $ hg -q ci -A -m initial
12 $ hg -q ci -A -m initial
13 $ echo bar > foo
13 $ echo bar > foo
14 $ hg ci -m 'modify foo'
14 $ hg ci -m 'modify foo'
15 $ echo bar > da/foo
15 $ echo bar > da/foo
16 $ hg ci -m 'modify da/foo'
16 $ hg ci -m 'modify da/foo'
17 $ hg bookmark bookmark1
17 $ hg bookmark bookmark1
18 $ hg up default
18 $ hg up default
19 0 files updated, 0 files merged, 0 files removed, 0 files unresolved
19 0 files updated, 0 files merged, 0 files removed, 0 files unresolved
20 (leaving bookmark bookmark1)
20 (leaving bookmark bookmark1)
21 $ hg mv foo foo-new
21 $ hg mv foo foo-new
22 $ hg commit -m 'move foo'
22 $ hg commit -m 'move foo'
23 $ hg tag -m 'create tag' tag1
23 $ hg tag -m 'create tag' tag1
24 $ hg phase --public -r .
24 $ hg phase --public -r .
25 $ echo baz > da/foo
25 $ echo baz > da/foo
26 $ hg commit -m 'another commit to da/foo'
26 $ hg commit -m 'another commit to da/foo'
27 $ hg tag -m 'create tag2' tag2
27 $ hg tag -m 'create tag2' tag2
28 $ hg bookmark bookmark2
28 $ hg bookmark bookmark2
29 $ hg -q up -r 0
29 $ hg -q up -r 0
30 $ hg -q branch test-branch
30 $ hg -q branch test-branch
31 $ echo branch > foo
31 $ echo branch > foo
32 $ hg commit -m 'create test branch'
32 $ hg commit -m 'create test branch'
33 $ echo branch_commit_2 > foo
33 $ echo branch_commit_2 > foo
34 $ hg commit -m 'another commit in test-branch'
34 $ hg commit -m 'another commit in test-branch'
35 $ hg -q up default
35 $ hg -q up default
36 $ hg merge --tool :local test-branch
36 $ hg merge --tool :local test-branch
37 0 files updated, 1 files merged, 0 files removed, 0 files unresolved
37 0 files updated, 1 files merged, 0 files removed, 0 files unresolved
38 (branch merge, don't forget to commit)
38 (branch merge, don't forget to commit)
39 $ hg commit -m 'merge test-branch into default'
39 $ hg commit -m 'merge test-branch into default'
40
40
41 $ hg log -G
41 $ hg log -G
42 @ changeset: 9:cc725e08502a
42 @ changeset: 9:cc725e08502a
43 |\ tag: tip
43 |\ tag: tip
44 | | parent: 6:ceed296fe500
44 | | parent: 6:ceed296fe500
45 | | parent: 8:ed66c30e87eb
45 | | parent: 8:ed66c30e87eb
46 | | user: test
46 | | user: test
47 | | date: Thu Jan 01 00:00:00 1970 +0000
47 | | date: Thu Jan 01 00:00:00 1970 +0000
48 | | summary: merge test-branch into default
48 | | summary: merge test-branch into default
49 | |
49 | |
50 | o changeset: 8:ed66c30e87eb
50 | o changeset: 8:ed66c30e87eb
51 | | branch: test-branch
51 | | branch: test-branch
52 | | user: test
52 | | user: test
53 | | date: Thu Jan 01 00:00:00 1970 +0000
53 | | date: Thu Jan 01 00:00:00 1970 +0000
54 | | summary: another commit in test-branch
54 | | summary: another commit in test-branch
55 | |
55 | |
56 | o changeset: 7:6ab967a8ab34
56 | o changeset: 7:6ab967a8ab34
57 | | branch: test-branch
57 | | branch: test-branch
58 | | parent: 0:06e557f3edf6
58 | | parent: 0:06e557f3edf6
59 | | user: test
59 | | user: test
60 | | date: Thu Jan 01 00:00:00 1970 +0000
60 | | date: Thu Jan 01 00:00:00 1970 +0000
61 | | summary: create test branch
61 | | summary: create test branch
62 | |
62 | |
63 o | changeset: 6:ceed296fe500
63 o | changeset: 6:ceed296fe500
64 | | bookmark: bookmark2
64 | | bookmark: bookmark2
65 | | user: test
65 | | user: test
66 | | date: Thu Jan 01 00:00:00 1970 +0000
66 | | date: Thu Jan 01 00:00:00 1970 +0000
67 | | summary: create tag2
67 | | summary: create tag2
68 | |
68 | |
69 o | changeset: 5:f2890a05fea4
69 o | changeset: 5:f2890a05fea4
70 | | tag: tag2
70 | | tag: tag2
71 | | user: test
71 | | user: test
72 | | date: Thu Jan 01 00:00:00 1970 +0000
72 | | date: Thu Jan 01 00:00:00 1970 +0000
73 | | summary: another commit to da/foo
73 | | summary: another commit to da/foo
74 | |
74 | |
75 o | changeset: 4:93a8ce14f891
75 o | changeset: 4:93a8ce14f891
76 | | user: test
76 | | user: test
77 | | date: Thu Jan 01 00:00:00 1970 +0000
77 | | date: Thu Jan 01 00:00:00 1970 +0000
78 | | summary: create tag
78 | | summary: create tag
79 | |
79 | |
80 o | changeset: 3:78896eb0e102
80 o | changeset: 3:78896eb0e102
81 | | tag: tag1
81 | | tag: tag1
82 | | user: test
82 | | user: test
83 | | date: Thu Jan 01 00:00:00 1970 +0000
83 | | date: Thu Jan 01 00:00:00 1970 +0000
84 | | summary: move foo
84 | | summary: move foo
85 | |
85 | |
86 o | changeset: 2:8d7c456572ac
86 o | changeset: 2:8d7c456572ac
87 | | bookmark: bookmark1
87 | | bookmark: bookmark1
88 | | user: test
88 | | user: test
89 | | date: Thu Jan 01 00:00:00 1970 +0000
89 | | date: Thu Jan 01 00:00:00 1970 +0000
90 | | summary: modify da/foo
90 | | summary: modify da/foo
91 | |
91 | |
92 o | changeset: 1:f8bbb9024b10
92 o | changeset: 1:f8bbb9024b10
93 |/ user: test
93 |/ user: test
94 | date: Thu Jan 01 00:00:00 1970 +0000
94 | date: Thu Jan 01 00:00:00 1970 +0000
95 | summary: modify foo
95 | summary: modify foo
96 |
96 |
97 o changeset: 0:06e557f3edf6
97 o changeset: 0:06e557f3edf6
98 user: test
98 user: test
99 date: Thu Jan 01 00:00:00 1970 +0000
99 date: Thu Jan 01 00:00:00 1970 +0000
100 summary: initial
100 summary: initial
101
101
102
102
103 $ echo '[web]' >> .hg/hgrc
103 $ echo '[web]' >> .hg/hgrc
104 $ echo 'allow-archive = bz2' >> .hg/hgrc
104 $ echo 'allow-archive = bz2' >> .hg/hgrc
105 $ hg serve -p $HGPORT -d --pid-file=hg.pid -A access.log -E error.log
105 $ hg serve -p $HGPORT -d --pid-file=hg.pid -A access.log -E error.log
106 $ cat hg.pid >> $DAEMON_PIDS
106 $ cat hg.pid >> $DAEMON_PIDS
107
107
108 (Try to keep these in roughly the order they are defined in webcommands.py)
108 (Try to keep these in roughly the order they are defined in webcommands.py)
109
109
110 (log is handled by filelog/ and changelog/ - ignore it)
110 (log is handled by filelog/ and changelog/ - ignore it)
111
111
112 (rawfile/ doesn't use templating - nothing to test)
112 (rawfile/ doesn't use templating - nothing to test)
113
113
114 file/{revision}/{path} shows file revision
114 file/{revision}/{path} shows file revision
115
115
116 $ request json-file/78896eb0e102/foo-new
116 $ request json-file/78896eb0e102/foo-new
117 200 Script output follows
117 200 Script output follows
118
118
119 {
119 {
120 "bookmarks": [],
120 "bookmarks": [],
121 "branch": "default",
121 "branch": "default",
122 "date": [
122 "date": [
123 0.0,
123 0.0,
124 0
124 0
125 ],
125 ],
126 "desc": "move foo",
126 "desc": "move foo",
127 "lines": [
127 "lines": [
128 {
128 {
129 "line": "bar\n"
129 "line": "bar\n"
130 }
130 }
131 ],
131 ],
132 "node": "78896eb0e102174ce9278438a95e12543e4367a7",
132 "node": "78896eb0e102174ce9278438a95e12543e4367a7",
133 "parents": [
133 "parents": [
134 "f8bbb9024b10f93cdbb8d940337398291d40dea8"
134 "f8bbb9024b10f93cdbb8d940337398291d40dea8"
135 ],
135 ],
136 "path": "foo-new",
136 "path": "foo-new",
137 "phase": "public",
137 "phase": "public",
138 "tags": [
138 "tags": [
139 "tag1"
139 "tag1"
140 ],
140 ],
141 "user": "test"
141 "user": "test"
142 }
142 }
143
143
144 file/{revision} shows root directory info
144 file/{revision} shows root directory info
145
145
146 $ request json-file/cc725e08502a
146 $ request json-file/cc725e08502a
147 200 Script output follows
147 200 Script output follows
148
148
149 {
149 {
150 "abspath": "/",
150 "abspath": "/",
151 "bookmarks": [],
151 "bookmarks": [],
152 "directories": [
152 "directories": [
153 {
153 {
154 "abspath": "/da",
154 "abspath": "/da",
155 "basename": "da",
155 "basename": "da",
156 "emptydirs": ""
156 "emptydirs": ""
157 }
157 }
158 ],
158 ],
159 "files": [
159 "files": [
160 {
160 {
161 "abspath": ".hgtags",
161 "abspath": ".hgtags",
162 "basename": ".hgtags",
162 "basename": ".hgtags",
163 "date": [
163 "date": [
164 0.0,
164 0.0,
165 0
165 0
166 ],
166 ],
167 "flags": "",
167 "flags": "",
168 "size": 92
168 "size": 92
169 },
169 },
170 {
170 {
171 "abspath": "foo-new",
171 "abspath": "foo-new",
172 "basename": "foo-new",
172 "basename": "foo-new",
173 "date": [
173 "date": [
174 0.0,
174 0.0,
175 0
175 0
176 ],
176 ],
177 "flags": "",
177 "flags": "",
178 "size": 4
178 "size": 4
179 }
179 }
180 ],
180 ],
181 "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7",
181 "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7",
182 "tags": [
182 "tags": [
183 "tip"
183 "tip"
184 ]
184 ]
185 }
185 }
186
186
187 changelog/ shows information about several changesets
187 changelog/ shows information about several changesets
188
188
189 $ request json-changelog
189 $ request json-changelog
190 200 Script output follows
190 200 Script output follows
191
191
192 {
192 {
193 "changeset_count": 10,
193 "changeset_count": 10,
194 "changesets": [
194 "changesets": [
195 {
195 {
196 "bookmarks": [],
196 "bookmarks": [],
197 "branch": "default",
197 "branch": "default",
198 "date": [
198 "date": [
199 0.0,
199 0.0,
200 0
200 0
201 ],
201 ],
202 "desc": "merge test-branch into default",
202 "desc": "merge test-branch into default",
203 "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7",
203 "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7",
204 "parents": [
204 "parents": [
205 "ceed296fe500c3fac9541e31dad860cb49c89e45",
205 "ceed296fe500c3fac9541e31dad860cb49c89e45",
206 "ed66c30e87eb65337c05a4229efaa5f1d5285a90"
206 "ed66c30e87eb65337c05a4229efaa5f1d5285a90"
207 ],
207 ],
208 "phase": "draft",
208 "phase": "draft",
209 "tags": [
209 "tags": [
210 "tip"
210 "tip"
211 ],
211 ],
212 "user": "test"
212 "user": "test"
213 },
213 },
214 {
214 {
215 "bookmarks": [],
215 "bookmarks": [],
216 "branch": "test-branch",
216 "branch": "test-branch",
217 "date": [
217 "date": [
218 0.0,
218 0.0,
219 0
219 0
220 ],
220 ],
221 "desc": "another commit in test-branch",
221 "desc": "another commit in test-branch",
222 "node": "ed66c30e87eb65337c05a4229efaa5f1d5285a90",
222 "node": "ed66c30e87eb65337c05a4229efaa5f1d5285a90",
223 "parents": [
223 "parents": [
224 "6ab967a8ab3489227a83f80e920faa039a71819f"
224 "6ab967a8ab3489227a83f80e920faa039a71819f"
225 ],
225 ],
226 "phase": "draft",
226 "phase": "draft",
227 "tags": [],
227 "tags": [],
228 "user": "test"
228 "user": "test"
229 },
229 },
230 {
230 {
231 "bookmarks": [],
231 "bookmarks": [],
232 "branch": "test-branch",
232 "branch": "test-branch",
233 "date": [
233 "date": [
234 0.0,
234 0.0,
235 0
235 0
236 ],
236 ],
237 "desc": "create test branch",
237 "desc": "create test branch",
238 "node": "6ab967a8ab3489227a83f80e920faa039a71819f",
238 "node": "6ab967a8ab3489227a83f80e920faa039a71819f",
239 "parents": [
239 "parents": [
240 "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e"
240 "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e"
241 ],
241 ],
242 "phase": "draft",
242 "phase": "draft",
243 "tags": [],
243 "tags": [],
244 "user": "test"
244 "user": "test"
245 },
245 },
246 {
246 {
247 "bookmarks": [
247 "bookmarks": [
248 "bookmark2"
248 "bookmark2"
249 ],
249 ],
250 "branch": "default",
250 "branch": "default",
251 "date": [
251 "date": [
252 0.0,
252 0.0,
253 0
253 0
254 ],
254 ],
255 "desc": "create tag2",
255 "desc": "create tag2",
256 "node": "ceed296fe500c3fac9541e31dad860cb49c89e45",
256 "node": "ceed296fe500c3fac9541e31dad860cb49c89e45",
257 "parents": [
257 "parents": [
258 "f2890a05fea49bfaf9fb27ed5490894eba32da78"
258 "f2890a05fea49bfaf9fb27ed5490894eba32da78"
259 ],
259 ],
260 "phase": "draft",
260 "phase": "draft",
261 "tags": [],
261 "tags": [],
262 "user": "test"
262 "user": "test"
263 },
263 },
264 {
264 {
265 "bookmarks": [],
265 "bookmarks": [],
266 "branch": "default",
266 "branch": "default",
267 "date": [
267 "date": [
268 0.0,
268 0.0,
269 0
269 0
270 ],
270 ],
271 "desc": "another commit to da/foo",
271 "desc": "another commit to da/foo",
272 "node": "f2890a05fea49bfaf9fb27ed5490894eba32da78",
272 "node": "f2890a05fea49bfaf9fb27ed5490894eba32da78",
273 "parents": [
273 "parents": [
274 "93a8ce14f89156426b7fa981af8042da53f03aa0"
274 "93a8ce14f89156426b7fa981af8042da53f03aa0"
275 ],
275 ],
276 "phase": "draft",
276 "phase": "draft",
277 "tags": [
277 "tags": [
278 "tag2"
278 "tag2"
279 ],
279 ],
280 "user": "test"
280 "user": "test"
281 },
281 },
282 {
282 {
283 "bookmarks": [],
283 "bookmarks": [],
284 "branch": "default",
284 "branch": "default",
285 "date": [
285 "date": [
286 0.0,
286 0.0,
287 0
287 0
288 ],
288 ],
289 "desc": "create tag",
289 "desc": "create tag",
290 "node": "93a8ce14f89156426b7fa981af8042da53f03aa0",
290 "node": "93a8ce14f89156426b7fa981af8042da53f03aa0",
291 "parents": [
291 "parents": [
292 "78896eb0e102174ce9278438a95e12543e4367a7"
292 "78896eb0e102174ce9278438a95e12543e4367a7"
293 ],
293 ],
294 "phase": "public",
294 "phase": "public",
295 "tags": [],
295 "tags": [],
296 "user": "test"
296 "user": "test"
297 },
297 },
298 {
298 {
299 "bookmarks": [],
299 "bookmarks": [],
300 "branch": "default",
300 "branch": "default",
301 "date": [
301 "date": [
302 0.0,
302 0.0,
303 0
303 0
304 ],
304 ],
305 "desc": "move foo",
305 "desc": "move foo",
306 "node": "78896eb0e102174ce9278438a95e12543e4367a7",
306 "node": "78896eb0e102174ce9278438a95e12543e4367a7",
307 "parents": [
307 "parents": [
308 "8d7c456572acf3557e8ed8a07286b10c408bcec5"
308 "8d7c456572acf3557e8ed8a07286b10c408bcec5"
309 ],
309 ],
310 "phase": "public",
310 "phase": "public",
311 "tags": [
311 "tags": [
312 "tag1"
312 "tag1"
313 ],
313 ],
314 "user": "test"
314 "user": "test"
315 },
315 },
316 {
316 {
317 "bookmarks": [
317 "bookmarks": [
318 "bookmark1"
318 "bookmark1"
319 ],
319 ],
320 "branch": "default",
320 "branch": "default",
321 "date": [
321 "date": [
322 0.0,
322 0.0,
323 0
323 0
324 ],
324 ],
325 "desc": "modify da/foo",
325 "desc": "modify da/foo",
326 "node": "8d7c456572acf3557e8ed8a07286b10c408bcec5",
326 "node": "8d7c456572acf3557e8ed8a07286b10c408bcec5",
327 "parents": [
327 "parents": [
328 "f8bbb9024b10f93cdbb8d940337398291d40dea8"
328 "f8bbb9024b10f93cdbb8d940337398291d40dea8"
329 ],
329 ],
330 "phase": "public",
330 "phase": "public",
331 "tags": [],
331 "tags": [],
332 "user": "test"
332 "user": "test"
333 },
333 },
334 {
334 {
335 "bookmarks": [],
335 "bookmarks": [],
336 "branch": "default",
336 "branch": "default",
337 "date": [
337 "date": [
338 0.0,
338 0.0,
339 0
339 0
340 ],
340 ],
341 "desc": "modify foo",
341 "desc": "modify foo",
342 "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8",
342 "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8",
343 "parents": [
343 "parents": [
344 "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e"
344 "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e"
345 ],
345 ],
346 "phase": "public",
346 "phase": "public",
347 "tags": [],
347 "tags": [],
348 "user": "test"
348 "user": "test"
349 },
349 },
350 {
350 {
351 "bookmarks": [],
351 "bookmarks": [],
352 "branch": "default",
352 "branch": "default",
353 "date": [
353 "date": [
354 0.0,
354 0.0,
355 0
355 0
356 ],
356 ],
357 "desc": "initial",
357 "desc": "initial",
358 "node": "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e",
358 "node": "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e",
359 "parents": [],
359 "parents": [],
360 "phase": "public",
360 "phase": "public",
361 "tags": [],
361 "tags": [],
362 "user": "test"
362 "user": "test"
363 }
363 }
364 ],
364 ],
365 "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7"
365 "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7"
366 }
366 }
367
367
368 changelog/{revision} shows information starting at a specific changeset
368 changelog/{revision} shows information starting at a specific changeset
369
369
370 $ request json-changelog/f8bbb9024b10
370 $ request json-changelog/f8bbb9024b10
371 200 Script output follows
371 200 Script output follows
372
372
373 {
373 {
374 "changeset_count": 10,
374 "changeset_count": 10,
375 "changesets": [
375 "changesets": [
376 {
376 {
377 "bookmarks": [],
377 "bookmarks": [],
378 "branch": "default",
378 "branch": "default",
379 "date": [
379 "date": [
380 0.0,
380 0.0,
381 0
381 0
382 ],
382 ],
383 "desc": "modify foo",
383 "desc": "modify foo",
384 "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8",
384 "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8",
385 "parents": [
385 "parents": [
386 "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e"
386 "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e"
387 ],
387 ],
388 "phase": "public",
388 "phase": "public",
389 "tags": [],
389 "tags": [],
390 "user": "test"
390 "user": "test"
391 },
391 },
392 {
392 {
393 "bookmarks": [],
393 "bookmarks": [],
394 "branch": "default",
394 "branch": "default",
395 "date": [
395 "date": [
396 0.0,
396 0.0,
397 0
397 0
398 ],
398 ],
399 "desc": "initial",
399 "desc": "initial",
400 "node": "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e",
400 "node": "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e",
401 "parents": [],
401 "parents": [],
402 "phase": "public",
402 "phase": "public",
403 "tags": [],
403 "tags": [],
404 "user": "test"
404 "user": "test"
405 }
405 }
406 ],
406 ],
407 "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8"
407 "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8"
408 }
408 }
409
409
410 shortlog/ shows information about a set of changesets
410 shortlog/ shows information about a set of changesets
411
411
412 $ request json-shortlog
412 $ request json-shortlog
413 200 Script output follows
413 200 Script output follows
414
414
415 {
415 {
416 "changeset_count": 10,
416 "changeset_count": 10,
417 "changesets": [
417 "changesets": [
418 {
418 {
419 "bookmarks": [],
419 "bookmarks": [],
420 "branch": "default",
420 "branch": "default",
421 "date": [
421 "date": [
422 0.0,
422 0.0,
423 0
423 0
424 ],
424 ],
425 "desc": "merge test-branch into default",
425 "desc": "merge test-branch into default",
426 "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7",
426 "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7",
427 "parents": [
427 "parents": [
428 "ceed296fe500c3fac9541e31dad860cb49c89e45",
428 "ceed296fe500c3fac9541e31dad860cb49c89e45",
429 "ed66c30e87eb65337c05a4229efaa5f1d5285a90"
429 "ed66c30e87eb65337c05a4229efaa5f1d5285a90"
430 ],
430 ],
431 "phase": "draft",
431 "phase": "draft",
432 "tags": [
432 "tags": [
433 "tip"
433 "tip"
434 ],
434 ],
435 "user": "test"
435 "user": "test"
436 },
436 },
437 {
437 {
438 "bookmarks": [],
438 "bookmarks": [],
439 "branch": "test-branch",
439 "branch": "test-branch",
440 "date": [
440 "date": [
441 0.0,
441 0.0,
442 0
442 0
443 ],
443 ],
444 "desc": "another commit in test-branch",
444 "desc": "another commit in test-branch",
445 "node": "ed66c30e87eb65337c05a4229efaa5f1d5285a90",
445 "node": "ed66c30e87eb65337c05a4229efaa5f1d5285a90",
446 "parents": [
446 "parents": [
447 "6ab967a8ab3489227a83f80e920faa039a71819f"
447 "6ab967a8ab3489227a83f80e920faa039a71819f"
448 ],
448 ],
449 "phase": "draft",
449 "phase": "draft",
450 "tags": [],
450 "tags": [],
451 "user": "test"
451 "user": "test"
452 },
452 },
453 {
453 {
454 "bookmarks": [],
454 "bookmarks": [],
455 "branch": "test-branch",
455 "branch": "test-branch",
456 "date": [
456 "date": [
457 0.0,
457 0.0,
458 0
458 0
459 ],
459 ],
460 "desc": "create test branch",
460 "desc": "create test branch",
461 "node": "6ab967a8ab3489227a83f80e920faa039a71819f",
461 "node": "6ab967a8ab3489227a83f80e920faa039a71819f",
462 "parents": [
462 "parents": [
463 "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e"
463 "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e"
464 ],
464 ],
465 "phase": "draft",
465 "phase": "draft",
466 "tags": [],
466 "tags": [],
467 "user": "test"
467 "user": "test"
468 },
468 },
469 {
469 {
470 "bookmarks": [
470 "bookmarks": [
471 "bookmark2"
471 "bookmark2"
472 ],
472 ],
473 "branch": "default",
473 "branch": "default",
474 "date": [
474 "date": [
475 0.0,
475 0.0,
476 0
476 0
477 ],
477 ],
478 "desc": "create tag2",
478 "desc": "create tag2",
479 "node": "ceed296fe500c3fac9541e31dad860cb49c89e45",
479 "node": "ceed296fe500c3fac9541e31dad860cb49c89e45",
480 "parents": [
480 "parents": [
481 "f2890a05fea49bfaf9fb27ed5490894eba32da78"
481 "f2890a05fea49bfaf9fb27ed5490894eba32da78"
482 ],
482 ],
483 "phase": "draft",
483 "phase": "draft",
484 "tags": [],
484 "tags": [],
485 "user": "test"
485 "user": "test"
486 },
486 },
487 {
487 {
488 "bookmarks": [],
488 "bookmarks": [],
489 "branch": "default",
489 "branch": "default",
490 "date": [
490 "date": [
491 0.0,
491 0.0,
492 0
492 0
493 ],
493 ],
494 "desc": "another commit to da/foo",
494 "desc": "another commit to da/foo",
495 "node": "f2890a05fea49bfaf9fb27ed5490894eba32da78",
495 "node": "f2890a05fea49bfaf9fb27ed5490894eba32da78",
496 "parents": [
496 "parents": [
497 "93a8ce14f89156426b7fa981af8042da53f03aa0"
497 "93a8ce14f89156426b7fa981af8042da53f03aa0"
498 ],
498 ],
499 "phase": "draft",
499 "phase": "draft",
500 "tags": [
500 "tags": [
501 "tag2"
501 "tag2"
502 ],
502 ],
503 "user": "test"
503 "user": "test"
504 },
504 },
505 {
505 {
506 "bookmarks": [],
506 "bookmarks": [],
507 "branch": "default",
507 "branch": "default",
508 "date": [
508 "date": [
509 0.0,
509 0.0,
510 0
510 0
511 ],
511 ],
512 "desc": "create tag",
512 "desc": "create tag",
513 "node": "93a8ce14f89156426b7fa981af8042da53f03aa0",
513 "node": "93a8ce14f89156426b7fa981af8042da53f03aa0",
514 "parents": [
514 "parents": [
515 "78896eb0e102174ce9278438a95e12543e4367a7"
515 "78896eb0e102174ce9278438a95e12543e4367a7"
516 ],
516 ],
517 "phase": "public",
517 "phase": "public",
518 "tags": [],
518 "tags": [],
519 "user": "test"
519 "user": "test"
520 },
520 },
521 {
521 {
522 "bookmarks": [],
522 "bookmarks": [],
523 "branch": "default",
523 "branch": "default",
524 "date": [
524 "date": [
525 0.0,
525 0.0,
526 0
526 0
527 ],
527 ],
528 "desc": "move foo",
528 "desc": "move foo",
529 "node": "78896eb0e102174ce9278438a95e12543e4367a7",
529 "node": "78896eb0e102174ce9278438a95e12543e4367a7",
530 "parents": [
530 "parents": [
531 "8d7c456572acf3557e8ed8a07286b10c408bcec5"
531 "8d7c456572acf3557e8ed8a07286b10c408bcec5"
532 ],
532 ],
533 "phase": "public",
533 "phase": "public",
534 "tags": [
534 "tags": [
535 "tag1"
535 "tag1"
536 ],
536 ],
537 "user": "test"
537 "user": "test"
538 },
538 },
539 {
539 {
540 "bookmarks": [
540 "bookmarks": [
541 "bookmark1"
541 "bookmark1"
542 ],
542 ],
543 "branch": "default",
543 "branch": "default",
544 "date": [
544 "date": [
545 0.0,
545 0.0,
546 0
546 0
547 ],
547 ],
548 "desc": "modify da/foo",
548 "desc": "modify da/foo",
549 "node": "8d7c456572acf3557e8ed8a07286b10c408bcec5",
549 "node": "8d7c456572acf3557e8ed8a07286b10c408bcec5",
550 "parents": [
550 "parents": [
551 "f8bbb9024b10f93cdbb8d940337398291d40dea8"
551 "f8bbb9024b10f93cdbb8d940337398291d40dea8"
552 ],
552 ],
553 "phase": "public",
553 "phase": "public",
554 "tags": [],
554 "tags": [],
555 "user": "test"
555 "user": "test"
556 },
556 },
557 {
557 {
558 "bookmarks": [],
558 "bookmarks": [],
559 "branch": "default",
559 "branch": "default",
560 "date": [
560 "date": [
561 0.0,
561 0.0,
562 0
562 0
563 ],
563 ],
564 "desc": "modify foo",
564 "desc": "modify foo",
565 "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8",
565 "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8",
566 "parents": [
566 "parents": [
567 "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e"
567 "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e"
568 ],
568 ],
569 "phase": "public",
569 "phase": "public",
570 "tags": [],
570 "tags": [],
571 "user": "test"
571 "user": "test"
572 },
572 },
573 {
573 {
574 "bookmarks": [],
574 "bookmarks": [],
575 "branch": "default",
575 "branch": "default",
576 "date": [
576 "date": [
577 0.0,
577 0.0,
578 0
578 0
579 ],
579 ],
580 "desc": "initial",
580 "desc": "initial",
581 "node": "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e",
581 "node": "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e",
582 "parents": [],
582 "parents": [],
583 "phase": "public",
583 "phase": "public",
584 "tags": [],
584 "tags": [],
585 "user": "test"
585 "user": "test"
586 }
586 }
587 ],
587 ],
588 "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7"
588 "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7"
589 }
589 }
590
590
591 shortlog is displayed by default (issue5978)
591 shortlog is displayed by default (issue5978)
592
592
593 $ request '?style=json'
593 $ request '?style=json'
594 200 Script output follows
594 200 Script output follows
595
595
596 {
596 {
597 "changeset_count": 10,
597 "changeset_count": 10,
598 "changesets": [
598 "changesets": [
599 {
599 {
600 "bookmarks": [],
600 "bookmarks": [],
601 "branch": "default",
601 "branch": "default",
602 "date": [
602 "date": [
603 0.0,
603 0.0,
604 0
604 0
605 ],
605 ],
606 "desc": "merge test-branch into default",
606 "desc": "merge test-branch into default",
607 "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7",
607 "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7",
608 "parents": [
608 "parents": [
609 "ceed296fe500c3fac9541e31dad860cb49c89e45",
609 "ceed296fe500c3fac9541e31dad860cb49c89e45",
610 "ed66c30e87eb65337c05a4229efaa5f1d5285a90"
610 "ed66c30e87eb65337c05a4229efaa5f1d5285a90"
611 ],
611 ],
612 "phase": "draft",
612 "phase": "draft",
613 "tags": [
613 "tags": [
614 "tip"
614 "tip"
615 ],
615 ],
616 "user": "test"
616 "user": "test"
617 },
617 },
618 {
618 {
619 "bookmarks": [],
619 "bookmarks": [],
620 "branch": "test-branch",
620 "branch": "test-branch",
621 "date": [
621 "date": [
622 0.0,
622 0.0,
623 0
623 0
624 ],
624 ],
625 "desc": "another commit in test-branch",
625 "desc": "another commit in test-branch",
626 "node": "ed66c30e87eb65337c05a4229efaa5f1d5285a90",
626 "node": "ed66c30e87eb65337c05a4229efaa5f1d5285a90",
627 "parents": [
627 "parents": [
628 "6ab967a8ab3489227a83f80e920faa039a71819f"
628 "6ab967a8ab3489227a83f80e920faa039a71819f"
629 ],
629 ],
630 "phase": "draft",
630 "phase": "draft",
631 "tags": [],
631 "tags": [],
632 "user": "test"
632 "user": "test"
633 },
633 },
634 {
634 {
635 "bookmarks": [],
635 "bookmarks": [],
636 "branch": "test-branch",
636 "branch": "test-branch",
637 "date": [
637 "date": [
638 0.0,
638 0.0,
639 0
639 0
640 ],
640 ],
641 "desc": "create test branch",
641 "desc": "create test branch",
642 "node": "6ab967a8ab3489227a83f80e920faa039a71819f",
642 "node": "6ab967a8ab3489227a83f80e920faa039a71819f",
643 "parents": [
643 "parents": [
644 "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e"
644 "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e"
645 ],
645 ],
646 "phase": "draft",
646 "phase": "draft",
647 "tags": [],
647 "tags": [],
648 "user": "test"
648 "user": "test"
649 },
649 },
650 {
650 {
651 "bookmarks": [
651 "bookmarks": [
652 "bookmark2"
652 "bookmark2"
653 ],
653 ],
654 "branch": "default",
654 "branch": "default",
655 "date": [
655 "date": [
656 0.0,
656 0.0,
657 0
657 0
658 ],
658 ],
659 "desc": "create tag2",
659 "desc": "create tag2",
660 "node": "ceed296fe500c3fac9541e31dad860cb49c89e45",
660 "node": "ceed296fe500c3fac9541e31dad860cb49c89e45",
661 "parents": [
661 "parents": [
662 "f2890a05fea49bfaf9fb27ed5490894eba32da78"
662 "f2890a05fea49bfaf9fb27ed5490894eba32da78"
663 ],
663 ],
664 "phase": "draft",
664 "phase": "draft",
665 "tags": [],
665 "tags": [],
666 "user": "test"
666 "user": "test"
667 },
667 },
668 {
668 {
669 "bookmarks": [],
669 "bookmarks": [],
670 "branch": "default",
670 "branch": "default",
671 "date": [
671 "date": [
672 0.0,
672 0.0,
673 0
673 0
674 ],
674 ],
675 "desc": "another commit to da/foo",
675 "desc": "another commit to da/foo",
676 "node": "f2890a05fea49bfaf9fb27ed5490894eba32da78",
676 "node": "f2890a05fea49bfaf9fb27ed5490894eba32da78",
677 "parents": [
677 "parents": [
678 "93a8ce14f89156426b7fa981af8042da53f03aa0"
678 "93a8ce14f89156426b7fa981af8042da53f03aa0"
679 ],
679 ],
680 "phase": "draft",
680 "phase": "draft",
681 "tags": [
681 "tags": [
682 "tag2"
682 "tag2"
683 ],
683 ],
684 "user": "test"
684 "user": "test"
685 },
685 },
686 {
686 {
687 "bookmarks": [],
687 "bookmarks": [],
688 "branch": "default",
688 "branch": "default",
689 "date": [
689 "date": [
690 0.0,
690 0.0,
691 0
691 0
692 ],
692 ],
693 "desc": "create tag",
693 "desc": "create tag",
694 "node": "93a8ce14f89156426b7fa981af8042da53f03aa0",
694 "node": "93a8ce14f89156426b7fa981af8042da53f03aa0",
695 "parents": [
695 "parents": [
696 "78896eb0e102174ce9278438a95e12543e4367a7"
696 "78896eb0e102174ce9278438a95e12543e4367a7"
697 ],
697 ],
698 "phase": "public",
698 "phase": "public",
699 "tags": [],
699 "tags": [],
700 "user": "test"
700 "user": "test"
701 },
701 },
702 {
702 {
703 "bookmarks": [],
703 "bookmarks": [],
704 "branch": "default",
704 "branch": "default",
705 "date": [
705 "date": [
706 0.0,
706 0.0,
707 0
707 0
708 ],
708 ],
709 "desc": "move foo",
709 "desc": "move foo",
710 "node": "78896eb0e102174ce9278438a95e12543e4367a7",
710 "node": "78896eb0e102174ce9278438a95e12543e4367a7",
711 "parents": [
711 "parents": [
712 "8d7c456572acf3557e8ed8a07286b10c408bcec5"
712 "8d7c456572acf3557e8ed8a07286b10c408bcec5"
713 ],
713 ],
714 "phase": "public",
714 "phase": "public",
715 "tags": [
715 "tags": [
716 "tag1"
716 "tag1"
717 ],
717 ],
718 "user": "test"
718 "user": "test"
719 },
719 },
720 {
720 {
721 "bookmarks": [
721 "bookmarks": [
722 "bookmark1"
722 "bookmark1"
723 ],
723 ],
724 "branch": "default",
724 "branch": "default",
725 "date": [
725 "date": [
726 0.0,
726 0.0,
727 0
727 0
728 ],
728 ],
729 "desc": "modify da/foo",
729 "desc": "modify da/foo",
730 "node": "8d7c456572acf3557e8ed8a07286b10c408bcec5",
730 "node": "8d7c456572acf3557e8ed8a07286b10c408bcec5",
731 "parents": [
731 "parents": [
732 "f8bbb9024b10f93cdbb8d940337398291d40dea8"
732 "f8bbb9024b10f93cdbb8d940337398291d40dea8"
733 ],
733 ],
734 "phase": "public",
734 "phase": "public",
735 "tags": [],
735 "tags": [],
736 "user": "test"
736 "user": "test"
737 },
737 },
738 {
738 {
739 "bookmarks": [],
739 "bookmarks": [],
740 "branch": "default",
740 "branch": "default",
741 "date": [
741 "date": [
742 0.0,
742 0.0,
743 0
743 0
744 ],
744 ],
745 "desc": "modify foo",
745 "desc": "modify foo",
746 "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8",
746 "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8",
747 "parents": [
747 "parents": [
748 "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e"
748 "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e"
749 ],
749 ],
750 "phase": "public",
750 "phase": "public",
751 "tags": [],
751 "tags": [],
752 "user": "test"
752 "user": "test"
753 },
753 },
754 {
754 {
755 "bookmarks": [],
755 "bookmarks": [],
756 "branch": "default",
756 "branch": "default",
757 "date": [
757 "date": [
758 0.0,
758 0.0,
759 0
759 0
760 ],
760 ],
761 "desc": "initial",
761 "desc": "initial",
762 "node": "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e",
762 "node": "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e",
763 "parents": [],
763 "parents": [],
764 "phase": "public",
764 "phase": "public",
765 "tags": [],
765 "tags": [],
766 "user": "test"
766 "user": "test"
767 }
767 }
768 ],
768 ],
769 "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7"
769 "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7"
770 }
770 }
771
771
772 changeset/ renders the tip changeset
772 changeset/ renders the tip changeset
773
773
774 $ request json-rev
774 $ request json-rev
775 200 Script output follows
775 200 Script output follows
776
776
777 {
777 {
778 "bookmarks": [],
778 "bookmarks": [],
779 "branch": "default",
779 "branch": "default",
780 "date": [
780 "date": [
781 0.0,
781 0.0,
782 0
782 0
783 ],
783 ],
784 "desc": "merge test-branch into default",
784 "desc": "merge test-branch into default",
785 "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7",
785 "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7",
786 "parents": [
786 "parents": [
787 "ceed296fe500c3fac9541e31dad860cb49c89e45",
787 "ceed296fe500c3fac9541e31dad860cb49c89e45",
788 "ed66c30e87eb65337c05a4229efaa5f1d5285a90"
788 "ed66c30e87eb65337c05a4229efaa5f1d5285a90"
789 ],
789 ],
790 "phase": "draft",
790 "phase": "draft",
791 "tags": [
791 "tags": [
792 "tip"
792 "tip"
793 ],
793 ],
794 "user": "test"
794 "user": "test"
795 }
795 }
796
796
797 changeset/{revision} shows tags
797 changeset/{revision} shows tags
798
798
799 $ request json-rev/78896eb0e102
799 $ request json-rev/78896eb0e102
800 200 Script output follows
800 200 Script output follows
801
801
802 {
802 {
803 "bookmarks": [],
803 "bookmarks": [],
804 "branch": "default",
804 "branch": "default",
805 "date": [
805 "date": [
806 0.0,
806 0.0,
807 0
807 0
808 ],
808 ],
809 "desc": "move foo",
809 "desc": "move foo",
810 "node": "78896eb0e102174ce9278438a95e12543e4367a7",
810 "node": "78896eb0e102174ce9278438a95e12543e4367a7",
811 "parents": [
811 "parents": [
812 "8d7c456572acf3557e8ed8a07286b10c408bcec5"
812 "8d7c456572acf3557e8ed8a07286b10c408bcec5"
813 ],
813 ],
814 "phase": "public",
814 "phase": "public",
815 "tags": [
815 "tags": [
816 "tag1"
816 "tag1"
817 ],
817 ],
818 "user": "test"
818 "user": "test"
819 }
819 }
820
820
821 changeset/{revision} shows bookmarks
821 changeset/{revision} shows bookmarks
822
822
823 $ request json-rev/8d7c456572ac
823 $ request json-rev/8d7c456572ac
824 200 Script output follows
824 200 Script output follows
825
825
826 {
826 {
827 "bookmarks": [
827 "bookmarks": [
828 "bookmark1"
828 "bookmark1"
829 ],
829 ],
830 "branch": "default",
830 "branch": "default",
831 "date": [
831 "date": [
832 0.0,
832 0.0,
833 0
833 0
834 ],
834 ],
835 "desc": "modify da/foo",
835 "desc": "modify da/foo",
836 "node": "8d7c456572acf3557e8ed8a07286b10c408bcec5",
836 "node": "8d7c456572acf3557e8ed8a07286b10c408bcec5",
837 "parents": [
837 "parents": [
838 "f8bbb9024b10f93cdbb8d940337398291d40dea8"
838 "f8bbb9024b10f93cdbb8d940337398291d40dea8"
839 ],
839 ],
840 "phase": "public",
840 "phase": "public",
841 "tags": [],
841 "tags": [],
842 "user": "test"
842 "user": "test"
843 }
843 }
844
844
845 changeset/{revision} shows branches
845 changeset/{revision} shows branches
846
846
847 $ request json-rev/6ab967a8ab34
847 $ request json-rev/6ab967a8ab34
848 200 Script output follows
848 200 Script output follows
849
849
850 {
850 {
851 "bookmarks": [],
851 "bookmarks": [],
852 "branch": "test-branch",
852 "branch": "test-branch",
853 "date": [
853 "date": [
854 0.0,
854 0.0,
855 0
855 0
856 ],
856 ],
857 "desc": "create test branch",
857 "desc": "create test branch",
858 "node": "6ab967a8ab3489227a83f80e920faa039a71819f",
858 "node": "6ab967a8ab3489227a83f80e920faa039a71819f",
859 "parents": [
859 "parents": [
860 "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e"
860 "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e"
861 ],
861 ],
862 "phase": "draft",
862 "phase": "draft",
863 "tags": [],
863 "tags": [],
864 "user": "test"
864 "user": "test"
865 }
865 }
866
866
867 manifest/{revision}/{path} shows info about a directory at a revision
867 manifest/{revision}/{path} shows info about a directory at a revision
868
868
869 $ request json-manifest/06e557f3edf6/
869 $ request json-manifest/06e557f3edf6/
870 200 Script output follows
870 200 Script output follows
871
871
872 {
872 {
873 "abspath": "/",
873 "abspath": "/",
874 "bookmarks": [],
874 "bookmarks": [],
875 "directories": [
875 "directories": [
876 {
876 {
877 "abspath": "/da",
877 "abspath": "/da",
878 "basename": "da",
878 "basename": "da",
879 "emptydirs": ""
879 "emptydirs": ""
880 }
880 }
881 ],
881 ],
882 "files": [
882 "files": [
883 {
883 {
884 "abspath": "foo",
884 "abspath": "foo",
885 "basename": "foo",
885 "basename": "foo",
886 "date": [
886 "date": [
887 0.0,
887 0.0,
888 0
888 0
889 ],
889 ],
890 "flags": "",
890 "flags": "",
891 "size": 4
891 "size": 4
892 }
892 }
893 ],
893 ],
894 "node": "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e",
894 "node": "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e",
895 "tags": []
895 "tags": []
896 }
896 }
897
897
898 tags/ shows tags info
898 tags/ shows tags info
899
899
900 $ request json-tags
900 $ request json-tags
901 200 Script output follows
901 200 Script output follows
902
902
903 {
903 {
904 "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7",
904 "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7",
905 "tags": [
905 "tags": [
906 {
906 {
907 "date": [
907 "date": [
908 0.0,
908 0.0,
909 0
909 0
910 ],
910 ],
911 "node": "f2890a05fea49bfaf9fb27ed5490894eba32da78",
911 "node": "f2890a05fea49bfaf9fb27ed5490894eba32da78",
912 "tag": "tag2"
912 "tag": "tag2"
913 },
913 },
914 {
914 {
915 "date": [
915 "date": [
916 0.0,
916 0.0,
917 0
917 0
918 ],
918 ],
919 "node": "78896eb0e102174ce9278438a95e12543e4367a7",
919 "node": "78896eb0e102174ce9278438a95e12543e4367a7",
920 "tag": "tag1"
920 "tag": "tag1"
921 }
921 }
922 ]
922 ]
923 }
923 }
924
924
925 bookmarks/ shows bookmarks info
925 bookmarks/ shows bookmarks info
926
926
927 $ request json-bookmarks
927 $ request json-bookmarks
928 200 Script output follows
928 200 Script output follows
929
929
930 {
930 {
931 "bookmarks": [
931 "bookmarks": [
932 {
932 {
933 "bookmark": "bookmark2",
933 "bookmark": "bookmark2",
934 "date": [
934 "date": [
935 0.0,
935 0.0,
936 0
936 0
937 ],
937 ],
938 "node": "ceed296fe500c3fac9541e31dad860cb49c89e45"
938 "node": "ceed296fe500c3fac9541e31dad860cb49c89e45"
939 },
939 },
940 {
940 {
941 "bookmark": "bookmark1",
941 "bookmark": "bookmark1",
942 "date": [
942 "date": [
943 0.0,
943 0.0,
944 0
944 0
945 ],
945 ],
946 "node": "8d7c456572acf3557e8ed8a07286b10c408bcec5"
946 "node": "8d7c456572acf3557e8ed8a07286b10c408bcec5"
947 }
947 }
948 ],
948 ],
949 "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7"
949 "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7"
950 }
950 }
951
951
952 branches/ shows branches info
952 branches/ shows branches info
953
953
954 $ request json-branches
954 $ request json-branches
955 200 Script output follows
955 200 Script output follows
956
956
957 {
957 {
958 "branches": [
958 "branches": [
959 {
959 {
960 "branch": "default",
960 "branch": "default",
961 "date": [
961 "date": [
962 0.0,
962 0.0,
963 0
963 0
964 ],
964 ],
965 "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7",
965 "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7",
966 "status": "open"
966 "status": "open"
967 },
967 },
968 {
968 {
969 "branch": "test-branch",
969 "branch": "test-branch",
970 "date": [
970 "date": [
971 0.0,
971 0.0,
972 0
972 0
973 ],
973 ],
974 "node": "ed66c30e87eb65337c05a4229efaa5f1d5285a90",
974 "node": "ed66c30e87eb65337c05a4229efaa5f1d5285a90",
975 "status": "inactive"
975 "status": "inactive"
976 }
976 }
977 ]
977 ]
978 }
978 }
979
979
980 summary/ shows a summary of repository state
980 summary/ shows a summary of repository state
981
981
982 $ request json-summary
982 $ request json-summary
983 200 Script output follows
983 200 Script output follows
984
984
985 {
985 {
986 "archives": [
986 "archives": [
987 {
987 {
988 "extension": ".tar.bz2",
988 "extension": ".tar.bz2",
989 "node": "tip",
989 "node": "tip",
990 "type": "bz2",
990 "type": "bz2",
991 "url": "http://*:$HGPORT/archive/tip.tar.bz2" (glob)
991 "url": "http://*:$HGPORT/archive/tip.tar.bz2" (glob)
992 }
992 }
993 ],
993 ],
994 "bookmarks": [
994 "bookmarks": [
995 {
995 {
996 "bookmark": "bookmark2",
996 "bookmark": "bookmark2",
997 "date": [
997 "date": [
998 0.0,
998 0.0,
999 0
999 0
1000 ],
1000 ],
1001 "node": "ceed296fe500c3fac9541e31dad860cb49c89e45"
1001 "node": "ceed296fe500c3fac9541e31dad860cb49c89e45"
1002 },
1002 },
1003 {
1003 {
1004 "bookmark": "bookmark1",
1004 "bookmark": "bookmark1",
1005 "date": [
1005 "date": [
1006 0.0,
1006 0.0,
1007 0
1007 0
1008 ],
1008 ],
1009 "node": "8d7c456572acf3557e8ed8a07286b10c408bcec5"
1009 "node": "8d7c456572acf3557e8ed8a07286b10c408bcec5"
1010 }
1010 }
1011 ],
1011 ],
1012 "branches": [
1012 "branches": [
1013 {
1013 {
1014 "branch": "default",
1014 "branch": "default",
1015 "date": [
1015 "date": [
1016 0.0,
1016 0.0,
1017 0
1017 0
1018 ],
1018 ],
1019 "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7",
1019 "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7",
1020 "status": "open"
1020 "status": "open"
1021 },
1021 },
1022 {
1022 {
1023 "branch": "test-branch",
1023 "branch": "test-branch",
1024 "date": [
1024 "date": [
1025 0.0,
1025 0.0,
1026 0
1026 0
1027 ],
1027 ],
1028 "node": "ed66c30e87eb65337c05a4229efaa5f1d5285a90",
1028 "node": "ed66c30e87eb65337c05a4229efaa5f1d5285a90",
1029 "status": "inactive"
1029 "status": "inactive"
1030 }
1030 }
1031 ],
1031 ],
1032 "labels": [],
1032 "labels": [],
1033 "lastchange": [
1033 "lastchange": [
1034 0.0,
1034 0.0,
1035 0
1035 0
1036 ],
1036 ],
1037 "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7",
1037 "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7",
1038 "shortlog": [
1038 "shortlog": [
1039 {
1039 {
1040 "bookmarks": [],
1040 "bookmarks": [],
1041 "branch": "default",
1041 "branch": "default",
1042 "date": [
1042 "date": [
1043 0.0,
1043 0.0,
1044 0
1044 0
1045 ],
1045 ],
1046 "desc": "merge test-branch into default",
1046 "desc": "merge test-branch into default",
1047 "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7",
1047 "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7",
1048 "parents": [
1048 "parents": [
1049 "ceed296fe500c3fac9541e31dad860cb49c89e45",
1049 "ceed296fe500c3fac9541e31dad860cb49c89e45",
1050 "ed66c30e87eb65337c05a4229efaa5f1d5285a90"
1050 "ed66c30e87eb65337c05a4229efaa5f1d5285a90"
1051 ],
1051 ],
1052 "phase": "draft",
1052 "phase": "draft",
1053 "tags": [
1053 "tags": [
1054 "tip"
1054 "tip"
1055 ],
1055 ],
1056 "user": "test"
1056 "user": "test"
1057 },
1057 },
1058 {
1058 {
1059 "bookmarks": [],
1059 "bookmarks": [],
1060 "branch": "test-branch",
1060 "branch": "test-branch",
1061 "date": [
1061 "date": [
1062 0.0,
1062 0.0,
1063 0
1063 0
1064 ],
1064 ],
1065 "desc": "another commit in test-branch",
1065 "desc": "another commit in test-branch",
1066 "node": "ed66c30e87eb65337c05a4229efaa5f1d5285a90",
1066 "node": "ed66c30e87eb65337c05a4229efaa5f1d5285a90",
1067 "parents": [
1067 "parents": [
1068 "6ab967a8ab3489227a83f80e920faa039a71819f"
1068 "6ab967a8ab3489227a83f80e920faa039a71819f"
1069 ],
1069 ],
1070 "phase": "draft",
1070 "phase": "draft",
1071 "tags": [],
1071 "tags": [],
1072 "user": "test"
1072 "user": "test"
1073 },
1073 },
1074 {
1074 {
1075 "bookmarks": [],
1075 "bookmarks": [],
1076 "branch": "test-branch",
1076 "branch": "test-branch",
1077 "date": [
1077 "date": [
1078 0.0,
1078 0.0,
1079 0
1079 0
1080 ],
1080 ],
1081 "desc": "create test branch",
1081 "desc": "create test branch",
1082 "node": "6ab967a8ab3489227a83f80e920faa039a71819f",
1082 "node": "6ab967a8ab3489227a83f80e920faa039a71819f",
1083 "parents": [
1083 "parents": [
1084 "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e"
1084 "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e"
1085 ],
1085 ],
1086 "phase": "draft",
1086 "phase": "draft",
1087 "tags": [],
1087 "tags": [],
1088 "user": "test"
1088 "user": "test"
1089 },
1089 },
1090 {
1090 {
1091 "bookmarks": [
1091 "bookmarks": [
1092 "bookmark2"
1092 "bookmark2"
1093 ],
1093 ],
1094 "branch": "default",
1094 "branch": "default",
1095 "date": [
1095 "date": [
1096 0.0,
1096 0.0,
1097 0
1097 0
1098 ],
1098 ],
1099 "desc": "create tag2",
1099 "desc": "create tag2",
1100 "node": "ceed296fe500c3fac9541e31dad860cb49c89e45",
1100 "node": "ceed296fe500c3fac9541e31dad860cb49c89e45",
1101 "parents": [
1101 "parents": [
1102 "f2890a05fea49bfaf9fb27ed5490894eba32da78"
1102 "f2890a05fea49bfaf9fb27ed5490894eba32da78"
1103 ],
1103 ],
1104 "phase": "draft",
1104 "phase": "draft",
1105 "tags": [],
1105 "tags": [],
1106 "user": "test"
1106 "user": "test"
1107 },
1107 },
1108 {
1108 {
1109 "bookmarks": [],
1109 "bookmarks": [],
1110 "branch": "default",
1110 "branch": "default",
1111 "date": [
1111 "date": [
1112 0.0,
1112 0.0,
1113 0
1113 0
1114 ],
1114 ],
1115 "desc": "another commit to da/foo",
1115 "desc": "another commit to da/foo",
1116 "node": "f2890a05fea49bfaf9fb27ed5490894eba32da78",
1116 "node": "f2890a05fea49bfaf9fb27ed5490894eba32da78",
1117 "parents": [
1117 "parents": [
1118 "93a8ce14f89156426b7fa981af8042da53f03aa0"
1118 "93a8ce14f89156426b7fa981af8042da53f03aa0"
1119 ],
1119 ],
1120 "phase": "draft",
1120 "phase": "draft",
1121 "tags": [
1121 "tags": [
1122 "tag2"
1122 "tag2"
1123 ],
1123 ],
1124 "user": "test"
1124 "user": "test"
1125 },
1125 },
1126 {
1126 {
1127 "bookmarks": [],
1127 "bookmarks": [],
1128 "branch": "default",
1128 "branch": "default",
1129 "date": [
1129 "date": [
1130 0.0,
1130 0.0,
1131 0
1131 0
1132 ],
1132 ],
1133 "desc": "create tag",
1133 "desc": "create tag",
1134 "node": "93a8ce14f89156426b7fa981af8042da53f03aa0",
1134 "node": "93a8ce14f89156426b7fa981af8042da53f03aa0",
1135 "parents": [
1135 "parents": [
1136 "78896eb0e102174ce9278438a95e12543e4367a7"
1136 "78896eb0e102174ce9278438a95e12543e4367a7"
1137 ],
1137 ],
1138 "phase": "public",
1138 "phase": "public",
1139 "tags": [],
1139 "tags": [],
1140 "user": "test"
1140 "user": "test"
1141 },
1141 },
1142 {
1142 {
1143 "bookmarks": [],
1143 "bookmarks": [],
1144 "branch": "default",
1144 "branch": "default",
1145 "date": [
1145 "date": [
1146 0.0,
1146 0.0,
1147 0
1147 0
1148 ],
1148 ],
1149 "desc": "move foo",
1149 "desc": "move foo",
1150 "node": "78896eb0e102174ce9278438a95e12543e4367a7",
1150 "node": "78896eb0e102174ce9278438a95e12543e4367a7",
1151 "parents": [
1151 "parents": [
1152 "8d7c456572acf3557e8ed8a07286b10c408bcec5"
1152 "8d7c456572acf3557e8ed8a07286b10c408bcec5"
1153 ],
1153 ],
1154 "phase": "public",
1154 "phase": "public",
1155 "tags": [
1155 "tags": [
1156 "tag1"
1156 "tag1"
1157 ],
1157 ],
1158 "user": "test"
1158 "user": "test"
1159 },
1159 },
1160 {
1160 {
1161 "bookmarks": [
1161 "bookmarks": [
1162 "bookmark1"
1162 "bookmark1"
1163 ],
1163 ],
1164 "branch": "default",
1164 "branch": "default",
1165 "date": [
1165 "date": [
1166 0.0,
1166 0.0,
1167 0
1167 0
1168 ],
1168 ],
1169 "desc": "modify da/foo",
1169 "desc": "modify da/foo",
1170 "node": "8d7c456572acf3557e8ed8a07286b10c408bcec5",
1170 "node": "8d7c456572acf3557e8ed8a07286b10c408bcec5",
1171 "parents": [
1171 "parents": [
1172 "f8bbb9024b10f93cdbb8d940337398291d40dea8"
1172 "f8bbb9024b10f93cdbb8d940337398291d40dea8"
1173 ],
1173 ],
1174 "phase": "public",
1174 "phase": "public",
1175 "tags": [],
1175 "tags": [],
1176 "user": "test"
1176 "user": "test"
1177 },
1177 },
1178 {
1178 {
1179 "bookmarks": [],
1179 "bookmarks": [],
1180 "branch": "default",
1180 "branch": "default",
1181 "date": [
1181 "date": [
1182 0.0,
1182 0.0,
1183 0
1183 0
1184 ],
1184 ],
1185 "desc": "modify foo",
1185 "desc": "modify foo",
1186 "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8",
1186 "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8",
1187 "parents": [
1187 "parents": [
1188 "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e"
1188 "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e"
1189 ],
1189 ],
1190 "phase": "public",
1190 "phase": "public",
1191 "tags": [],
1191 "tags": [],
1192 "user": "test"
1192 "user": "test"
1193 },
1193 },
1194 {
1194 {
1195 "bookmarks": [],
1195 "bookmarks": [],
1196 "branch": "default",
1196 "branch": "default",
1197 "date": [
1197 "date": [
1198 0.0,
1198 0.0,
1199 0
1199 0
1200 ],
1200 ],
1201 "desc": "initial",
1201 "desc": "initial",
1202 "node": "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e",
1202 "node": "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e",
1203 "parents": [],
1203 "parents": [],
1204 "phase": "public",
1204 "phase": "public",
1205 "tags": [],
1205 "tags": [],
1206 "user": "test"
1206 "user": "test"
1207 }
1207 }
1208 ],
1208 ],
1209 "tags": [
1209 "tags": [
1210 {
1210 {
1211 "date": [
1211 "date": [
1212 0.0,
1212 0.0,
1213 0
1213 0
1214 ],
1214 ],
1215 "node": "f2890a05fea49bfaf9fb27ed5490894eba32da78",
1215 "node": "f2890a05fea49bfaf9fb27ed5490894eba32da78",
1216 "tag": "tag2"
1216 "tag": "tag2"
1217 },
1217 },
1218 {
1218 {
1219 "date": [
1219 "date": [
1220 0.0,
1220 0.0,
1221 0
1221 0
1222 ],
1222 ],
1223 "node": "78896eb0e102174ce9278438a95e12543e4367a7",
1223 "node": "78896eb0e102174ce9278438a95e12543e4367a7",
1224 "tag": "tag1"
1224 "tag": "tag1"
1225 }
1225 }
1226 ]
1226 ]
1227 }
1227 }
1228
1228
1229 $ request json-changelog?rev=create
1229 $ request json-changelog?rev=create
1230 200 Script output follows
1230 200 Script output follows
1231
1231
1232 {
1232 {
1233 "entries": [
1233 "entries": [
1234 {
1234 {
1235 "bookmarks": [],
1235 "bookmarks": [],
1236 "branch": "test-branch",
1236 "branch": "test-branch",
1237 "date": [
1237 "date": [
1238 0.0,
1238 0.0,
1239 0
1239 0
1240 ],
1240 ],
1241 "desc": "create test branch",
1241 "desc": "create test branch",
1242 "node": "6ab967a8ab3489227a83f80e920faa039a71819f",
1242 "node": "6ab967a8ab3489227a83f80e920faa039a71819f",
1243 "parents": [
1243 "parents": [
1244 "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e"
1244 "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e"
1245 ],
1245 ],
1246 "phase": "draft",
1246 "phase": "draft",
1247 "tags": [],
1247 "tags": [],
1248 "user": "test"
1248 "user": "test"
1249 },
1249 },
1250 {
1250 {
1251 "bookmarks": [
1251 "bookmarks": [
1252 "bookmark2"
1252 "bookmark2"
1253 ],
1253 ],
1254 "branch": "default",
1254 "branch": "default",
1255 "date": [
1255 "date": [
1256 0.0,
1256 0.0,
1257 0
1257 0
1258 ],
1258 ],
1259 "desc": "create tag2",
1259 "desc": "create tag2",
1260 "node": "ceed296fe500c3fac9541e31dad860cb49c89e45",
1260 "node": "ceed296fe500c3fac9541e31dad860cb49c89e45",
1261 "parents": [
1261 "parents": [
1262 "f2890a05fea49bfaf9fb27ed5490894eba32da78"
1262 "f2890a05fea49bfaf9fb27ed5490894eba32da78"
1263 ],
1263 ],
1264 "phase": "draft",
1264 "phase": "draft",
1265 "tags": [],
1265 "tags": [],
1266 "user": "test"
1266 "user": "test"
1267 },
1267 },
1268 {
1268 {
1269 "bookmarks": [],
1269 "bookmarks": [],
1270 "branch": "default",
1270 "branch": "default",
1271 "date": [
1271 "date": [
1272 0.0,
1272 0.0,
1273 0
1273 0
1274 ],
1274 ],
1275 "desc": "create tag",
1275 "desc": "create tag",
1276 "node": "93a8ce14f89156426b7fa981af8042da53f03aa0",
1276 "node": "93a8ce14f89156426b7fa981af8042da53f03aa0",
1277 "parents": [
1277 "parents": [
1278 "78896eb0e102174ce9278438a95e12543e4367a7"
1278 "78896eb0e102174ce9278438a95e12543e4367a7"
1279 ],
1279 ],
1280 "phase": "public",
1280 "phase": "public",
1281 "tags": [],
1281 "tags": [],
1282 "user": "test"
1282 "user": "test"
1283 }
1283 }
1284 ],
1284 ],
1285 "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7",
1285 "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7",
1286 "query": "create"
1286 "query": "create"
1287 }
1287 }
1288
1288
1289 filediff/{revision}/{path} shows changes to a file in a revision
1289 filediff/{revision}/{path} shows changes to a file in a revision
1290
1290
1291 $ request json-diff/f8bbb9024b10/foo
1291 $ request json-diff/f8bbb9024b10/foo
1292 200 Script output follows
1292 200 Script output follows
1293
1293
1294 {
1294 {
1295 "author": "test",
1295 "author": "test",
1296 "children": [],
1296 "children": [],
1297 "date": [
1297 "date": [
1298 0.0,
1298 0.0,
1299 0
1299 0
1300 ],
1300 ],
1301 "desc": "modify foo",
1301 "desc": "modify foo",
1302 "diff": [
1302 "diff": [
1303 {
1303 {
1304 "blockno": 1,
1304 "blockno": 1,
1305 "lines": [
1305 "lines": [
1306 {
1306 {
1307 "l": "--- a/foo\tThu Jan 01 00:00:00 1970 +0000\n",
1307 "l": "--- a/foo\tThu Jan 01 00:00:00 1970 +0000\n",
1308 "n": 1,
1308 "n": 1,
1309 "t": "-"
1309 "t": "-"
1310 },
1310 },
1311 {
1311 {
1312 "l": "+++ b/foo\tThu Jan 01 00:00:00 1970 +0000\n",
1312 "l": "+++ b/foo\tThu Jan 01 00:00:00 1970 +0000\n",
1313 "n": 2,
1313 "n": 2,
1314 "t": "+"
1314 "t": "+"
1315 },
1315 },
1316 {
1316 {
1317 "l": "@@ -1,1 +1,1 @@\n",
1317 "l": "@@ -1,1 +1,1 @@\n",
1318 "n": 3,
1318 "n": 3,
1319 "t": "@"
1319 "t": "@"
1320 },
1320 },
1321 {
1321 {
1322 "l": "-foo\n",
1322 "l": "-foo\n",
1323 "n": 4,
1323 "n": 4,
1324 "t": "-"
1324 "t": "-"
1325 },
1325 },
1326 {
1326 {
1327 "l": "+bar\n",
1327 "l": "+bar\n",
1328 "n": 5,
1328 "n": 5,
1329 "t": "+"
1329 "t": "+"
1330 }
1330 }
1331 ]
1331 ]
1332 }
1332 }
1333 ],
1333 ],
1334 "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8",
1334 "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8",
1335 "parents": [
1335 "parents": [
1336 "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e"
1336 "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e"
1337 ],
1337 ],
1338 "path": "foo"
1338 "path": "foo"
1339 }
1339 }
1340
1340
1341 comparison/{revision}/{path} shows information about before and after for a file
1341 comparison/{revision}/{path} shows information about before and after for a file
1342
1342
1343 $ request json-comparison/f8bbb9024b10/foo
1343 $ request json-comparison/f8bbb9024b10/foo
1344 200 Script output follows
1344 200 Script output follows
1345
1345
1346 {
1346 {
1347 "author": "test",
1347 "author": "test",
1348 "children": [],
1348 "children": [],
1349 "comparison": [
1349 "comparison": [
1350 {
1350 {
1351 "lines": [
1351 "lines": [
1352 {
1352 {
1353 "ll": "foo",
1353 "ll": "foo",
1354 "ln": 1,
1354 "ln": 1,
1355 "rl": "bar",
1355 "rl": "bar",
1356 "rn": 1,
1356 "rn": 1,
1357 "t": "replace"
1357 "t": "replace"
1358 }
1358 }
1359 ]
1359 ]
1360 }
1360 }
1361 ],
1361 ],
1362 "date": [
1362 "date": [
1363 0.0,
1363 0.0,
1364 0
1364 0
1365 ],
1365 ],
1366 "desc": "modify foo",
1366 "desc": "modify foo",
1367 "leftnode": "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e",
1367 "leftnode": "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e",
1368 "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8",
1368 "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8",
1369 "parents": [
1369 "parents": [
1370 "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e"
1370 "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e"
1371 ],
1371 ],
1372 "path": "foo",
1372 "path": "foo",
1373 "rightnode": "f8bbb9024b10f93cdbb8d940337398291d40dea8"
1373 "rightnode": "f8bbb9024b10f93cdbb8d940337398291d40dea8"
1374 }
1374 }
1375
1375
1376 annotate/{revision}/{path} shows annotations for each line
1376 annotate/{revision}/{path} shows annotations for each line
1377
1377
1378 $ request json-annotate/f8bbb9024b10/foo
1378 $ request json-annotate/f8bbb9024b10/foo
1379 200 Script output follows
1379 200 Script output follows
1380
1380
1381 {
1381 {
1382 "abspath": "foo",
1382 "abspath": "foo",
1383 "annotate": [
1383 "annotate": [
1384 {
1384 {
1385 "abspath": "foo",
1385 "abspath": "foo",
1386 "author": "test",
1386 "author": "test",
1387 "desc": "modify foo",
1387 "desc": "modify foo",
1388 "line": "bar\n",
1388 "line": "bar\n",
1389 "lineno": 1,
1389 "lineno": 1,
1390 "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8",
1390 "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8",
1391 "revdate": [
1391 "revdate": [
1392 0.0,
1392 0.0,
1393 0
1393 0
1394 ],
1394 ],
1395 "targetline": 1
1395 "targetline": 1
1396 }
1396 }
1397 ],
1397 ],
1398 "author": "test",
1398 "author": "test",
1399 "children": [],
1399 "children": [],
1400 "date": [
1400 "date": [
1401 0.0,
1401 0.0,
1402 0
1402 0
1403 ],
1403 ],
1404 "desc": "modify foo",
1404 "desc": "modify foo",
1405 "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8",
1405 "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8",
1406 "parents": [
1406 "parents": [
1407 "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e"
1407 "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e"
1408 ],
1408 ],
1409 "permissions": ""
1409 "permissions": ""
1410 }
1410 }
1411
1411
1412 filelog/{revision}/{path} shows history of a single file
1412 filelog/{revision}/{path} shows history of a single file
1413
1413
1414 $ request json-filelog/f8bbb9024b10/foo
1414 $ request json-filelog/f8bbb9024b10/foo
1415 200 Script output follows
1415 200 Script output follows
1416
1416
1417 {
1417 {
1418 "entries": [
1418 "entries": [
1419 {
1419 {
1420 "bookmarks": [],
1420 "bookmarks": [],
1421 "branch": "default",
1421 "branch": "default",
1422 "date": [
1422 "date": [
1423 0.0,
1423 0.0,
1424 0
1424 0
1425 ],
1425 ],
1426 "desc": "modify foo",
1426 "desc": "modify foo",
1427 "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8",
1427 "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8",
1428 "parents": [
1428 "parents": [
1429 "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e"
1429 "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e"
1430 ],
1430 ],
1431 "phase": "public",
1431 "phase": "public",
1432 "tags": [],
1432 "tags": [],
1433 "user": "test"
1433 "user": "test"
1434 },
1434 },
1435 {
1435 {
1436 "bookmarks": [],
1436 "bookmarks": [],
1437 "branch": "default",
1437 "branch": "default",
1438 "date": [
1438 "date": [
1439 0.0,
1439 0.0,
1440 0
1440 0
1441 ],
1441 ],
1442 "desc": "initial",
1442 "desc": "initial",
1443 "node": "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e",
1443 "node": "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e",
1444 "parents": [],
1444 "parents": [],
1445 "phase": "public",
1445 "phase": "public",
1446 "tags": [],
1446 "tags": [],
1447 "user": "test"
1447 "user": "test"
1448 }
1448 }
1449 ]
1449 ]
1450 }
1450 }
1451
1451
1452 $ request json-filelog/cc725e08502a/da/foo
1452 $ request json-filelog/cc725e08502a/da/foo
1453 200 Script output follows
1453 200 Script output follows
1454
1454
1455 {
1455 {
1456 "entries": [
1456 "entries": [
1457 {
1457 {
1458 "bookmarks": [],
1458 "bookmarks": [],
1459 "branch": "default",
1459 "branch": "default",
1460 "date": [
1460 "date": [
1461 0.0,
1461 0.0,
1462 0
1462 0
1463 ],
1463 ],
1464 "desc": "another commit to da/foo",
1464 "desc": "another commit to da/foo",
1465 "node": "f2890a05fea49bfaf9fb27ed5490894eba32da78",
1465 "node": "f2890a05fea49bfaf9fb27ed5490894eba32da78",
1466 "parents": [
1466 "parents": [
1467 "8d7c456572acf3557e8ed8a07286b10c408bcec5"
1467 "8d7c456572acf3557e8ed8a07286b10c408bcec5"
1468 ],
1468 ],
1469 "phase": "draft",
1469 "phase": "draft",
1470 "tags": [
1470 "tags": [
1471 "tag2"
1471 "tag2"
1472 ],
1472 ],
1473 "user": "test"
1473 "user": "test"
1474 },
1474 },
1475 {
1475 {
1476 "bookmarks": [
1476 "bookmarks": [
1477 "bookmark1"
1477 "bookmark1"
1478 ],
1478 ],
1479 "branch": "default",
1479 "branch": "default",
1480 "date": [
1480 "date": [
1481 0.0,
1481 0.0,
1482 0
1482 0
1483 ],
1483 ],
1484 "desc": "modify da/foo",
1484 "desc": "modify da/foo",
1485 "node": "8d7c456572acf3557e8ed8a07286b10c408bcec5",
1485 "node": "8d7c456572acf3557e8ed8a07286b10c408bcec5",
1486 "parents": [
1486 "parents": [
1487 "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e"
1487 "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e"
1488 ],
1488 ],
1489 "phase": "public",
1489 "phase": "public",
1490 "tags": [],
1490 "tags": [],
1491 "user": "test"
1491 "user": "test"
1492 },
1492 },
1493 {
1493 {
1494 "bookmarks": [],
1494 "bookmarks": [],
1495 "branch": "default",
1495 "branch": "default",
1496 "date": [
1496 "date": [
1497 0.0,
1497 0.0,
1498 0
1498 0
1499 ],
1499 ],
1500 "desc": "initial",
1500 "desc": "initial",
1501 "node": "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e",
1501 "node": "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e",
1502 "parents": [],
1502 "parents": [],
1503 "phase": "public",
1503 "phase": "public",
1504 "tags": [],
1504 "tags": [],
1505 "user": "test"
1505 "user": "test"
1506 }
1506 }
1507 ]
1507 ]
1508 }
1508 }
1509
1509
1510 (archive/ doesn't use templating, so ignore it)
1510 (archive/ doesn't use templating, so ignore it)
1511
1511
1512 (static/ doesn't use templating, so ignore it)
1512 (static/ doesn't use templating, so ignore it)
1513
1513
1514 graph/ shows information that can be used to render a graph of the DAG
1514 graph/ shows information that can be used to render a graph of the DAG
1515
1515
1516 $ request json-graph
1516 $ request json-graph
1517 200 Script output follows
1517 200 Script output follows
1518
1518
1519 {
1519 {
1520 "changeset_count": 10,
1520 "changeset_count": 10,
1521 "changesets": [
1521 "changesets": [
1522 {
1522 {
1523 "bookmarks": [],
1523 "bookmarks": [],
1524 "branch": "default",
1524 "branch": "default",
1525 "col": 0,
1525 "col": 0,
1526 "color": 1,
1526 "color": 1,
1527 "date": [
1527 "date": [
1528 0.0,
1528 0.0,
1529 0
1529 0
1530 ],
1530 ],
1531 "desc": "merge test-branch into default",
1531 "desc": "merge test-branch into default",
1532 "edges": [
1532 "edges": [
1533 {
1533 {
1534 "bcolor": "",
1534 "bcolor": "",
1535 "col": 0,
1535 "col": 0,
1536 "color": 1,
1536 "color": 1,
1537 "nextcol": 0,
1537 "nextcol": 0,
1538 "width": -1
1538 "width": -1
1539 },
1539 },
1540 {
1540 {
1541 "bcolor": "",
1541 "bcolor": "",
1542 "col": 0,
1542 "col": 0,
1543 "color": 1,
1543 "color": 1,
1544 "nextcol": 1,
1544 "nextcol": 1,
1545 "width": -1
1545 "width": -1
1546 }
1546 }
1547 ],
1547 ],
1548 "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7",
1548 "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7",
1549 "parents": [
1549 "parents": [
1550 "ceed296fe500c3fac9541e31dad860cb49c89e45",
1550 "ceed296fe500c3fac9541e31dad860cb49c89e45",
1551 "ed66c30e87eb65337c05a4229efaa5f1d5285a90"
1551 "ed66c30e87eb65337c05a4229efaa5f1d5285a90"
1552 ],
1552 ],
1553 "phase": "draft",
1553 "phase": "draft",
1554 "row": 0,
1554 "row": 0,
1555 "tags": [
1555 "tags": [
1556 "tip"
1556 "tip"
1557 ],
1557 ],
1558 "user": "test"
1558 "user": "test"
1559 },
1559 },
1560 {
1560 {
1561 "bookmarks": [],
1561 "bookmarks": [],
1562 "branch": "test-branch",
1562 "branch": "test-branch",
1563 "col": 1,
1563 "col": 1,
1564 "color": 2,
1564 "color": 2,
1565 "date": [
1565 "date": [
1566 0.0,
1566 0.0,
1567 0
1567 0
1568 ],
1568 ],
1569 "desc": "another commit in test-branch",
1569 "desc": "another commit in test-branch",
1570 "edges": [
1570 "edges": [
1571 {
1571 {
1572 "bcolor": "",
1572 "bcolor": "",
1573 "col": 0,
1573 "col": 0,
1574 "color": 1,
1574 "color": 1,
1575 "nextcol": 0,
1575 "nextcol": 0,
1576 "width": -1
1576 "width": -1
1577 },
1577 },
1578 {
1578 {
1579 "bcolor": "",
1579 "bcolor": "",
1580 "col": 1,
1580 "col": 1,
1581 "color": 2,
1581 "color": 2,
1582 "nextcol": 1,
1582 "nextcol": 1,
1583 "width": -1
1583 "width": -1
1584 }
1584 }
1585 ],
1585 ],
1586 "node": "ed66c30e87eb65337c05a4229efaa5f1d5285a90",
1586 "node": "ed66c30e87eb65337c05a4229efaa5f1d5285a90",
1587 "parents": [
1587 "parents": [
1588 "6ab967a8ab3489227a83f80e920faa039a71819f"
1588 "6ab967a8ab3489227a83f80e920faa039a71819f"
1589 ],
1589 ],
1590 "phase": "draft",
1590 "phase": "draft",
1591 "row": 1,
1591 "row": 1,
1592 "tags": [],
1592 "tags": [],
1593 "user": "test"
1593 "user": "test"
1594 },
1594 },
1595 {
1595 {
1596 "bookmarks": [],
1596 "bookmarks": [],
1597 "branch": "test-branch",
1597 "branch": "test-branch",
1598 "col": 1,
1598 "col": 1,
1599 "color": 2,
1599 "color": 2,
1600 "date": [
1600 "date": [
1601 0.0,
1601 0.0,
1602 0
1602 0
1603 ],
1603 ],
1604 "desc": "create test branch",
1604 "desc": "create test branch",
1605 "edges": [
1605 "edges": [
1606 {
1606 {
1607 "bcolor": "",
1607 "bcolor": "",
1608 "col": 0,
1608 "col": 0,
1609 "color": 1,
1609 "color": 1,
1610 "nextcol": 0,
1610 "nextcol": 0,
1611 "width": -1
1611 "width": -1
1612 },
1612 },
1613 {
1613 {
1614 "bcolor": "",
1614 "bcolor": "",
1615 "col": 1,
1615 "col": 1,
1616 "color": 2,
1616 "color": 2,
1617 "nextcol": 1,
1617 "nextcol": 1,
1618 "width": -1
1618 "width": -1
1619 }
1619 }
1620 ],
1620 ],
1621 "node": "6ab967a8ab3489227a83f80e920faa039a71819f",
1621 "node": "6ab967a8ab3489227a83f80e920faa039a71819f",
1622 "parents": [
1622 "parents": [
1623 "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e"
1623 "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e"
1624 ],
1624 ],
1625 "phase": "draft",
1625 "phase": "draft",
1626 "row": 2,
1626 "row": 2,
1627 "tags": [],
1627 "tags": [],
1628 "user": "test"
1628 "user": "test"
1629 },
1629 },
1630 {
1630 {
1631 "bookmarks": [
1631 "bookmarks": [
1632 "bookmark2"
1632 "bookmark2"
1633 ],
1633 ],
1634 "branch": "default",
1634 "branch": "default",
1635 "col": 0,
1635 "col": 0,
1636 "color": 1,
1636 "color": 1,
1637 "date": [
1637 "date": [
1638 0.0,
1638 0.0,
1639 0
1639 0
1640 ],
1640 ],
1641 "desc": "create tag2",
1641 "desc": "create tag2",
1642 "edges": [
1642 "edges": [
1643 {
1643 {
1644 "bcolor": "",
1644 "bcolor": "",
1645 "col": 0,
1645 "col": 0,
1646 "color": 1,
1646 "color": 1,
1647 "nextcol": 0,
1647 "nextcol": 0,
1648 "width": -1
1648 "width": -1
1649 },
1649 },
1650 {
1650 {
1651 "bcolor": "",
1651 "bcolor": "",
1652 "col": 1,
1652 "col": 1,
1653 "color": 2,
1653 "color": 2,
1654 "nextcol": 1,
1654 "nextcol": 1,
1655 "width": -1
1655 "width": -1
1656 }
1656 }
1657 ],
1657 ],
1658 "node": "ceed296fe500c3fac9541e31dad860cb49c89e45",
1658 "node": "ceed296fe500c3fac9541e31dad860cb49c89e45",
1659 "parents": [
1659 "parents": [
1660 "f2890a05fea49bfaf9fb27ed5490894eba32da78"
1660 "f2890a05fea49bfaf9fb27ed5490894eba32da78"
1661 ],
1661 ],
1662 "phase": "draft",
1662 "phase": "draft",
1663 "row": 3,
1663 "row": 3,
1664 "tags": [],
1664 "tags": [],
1665 "user": "test"
1665 "user": "test"
1666 },
1666 },
1667 {
1667 {
1668 "bookmarks": [],
1668 "bookmarks": [],
1669 "branch": "default",
1669 "branch": "default",
1670 "col": 0,
1670 "col": 0,
1671 "color": 1,
1671 "color": 1,
1672 "date": [
1672 "date": [
1673 0.0,
1673 0.0,
1674 0
1674 0
1675 ],
1675 ],
1676 "desc": "another commit to da/foo",
1676 "desc": "another commit to da/foo",
1677 "edges": [
1677 "edges": [
1678 {
1678 {
1679 "bcolor": "",
1679 "bcolor": "",
1680 "col": 0,
1680 "col": 0,
1681 "color": 1,
1681 "color": 1,
1682 "nextcol": 0,
1682 "nextcol": 0,
1683 "width": -1
1683 "width": -1
1684 },
1684 },
1685 {
1685 {
1686 "bcolor": "",
1686 "bcolor": "",
1687 "col": 1,
1687 "col": 1,
1688 "color": 2,
1688 "color": 2,
1689 "nextcol": 1,
1689 "nextcol": 1,
1690 "width": -1
1690 "width": -1
1691 }
1691 }
1692 ],
1692 ],
1693 "node": "f2890a05fea49bfaf9fb27ed5490894eba32da78",
1693 "node": "f2890a05fea49bfaf9fb27ed5490894eba32da78",
1694 "parents": [
1694 "parents": [
1695 "93a8ce14f89156426b7fa981af8042da53f03aa0"
1695 "93a8ce14f89156426b7fa981af8042da53f03aa0"
1696 ],
1696 ],
1697 "phase": "draft",
1697 "phase": "draft",
1698 "row": 4,
1698 "row": 4,
1699 "tags": [
1699 "tags": [
1700 "tag2"
1700 "tag2"
1701 ],
1701 ],
1702 "user": "test"
1702 "user": "test"
1703 },
1703 },
1704 {
1704 {
1705 "bookmarks": [],
1705 "bookmarks": [],
1706 "branch": "default",
1706 "branch": "default",
1707 "col": 0,
1707 "col": 0,
1708 "color": 1,
1708 "color": 1,
1709 "date": [
1709 "date": [
1710 0.0,
1710 0.0,
1711 0
1711 0
1712 ],
1712 ],
1713 "desc": "create tag",
1713 "desc": "create tag",
1714 "edges": [
1714 "edges": [
1715 {
1715 {
1716 "bcolor": "",
1716 "bcolor": "",
1717 "col": 0,
1717 "col": 0,
1718 "color": 1,
1718 "color": 1,
1719 "nextcol": 0,
1719 "nextcol": 0,
1720 "width": -1
1720 "width": -1
1721 },
1721 },
1722 {
1722 {
1723 "bcolor": "",
1723 "bcolor": "",
1724 "col": 1,
1724 "col": 1,
1725 "color": 2,
1725 "color": 2,
1726 "nextcol": 1,
1726 "nextcol": 1,
1727 "width": -1
1727 "width": -1
1728 }
1728 }
1729 ],
1729 ],
1730 "node": "93a8ce14f89156426b7fa981af8042da53f03aa0",
1730 "node": "93a8ce14f89156426b7fa981af8042da53f03aa0",
1731 "parents": [
1731 "parents": [
1732 "78896eb0e102174ce9278438a95e12543e4367a7"
1732 "78896eb0e102174ce9278438a95e12543e4367a7"
1733 ],
1733 ],
1734 "phase": "public",
1734 "phase": "public",
1735 "row": 5,
1735 "row": 5,
1736 "tags": [],
1736 "tags": [],
1737 "user": "test"
1737 "user": "test"
1738 },
1738 },
1739 {
1739 {
1740 "bookmarks": [],
1740 "bookmarks": [],
1741 "branch": "default",
1741 "branch": "default",
1742 "col": 0,
1742 "col": 0,
1743 "color": 1,
1743 "color": 1,
1744 "date": [
1744 "date": [
1745 0.0,
1745 0.0,
1746 0
1746 0
1747 ],
1747 ],
1748 "desc": "move foo",
1748 "desc": "move foo",
1749 "edges": [
1749 "edges": [
1750 {
1750 {
1751 "bcolor": "",
1751 "bcolor": "",
1752 "col": 0,
1752 "col": 0,
1753 "color": 1,
1753 "color": 1,
1754 "nextcol": 0,
1754 "nextcol": 0,
1755 "width": -1
1755 "width": -1
1756 },
1756 },
1757 {
1757 {
1758 "bcolor": "",
1758 "bcolor": "",
1759 "col": 1,
1759 "col": 1,
1760 "color": 2,
1760 "color": 2,
1761 "nextcol": 1,
1761 "nextcol": 1,
1762 "width": -1
1762 "width": -1
1763 }
1763 }
1764 ],
1764 ],
1765 "node": "78896eb0e102174ce9278438a95e12543e4367a7",
1765 "node": "78896eb0e102174ce9278438a95e12543e4367a7",
1766 "parents": [
1766 "parents": [
1767 "8d7c456572acf3557e8ed8a07286b10c408bcec5"
1767 "8d7c456572acf3557e8ed8a07286b10c408bcec5"
1768 ],
1768 ],
1769 "phase": "public",
1769 "phase": "public",
1770 "row": 6,
1770 "row": 6,
1771 "tags": [
1771 "tags": [
1772 "tag1"
1772 "tag1"
1773 ],
1773 ],
1774 "user": "test"
1774 "user": "test"
1775 },
1775 },
1776 {
1776 {
1777 "bookmarks": [
1777 "bookmarks": [
1778 "bookmark1"
1778 "bookmark1"
1779 ],
1779 ],
1780 "branch": "default",
1780 "branch": "default",
1781 "col": 0,
1781 "col": 0,
1782 "color": 1,
1782 "color": 1,
1783 "date": [
1783 "date": [
1784 0.0,
1784 0.0,
1785 0
1785 0
1786 ],
1786 ],
1787 "desc": "modify da/foo",
1787 "desc": "modify da/foo",
1788 "edges": [
1788 "edges": [
1789 {
1789 {
1790 "bcolor": "",
1790 "bcolor": "",
1791 "col": 0,
1791 "col": 0,
1792 "color": 1,
1792 "color": 1,
1793 "nextcol": 0,
1793 "nextcol": 0,
1794 "width": -1
1794 "width": -1
1795 },
1795 },
1796 {
1796 {
1797 "bcolor": "",
1797 "bcolor": "",
1798 "col": 1,
1798 "col": 1,
1799 "color": 2,
1799 "color": 2,
1800 "nextcol": 1,
1800 "nextcol": 1,
1801 "width": -1
1801 "width": -1
1802 }
1802 }
1803 ],
1803 ],
1804 "node": "8d7c456572acf3557e8ed8a07286b10c408bcec5",
1804 "node": "8d7c456572acf3557e8ed8a07286b10c408bcec5",
1805 "parents": [
1805 "parents": [
1806 "f8bbb9024b10f93cdbb8d940337398291d40dea8"
1806 "f8bbb9024b10f93cdbb8d940337398291d40dea8"
1807 ],
1807 ],
1808 "phase": "public",
1808 "phase": "public",
1809 "row": 7,
1809 "row": 7,
1810 "tags": [],
1810 "tags": [],
1811 "user": "test"
1811 "user": "test"
1812 },
1812 },
1813 {
1813 {
1814 "bookmarks": [],
1814 "bookmarks": [],
1815 "branch": "default",
1815 "branch": "default",
1816 "col": 0,
1816 "col": 0,
1817 "color": 1,
1817 "color": 1,
1818 "date": [
1818 "date": [
1819 0.0,
1819 0.0,
1820 0
1820 0
1821 ],
1821 ],
1822 "desc": "modify foo",
1822 "desc": "modify foo",
1823 "edges": [
1823 "edges": [
1824 {
1824 {
1825 "bcolor": "",
1825 "bcolor": "",
1826 "col": 0,
1826 "col": 0,
1827 "color": 1,
1827 "color": 1,
1828 "nextcol": 0,
1828 "nextcol": 0,
1829 "width": -1
1829 "width": -1
1830 },
1830 },
1831 {
1831 {
1832 "bcolor": "",
1832 "bcolor": "",
1833 "col": 1,
1833 "col": 1,
1834 "color": 2,
1834 "color": 2,
1835 "nextcol": 0,
1835 "nextcol": 0,
1836 "width": -1
1836 "width": -1
1837 }
1837 }
1838 ],
1838 ],
1839 "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8",
1839 "node": "f8bbb9024b10f93cdbb8d940337398291d40dea8",
1840 "parents": [
1840 "parents": [
1841 "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e"
1841 "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e"
1842 ],
1842 ],
1843 "phase": "public",
1843 "phase": "public",
1844 "row": 8,
1844 "row": 8,
1845 "tags": [],
1845 "tags": [],
1846 "user": "test"
1846 "user": "test"
1847 },
1847 },
1848 {
1848 {
1849 "bookmarks": [],
1849 "bookmarks": [],
1850 "branch": "default",
1850 "branch": "default",
1851 "col": 0,
1851 "col": 0,
1852 "color": 2,
1852 "color": 2,
1853 "date": [
1853 "date": [
1854 0.0,
1854 0.0,
1855 0
1855 0
1856 ],
1856 ],
1857 "desc": "initial",
1857 "desc": "initial",
1858 "edges": [],
1858 "edges": [],
1859 "node": "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e",
1859 "node": "06e557f3edf66faa1ccaba5dd8c203c21cc79f1e",
1860 "parents": [],
1860 "parents": [],
1861 "phase": "public",
1861 "phase": "public",
1862 "row": 9,
1862 "row": 9,
1863 "tags": [],
1863 "tags": [],
1864 "user": "test"
1864 "user": "test"
1865 }
1865 }
1866 ],
1866 ],
1867 "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7"
1867 "node": "cc725e08502a79dd1eda913760fbe06ed7a9abc7"
1868 }
1868 }
1869
1869
1870 help/ shows help topics
1870 help/ shows help topics
1871
1871
1872 $ request json-help
1872 $ request json-help
1873 200 Script output follows
1873 200 Script output follows
1874
1874
1875 {
1875 {
1876 "earlycommands": [
1876 "earlycommands": [
1877 {
1877 {
1878 "summary": "add the specified files on the next commit",
1878 "summary": "add the specified files on the next commit",
1879 "topic": "add"
1879 "topic": "add"
1880 },
1880 },
1881 {
1881 {
1882 "summary": "show changeset information by line for each file",
1882 "summary": "show changeset information by line for each file",
1883 "topic": "annotate"
1883 "topic": "annotate"
1884 },
1884 },
1885 {
1885 {
1886 "summary": "make a copy of an existing repository",
1886 "summary": "make a copy of an existing repository",
1887 "topic": "clone"
1887 "topic": "clone"
1888 },
1888 },
1889 {
1889 {
1890 "summary": "commit the specified files or all outstanding changes",
1890 "summary": "commit the specified files or all outstanding changes",
1891 "topic": "commit"
1891 "topic": "commit"
1892 },
1892 },
1893 {
1893 {
1894 "summary": "diff repository (or selected files)",
1894 "summary": "diff repository (or selected files)",
1895 "topic": "diff"
1895 "topic": "diff"
1896 },
1896 },
1897 {
1897 {
1898 "summary": "dump the header and diffs for one or more changesets",
1898 "summary": "dump the header and diffs for one or more changesets",
1899 "topic": "export"
1899 "topic": "export"
1900 },
1900 },
1901 {
1901 {
1902 "summary": "forget the specified files on the next commit",
1902 "summary": "forget the specified files on the next commit",
1903 "topic": "forget"
1903 "topic": "forget"
1904 },
1904 },
1905 {
1905 {
1906 "summary": "create a new repository in the given directory",
1906 "summary": "create a new repository in the given directory",
1907 "topic": "init"
1907 "topic": "init"
1908 },
1908 },
1909 {
1909 {
1910 "summary": "show revision history of entire repository or files",
1910 "summary": "show revision history of entire repository or files",
1911 "topic": "log"
1911 "topic": "log"
1912 },
1912 },
1913 {
1913 {
1914 "summary": "merge another revision into working directory",
1914 "summary": "merge another revision into working directory",
1915 "topic": "merge"
1915 "topic": "merge"
1916 },
1916 },
1917 {
1917 {
1918 "summary": "pull changes from the specified source",
1918 "summary": "pull changes from the specified source",
1919 "topic": "pull"
1919 "topic": "pull"
1920 },
1920 },
1921 {
1921 {
1922 "summary": "push changes to the specified destination",
1922 "summary": "push changes to the specified destination",
1923 "topic": "push"
1923 "topic": "push"
1924 },
1924 },
1925 {
1925 {
1926 "summary": "remove the specified files on the next commit",
1926 "summary": "remove the specified files on the next commit",
1927 "topic": "remove"
1927 "topic": "remove"
1928 },
1928 },
1929 {
1929 {
1930 "summary": "start stand-alone webserver",
1930 "summary": "start stand-alone webserver",
1931 "topic": "serve"
1931 "topic": "serve"
1932 },
1932 },
1933 {
1933 {
1934 "summary": "show changed files in the working directory",
1934 "summary": "show changed files in the working directory",
1935 "topic": "status"
1935 "topic": "status"
1936 },
1936 },
1937 {
1937 {
1938 "summary": "summarize working directory state",
1938 "summary": "summarize working directory state",
1939 "topic": "summary"
1939 "topic": "summary"
1940 },
1940 },
1941 {
1941 {
1942 "summary": "update working directory (or switch revisions)",
1942 "summary": "update working directory (or switch revisions)",
1943 "topic": "update"
1943 "topic": "update"
1944 }
1944 }
1945 ],
1945 ],
1946 "othercommands": [
1946 "othercommands": [
1947 {
1947 {
1948 "summary": "add all new files, delete all missing files",
1948 "summary": "add all new files, delete all missing files",
1949 "topic": "addremove"
1949 "topic": "addremove"
1950 },
1950 },
1951 {
1951 {
1952 "summary": "create an unversioned archive of a repository revision",
1952 "summary": "create an unversioned archive of a repository revision",
1953 "topic": "archive"
1953 "topic": "archive"
1954 },
1954 },
1955 {
1955 {
1956 "summary": "reverse effect of earlier changeset",
1956 "summary": "reverse effect of earlier changeset",
1957 "topic": "backout"
1957 "topic": "backout"
1958 },
1958 },
1959 {
1959 {
1960 "summary": "subdivision search of changesets",
1960 "summary": "subdivision search of changesets",
1961 "topic": "bisect"
1961 "topic": "bisect"
1962 },
1962 },
1963 {
1963 {
1964 "summary": "create a new bookmark or list existing bookmarks",
1964 "summary": "create a new bookmark or list existing bookmarks",
1965 "topic": "bookmarks"
1965 "topic": "bookmarks"
1966 },
1966 },
1967 {
1967 {
1968 "summary": "set or show the current branch name",
1968 "summary": "set or show the current branch name",
1969 "topic": "branch"
1969 "topic": "branch"
1970 },
1970 },
1971 {
1971 {
1972 "summary": "list repository named branches",
1972 "summary": "list repository named branches",
1973 "topic": "branches"
1973 "topic": "branches"
1974 },
1974 },
1975 {
1975 {
1976 "summary": "create a bundle file",
1976 "summary": "create a bundle file",
1977 "topic": "bundle"
1977 "topic": "bundle"
1978 },
1978 },
1979 {
1979 {
1980 "summary": "output the current or given revision of files",
1980 "summary": "output the current or given revision of files",
1981 "topic": "cat"
1981 "topic": "cat"
1982 },
1982 },
1983 {
1983 {
1984 "summary": "show combined config settings from all hgrc files",
1984 "summary": "show combined config settings from all hgrc files",
1985 "topic": "config"
1985 "topic": "config"
1986 },
1986 },
1987 {
1987 {
1988 "summary": "mark files as copied for the next commit",
1988 "summary": "mark files as copied for the next commit",
1989 "topic": "copy"
1989 "topic": "copy"
1990 },
1990 },
1991 {
1991 {
1992 "summary": "list tracked files",
1992 "summary": "list tracked files",
1993 "topic": "files"
1993 "topic": "files"
1994 },
1994 },
1995 {
1995 {
1996 "summary": "copy changes from other branches onto the current branch",
1996 "summary": "copy changes from other branches onto the current branch",
1997 "topic": "graft"
1997 "topic": "graft"
1998 },
1998 },
1999 {
1999 {
2000 "summary": "search revision history for a pattern in specified files",
2000 "summary": "search revision history for a pattern in specified files",
2001 "topic": "grep"
2001 "topic": "grep"
2002 },
2002 },
2003 {
2003 {
2004 "summary": "show branch heads",
2004 "summary": "show branch heads",
2005 "topic": "heads"
2005 "topic": "heads"
2006 },
2006 },
2007 {
2007 {
2008 "summary": "show help for a given topic or a help overview",
2008 "summary": "show help for a given topic or a help overview",
2009 "topic": "help"
2009 "topic": "help"
2010 },
2010 },
2011 {
2011 {
2012 "summary": "identify the working directory or specified revision",
2012 "summary": "identify the working directory or specified revision",
2013 "topic": "identify"
2013 "topic": "identify"
2014 },
2014 },
2015 {
2015 {
2016 "summary": "import an ordered set of patches",
2016 "summary": "import an ordered set of patches",
2017 "topic": "import"
2017 "topic": "import"
2018 },
2018 },
2019 {
2019 {
2020 "summary": "show new changesets found in source",
2020 "summary": "show new changesets found in source",
2021 "topic": "incoming"
2021 "topic": "incoming"
2022 },
2022 },
2023 {
2023 {
2024 "summary": "output the current or given revision of the project manifest",
2024 "summary": "output the current or given revision of the project manifest",
2025 "topic": "manifest"
2025 "topic": "manifest"
2026 },
2026 },
2027 {
2027 {
2028 "summary": "show changesets not found in the destination",
2028 "summary": "show changesets not found in the destination",
2029 "topic": "outgoing"
2029 "topic": "outgoing"
2030 },
2030 },
2031 {
2031 {
2032 "summary": "show aliases for remote repositories",
2032 "summary": "show aliases for remote repositories",
2033 "topic": "paths"
2033 "topic": "paths"
2034 },
2034 },
2035 {
2035 {
2036 "summary": "set or show the current phase name",
2036 "summary": "set or show the current phase name",
2037 "topic": "phase"
2037 "topic": "phase"
2038 },
2038 },
2039 {
2039 {
2040 "summary": "roll back an interrupted transaction",
2040 "summary": "roll back an interrupted transaction",
2041 "topic": "recover"
2041 "topic": "recover"
2042 },
2042 },
2043 {
2043 {
2044 "summary": "rename files; equivalent of copy + remove",
2044 "summary": "rename files; equivalent of copy + remove",
2045 "topic": "rename"
2045 "topic": "rename"
2046 },
2046 },
2047 {
2047 {
2048 "summary": "redo merges or set/view the merge status of files",
2048 "summary": "redo merges or set/view the merge status of files",
2049 "topic": "resolve"
2049 "topic": "resolve"
2050 },
2050 },
2051 {
2051 {
2052 "summary": "restore files to their checkout state",
2052 "summary": "restore files to their checkout state",
2053 "topic": "revert"
2053 "topic": "revert"
2054 },
2054 },
2055 {
2055 {
2056 "summary": "print the root (top) of the current working directory",
2056 "summary": "print the root (top) of the current working directory",
2057 "topic": "root"
2057 "topic": "root"
2058 },
2058 },
2059 {
2059 {
2060 "summary": "add one or more tags for the current or given revision",
2060 "summary": "add one or more tags for the current or given revision",
2061 "topic": "tag"
2061 "topic": "tag"
2062 },
2062 },
2063 {
2063 {
2064 "summary": "list repository tags",
2064 "summary": "list repository tags",
2065 "topic": "tags"
2065 "topic": "tags"
2066 },
2066 },
2067 {
2067 {
2068 "summary": "apply one or more bundle files",
2068 "summary": "apply one or more bundle files",
2069 "topic": "unbundle"
2069 "topic": "unbundle"
2070 },
2070 },
2071 {
2071 {
2072 "summary": "verify the integrity of the repository",
2072 "summary": "verify the integrity of the repository",
2073 "topic": "verify"
2073 "topic": "verify"
2074 },
2074 },
2075 {
2075 {
2076 "summary": "output version and copyright information",
2076 "summary": "output version and copyright information",
2077 "topic": "version"
2077 "topic": "version"
2078 }
2078 }
2079 ],
2079 ],
2080 "topics": [
2080 "topics": [
2081 {
2081 {
2082 "summary": "Bundle File Formats",
2082 "summary": "Bundle File Formats",
2083 "topic": "bundlespec"
2083 "topic": "bundlespec"
2084 },
2084 },
2085 {
2085 {
2086 "summary": "Colorizing Outputs",
2086 "summary": "Colorizing Outputs",
2087 "topic": "color"
2087 "topic": "color"
2088 },
2088 },
2089 {
2089 {
2090 "summary": "Configuration Files",
2090 "summary": "Configuration Files",
2091 "topic": "config"
2091 "topic": "config"
2092 },
2092 },
2093 {
2093 {
2094 "summary": "Date Formats",
2094 "summary": "Date Formats",
2095 "topic": "dates"
2095 "topic": "dates"
2096 },
2096 },
2097 {
2097 {
2098 "summary": "Deprecated Features",
2098 "summary": "Deprecated Features",
2099 "topic": "deprecated"
2099 "topic": "deprecated"
2100 },
2100 },
2101 {
2101 {
2102 "summary": "Diff Formats",
2102 "summary": "Diff Formats",
2103 "topic": "diffs"
2103 "topic": "diffs"
2104 },
2104 },
2105 {
2105 {
2106 "summary": "Environment Variables",
2106 "summary": "Environment Variables",
2107 "topic": "environment"
2107 "topic": "environment"
2108 },
2108 },
2109 {
2109 {
2110 "summary": "Using Additional Features",
2110 "summary": "Using Additional Features",
2111 "topic": "extensions"
2111 "topic": "extensions"
2112 },
2112 },
2113 {
2113 {
2114 "summary": "Specifying File Sets",
2114 "summary": "Specifying File Sets",
2115 "topic": "filesets"
2115 "topic": "filesets"
2116 },
2116 },
2117 {
2117 {
2118 "summary": "Command-line flags",
2118 "summary": "Command-line flags",
2119 "topic": "flags"
2119 "topic": "flags"
2120 },
2120 },
2121 {
2121 {
2122 "summary": "Glossary",
2122 "summary": "Glossary",
2123 "topic": "glossary"
2123 "topic": "glossary"
2124 },
2124 },
2125 {
2125 {
2126 "summary": "Syntax for Mercurial Ignore Files",
2126 "summary": "Syntax for Mercurial Ignore Files",
2127 "topic": "hgignore"
2127 "topic": "hgignore"
2128 },
2128 },
2129 {
2129 {
2130 "summary": "Configuring hgweb",
2130 "summary": "Configuring hgweb",
2131 "topic": "hgweb"
2131 "topic": "hgweb"
2132 },
2132 },
2133 {
2133 {
2134 "summary": "Technical implementation topics",
2134 "summary": "Technical implementation topics",
2135 "topic": "internals"
2135 "topic": "internals"
2136 },
2136 },
2137 {
2137 {
2138 "summary": "Merge Tools",
2138 "summary": "Merge Tools",
2139 "topic": "merge-tools"
2139 "topic": "merge-tools"
2140 },
2140 },
2141 {
2141 {
2142 "summary": "Pager Support",
2142 "summary": "Pager Support",
2143 "topic": "pager"
2143 "topic": "pager"
2144 },
2144 },
2145 {
2145 {
2146 "summary": "File Name Patterns",
2146 "summary": "File Name Patterns",
2147 "topic": "patterns"
2147 "topic": "patterns"
2148 },
2148 },
2149 {
2149 {
2150 "summary": "Working with Phases",
2150 "summary": "Working with Phases",
2151 "topic": "phases"
2151 "topic": "phases"
2152 },
2152 },
2153 {
2153 {
2154 "summary": "Specifying Revisions",
2154 "summary": "Specifying Revisions",
2155 "topic": "revisions"
2155 "topic": "revisions"
2156 },
2156 },
2157 {
2157 {
2158 "summary": "Using Mercurial from scripts and automation",
2158 "summary": "Using Mercurial from scripts and automation",
2159 "topic": "scripting"
2159 "topic": "scripting"
2160 },
2160 },
2161 {
2161 {
2162 "summary": "Subrepositories",
2162 "summary": "Subrepositories",
2163 "topic": "subrepos"
2163 "topic": "subrepos"
2164 },
2164 },
2165 {
2165 {
2166 "summary": "Template Usage",
2166 "summary": "Template Usage",
2167 "topic": "templating"
2167 "topic": "templating"
2168 },
2168 },
2169 {
2169 {
2170 "summary": "URL Paths",
2170 "summary": "URL Paths",
2171 "topic": "urls"
2171 "topic": "urls"
2172 }
2172 }
2173 ]
2173 ]
2174 }
2174 }
2175
2175
2176 help/{topic} shows an individual help topic
2176 help/{topic} shows an individual help topic
2177
2177
2178 $ request json-help/phases
2178 $ request json-help/phases
2179 200 Script output follows
2179 200 Script output follows
2180
2180
2181 {
2181 {
2182 "rawdoc": "Working with Phases\n*", (glob)
2182 "rawdoc": "Working with Phases\n*", (glob)
2183 "topic": "phases"
2183 "topic": "phases"
2184 }
2184 }
2185
2185
2186 Error page shouldn't crash
2187
2188 $ request json-changeset/deadbeef
2189 404 Not Found
2190
2191 {
2192 "error": "unknown revision 'deadbeef'"
2193 }
2194 [1]
2195
2186 Commit message with Japanese Kanji 'Noh', which ends with '\x5c'
2196 Commit message with Japanese Kanji 'Noh', which ends with '\x5c'
2187
2197
2188 $ echo foo >> da/foo
2198 $ echo foo >> da/foo
2189 $ HGENCODING=cp932 hg ci -m `$PYTHON -c 'print("\x94\x5c")'`
2199 $ HGENCODING=cp932 hg ci -m `$PYTHON -c 'print("\x94\x5c")'`
2190
2200
2191 Commit message with null character
2201 Commit message with null character
2192
2202
2193 $ echo foo >> da/foo
2203 $ echo foo >> da/foo
2194 >>> open('msg', 'wb').write('commit with null character: \0\n')
2204 >>> open('msg', 'wb').write('commit with null character: \0\n')
2195 $ hg ci -l msg
2205 $ hg ci -l msg
2196 $ rm msg
2206 $ rm msg
2197
2207
2198 Stop and restart with HGENCODING=cp932
2208 Stop and restart with HGENCODING=cp932
2199
2209
2200 $ killdaemons.py
2210 $ killdaemons.py
2201 $ HGENCODING=cp932 hg serve -p $HGPORT -d --pid-file=hg.pid \
2211 $ HGENCODING=cp932 hg serve -p $HGPORT -d --pid-file=hg.pid \
2202 > -A access.log -E error.log
2212 > -A access.log -E error.log
2203 $ cat hg.pid >> $DAEMON_PIDS
2213 $ cat hg.pid >> $DAEMON_PIDS
2204
2214
2205 Test json escape of multibyte characters
2215 Test json escape of multibyte characters
2206
2216
2207 $ request json-filelog/tip/da/foo?revcount=2 | grep '"desc":'
2217 $ request json-filelog/tip/da/foo?revcount=2 | grep '"desc":'
2208 "desc": "commit with null character: \u0000",
2218 "desc": "commit with null character: \u0000",
2209 "desc": "\u80fd",
2219 "desc": "\u80fd",
General Comments 0
You need to be logged in to leave comments. Login now