aboutsummaryrefslogtreecommitdiffstats
path: root/build/scripts/merge_coverage_data.py
diff options
context:
space:
mode:
authormonster <monster@ydb.tech>2022-07-07 14:41:37 +0300
committermonster <monster@ydb.tech>2022-07-07 14:41:37 +0300
commit06e5c21a835c0e923506c4ff27929f34e00761c2 (patch)
tree75efcbc6854ef9bd476eb8bf00cc5c900da436a2 /build/scripts/merge_coverage_data.py
parent03f024c4412e3aa613bb543cf1660176320ba8f4 (diff)
downloadydb-06e5c21a835c0e923506c4ff27929f34e00761c2.tar.gz
fix ya.make
Diffstat (limited to 'build/scripts/merge_coverage_data.py')
-rw-r--r--build/scripts/merge_coverage_data.py32
1 files changed, 0 insertions, 32 deletions
diff --git a/build/scripts/merge_coverage_data.py b/build/scripts/merge_coverage_data.py
deleted file mode 100644
index b7fa3c6a86..0000000000
--- a/build/scripts/merge_coverage_data.py
+++ /dev/null
@@ -1,32 +0,0 @@
-import sys
-import tarfile
-import copy
-import os
-import uuid
-
-
-def main(args):
- output_file, args = args[0], args[1:]
- # heretic@: Splits files on which could be merged( files ) and which should not be merged( expendables )
- # expendables will be in output_file in form {name}{ordinal number of archive in args[]}.{extension}
- try:
- split_i = args.index('-no-merge')
- except ValueError:
- split_i = len(args)
- files, expendables = args[:split_i], args[split_i + 1:]
-
- with tarfile.open(output_file, 'w') as outf:
- for x in files:
- with tarfile.open(x) as tf:
- for tarinfo in tf:
- new_tarinfo = copy.deepcopy(tarinfo)
- if new_tarinfo.name in expendables:
- dirname, basename = os.path.split(new_tarinfo.name)
- basename_parts = basename.split('.', 1)
- new_basename = '.'.join([basename_parts[0] + str(uuid.uuid4())] + basename_parts[1:])
- new_tarinfo.name = os.path.join(dirname, new_basename)
- outf.addfile(new_tarinfo, tf.extractfile(tarinfo))
-
-
-if __name__ == '__main__':
- main(sys.argv[1:])