python - subprocess.call requiring all parameters to be separated by commas -


i used able subprocess.call(["command","-option value -option value"]) , work there change command work things in quotes, have change subprocess call command this:

subprocess.call(["command","-option","value","-option","value"]) 

is there can work other way again in python?

the os.system("command -option value -option value") works same did before.

you'll need specify shell=true subprocess.call interpret string.

see note in subprocess.popen constructor documentation (the subprocess.call method takes same arguments subprocess.popen constructor).


Comments

Popular posts from this blog

angular - DownloadURL return null in below code -

python 2.7 - Given three nested dictionaries, sort the top two nested dictionaries from a value in the innermost dictionary? -