推荐学习书目
› Learn Python the Hard Way
Python Sites
› PyPI - Python Package Index
› http://diveintopython.org/toc/index.html
› Pocoo
值得关注的项目
› PyPy
› Celery
› Jinja2
› Read the Docs
› gevent
› pyenv
› virtualenv
› Stackless Python
› Beautiful Soup
› 结巴中文分词
› Green Unicorn
› Sentry
› Shovel
› Pyflakes
› pytest
Python 编程
› pep8 Checker
Styles
› PEP 8
› Google Python Style Guide
› Code Style from The Hitchhiker's Guide
pyengwoei
V2EX  ›  Python

请问 Popen 模块的这一坨参数是什么意思

  •  
  •   pyengwoei · Aug 31, 2016 · 3034 views
    This topic created in 3723 days ago, the information mentioned may be changed or developed.

    网上说的用法不是这样吗
    aaa = "G:/New.exe"
    Popen(aaa, shell=True)
    8 replies  •  2016-09-01 11:04:52 +08:00
    julyclyde
    julyclyde
    Aug 31, 2016
    1
    Popen 模块是什么?
    julyclyde
    julyclyde
    Aug 31, 2016
    2
    提醒你注意一下那个方括号,再参悟一下函数调用的语法
    ericls
    ericls
    Aug 31, 2016
    3
    那只是列表里面的元素而已
    zguangyu123
    zguangyu123
    Aug 31, 2016
    4
    这些参数是传给 popen 调用的程序的参数。
    pyengwoei
    pyengwoei
    OP
    Aug 31, 2016
    5
    @zguangyu123 Popen 的参数我看格式都不是这样的啦
    pyengwoei
    pyengwoei
    OP
    Aug 31, 2016
    6
    @ericls 我知道是列表里面的元素,但是这个传进去有什么用啦
    julyclyde
    julyclyde
    Aug 31, 2016
    7
    @pyengwoei 起什么作用要由被运行的那个程序来解释
    zerofiny
    zerofiny
    Sep 1, 2016
    8
    subprocess.Popen 你标注那些是执行程序需要的参数
    这个函数执行带参数 就是 Popen(['ls', '-als'])
    这个函数一系列参数 bufsize=0, executable=None, stdin=None, stdout=None, stderr=None, preexec_fn=None, close_fds=False, shell=False, cwd=None, env=None, universal_newlines=False, startupinfo=None, creationflags=0
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Privacy   ·   Solana   ·   2802 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 27ms · UTC 05:10 · PVG 13:10 · LAX 21:10 · JFK 00:10
    ♥ Do have faith in what you're doing.