Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
branch: master
Fetching contributors…

Octocat-spinner-32-eaf2f5

Cannot retrieve contributors at this time

file 28 lines (23 sloc) 0.601 kb
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27
import subprocess
import sys
import os

if len(sys.argv) < 3:
print "Usage: %s in_dir out_dir" % sys.argv[0]
sys.exit()

in_dir = sys.argv[1]
out_dir = sys.argv[2]

in_files = []
for root, dirs, files in os.walk(in_dir):
for file in files:
in_files.append(os.path.join(root, file))

#for file in in_files:
# print "Building " + file
subprocess.call([
"protogen",
"--proto_path=%s" % in_dir,
"--include_imports",
"-service_generator_type=GENERIC",
"-expand_namespace_directories=true",
"-cls_compliance=false",
"-ignore_google_protobuf=true",
"-output_directory=%s" % out_dir] + in_files)
Something went wrong with that request. Please try again.