third_party_nghttp2/mkstatichdtbl.py
2013-10-16 01:23:10 +09:00

9 lines
289 B
Python
Executable File

#!/usr/bin/env python
import re, sys
for line in sys.stdin:
m = re.match(r'(\d+)\s+(\S+)\s+(\S+)?', line)
print '/* {} */ "{}", "{}",'.format(m.group(1),
m.group(2),
m.group(3) if m.group(3) else '')