[Android] Pass -p to mkdir commands
These commands should not fail if the parent directory does not exist. Pass -p so that all the parent directories are also made. Review URL: https://chromiumcodereview.appspot.com/14795012 git-svn-id: http://src.chromium.org/svn/trunk/src/build@200456 4ff67af0-8c30-449e-8e8b-ad334ec8d88c
This commit is contained in:
Родитель
f13445c6a5
Коммит
e2f9224298
|
@ -58,7 +58,7 @@ def TriggerSymlinkScript(options):
|
|||
|
||||
adb = android_commands.AndroidCommands()
|
||||
device_dir = os.path.dirname(options.script_device_path)
|
||||
mkdir_cmd = ('if [ ! -e %(dir)s ]; then mkdir %(dir)s; fi ' %
|
||||
mkdir_cmd = ('if [ ! -e %(dir)s ]; then mkdir -p %(dir)s; fi ' %
|
||||
{ 'dir': device_dir })
|
||||
RunShellCommand(adb, mkdir_cmd)
|
||||
adb.PushIfNeeded(options.script_host_path, options.script_device_path)
|
||||
|
|
|
@ -35,7 +35,7 @@ def DoPush(options):
|
|||
|
||||
def Push():
|
||||
if needs_directory:
|
||||
adb.RunShellCommand('mkdir ' + options.device_dir)
|
||||
adb.RunShellCommand('mkdir -p ' + options.device_dir)
|
||||
needs_directory[:] = [] # = False
|
||||
adb.PushIfNeeded(host_path, device_path)
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче