misc: add a random number to build directory (#44527)
This commit is contained in:
parent
6704539ab5
commit
cfe87cda7e
|
@ -1,6 +1,7 @@
|
|||
#!/usr/bin/env python3
|
||||
|
||||
import atexit
|
||||
import random
|
||||
import re
|
||||
import shutil
|
||||
import subprocess
|
||||
|
@ -115,7 +116,7 @@ def get_project_infos(git_project_path, cmd_options):
|
|||
error("Unsupported project type", exit_code=2)
|
||||
|
||||
results['build_dir'] = os.path.join(
|
||||
settings.EOBUILDER_TMP, results['name']
|
||||
settings.EOBUILDER_TMP, '%s-%d' % (results['name'], random.randint(0, 1000000))
|
||||
)
|
||||
atexit.register(rm_recursive, results['build_dir'])
|
||||
results['commit_number'] = output("git rev-parse HEAD")[:-1]
|
||||
|
|
Loading…
Reference in New Issue