Page Menu
Home
Phabricator
Search
Configure Global Search
Log In
Files
F78490
hg_wire_proto.py
All Users
Actions
View File
Edit File
Delete File
View Transforms
Subscribe
Mute Notifications
Flag For Later
Award Token
Authored By
epriestley
Nov 5 2013, 3:43 AM
2013-11-05 03:43:01 (UTC+0)
Size
621 B
Referenced Files
None
Subscribers
None
hg_wire_proto.py
View Options
# list of nodes encoding / decoding
def
decodelist
(
l
,
sep
=
' '
):
if
l
:
return
map
(
bin
,
l
.
split
(
sep
))
return
[]
def
encodelist
(
l
,
sep
=
' '
):
return
sep
.
join
(
map
(
hex
,
l
))
# batched call argument encoding
def
escapearg
(
plain
):
return
(
plain
.
replace
(
':'
,
'::'
)
.
replace
(
','
,
':,'
)
.
replace
(
';'
,
':;'
)
.
replace
(
'='
,
':='
))
def
unescapearg
(
escaped
):
return
(
escaped
.
replace
(
':='
,
'='
)
.
replace
(
':;'
,
';'
)
.
replace
(
':,'
,
','
)
.
replace
(
'::'
,
':'
))
# client side
def
todict
(
**
args
):
return
args
File Metadata
Details
Attached
Mime Type
text/plain; charset=utf-8
Storage Engine
amazon-s3
Storage Format
Raw Data
Storage Handle
phabricator/yi/6z/ztcovvnbcrxgsawj
Default Alt Text
hg_wire_proto.py (621 B)
Attached To
Mode
P968 hg_wire_proto.py
Attached
Detach File
Event Timeline
Log In to Comment