File tree Expand file tree Collapse file tree 1 file changed +6
-7
lines changed Expand file tree Collapse file tree 1 file changed +6
-7
lines changed Original file line number Diff line number Diff line change 77
88
99def files_filter (dir , items : List [str ]) -> List [str ]:
10- ignored_dirs = ['protos' , '.git' ]
10+ ignored_names = ['.git' ]
1111
1212 ignore = []
1313 for item in items :
1414 fullpath = os .path .join (dir , item )
15- if os .path .isdir (fullpath ) and item not in ignored_dirs :
15+ if os .path .isdir (fullpath ) and item not in ignored_names :
1616 continue
1717 if item .endswith (".proto" ):
1818 continue
@@ -32,12 +32,11 @@ def create_init_files(dir):
3232
3333def replace_protos_dir ():
3434 def replace_dir (src , dst ):
35- shutil .rmtree (dst )
35+ shutil .rmtree (dst , ignore_errors = True )
3636 shutil .copytree (src , dst , ignore = files_filter )
3737 create_init_files (dst )
3838
39- replace_dir ("ydb-api-protos" , "ydb/public/api/grpc" )
40- replace_dir ("ydb-api-protos/protos" , "ydb/public/api/protos" )
39+ replace_dir ("ydb-api-protos" , "ydb/_grpc" )
4140
4241
4342def remove_protos ():
@@ -49,5 +48,5 @@ def remove_protos():
4948
5049if __name__ == '__main__' :
5150 replace_protos_dir ()
52- command .build_package_protos ('./ ydb/public/api/' )
53- remove_protos ()
51+ command .build_package_protos (" ydb/_grpc" )
52+ # remove_protos()
You can’t perform that action at this time.
0 commit comments