Jer*_*rub 12 python command-line arguments
我希望能够在我的Python 2.6程序中解析命令行参数.
理想情况下,我希望能够处理这些情况:
# Show some help
./myprogram --help
# These are equivalent
./myprogram --block=1
./myprogram -b 1
# This means verbose, and twice as verbose:
./myprogram -v
./myprogram -vv
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
20907 次 |
| 最近记录: |