Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #67098

Re: Python : parsing the command line options using optparse

Date 2014-02-26 09:32 -0500
From rodperson@rodperson.com
Subject Re: Python : parsing the command line options using optparse
References <CACT3xuWuV8omgE6oV0PNGfwdf-yrO3KPbjHtu=B+NHNuOhA_Jw@mail.gmail.com> <leig4s$ri5$1@ger.gmane.org> <CACT3xuUGtsER0B3xwAB2CqQ5Zb=v72w8+DQkaYz681xeSeJ2CQ@mail.gmail.com>
Newsgroups comp.lang.python
Message-ID <mailman.7396.1393425495.18130.python-list@python.org> (permalink)

Show all headers | View raw


On 2014-02-26 04:30, Ganesh Pal wrote:
> On Tue, Feb 25, 2014 at 9:55 PM, Peter
> Otten <__peter__@web.de> wrote:
> 
>> As you are just starting I recommend that you use argparse instead of
>  optparse.
> 
>  I would love to use argparse but  the script that I plan to write
> has to run on host machines that Python 2.6
> 
>  I have freebsd clients  with python  2.6  dont want to install
> python new version on all the host machine which will be eventually
> upgraded to 2.7 .
> 
> I wanted know if I could use argparse with python 2.6 and is it
> possible to add  something like   #pkg_add -r install
> python-argparse and install python argparse module before I use it.

They must be running an older version of FreeBSD since the default 
version of python is 2.7.

There is a FreeBSD package for argparse, the command would be something 
like
    pkg_add -r install py26-argparse


Rod

Back to comp.lang.python | Previous | Next | Find similar | Unroll thread


Thread

Re: Python : parsing the command line options using optparse rodperson@rodperson.com - 2014-02-26 09:32 -0500

csiph-web