#7972 closed (invalid)
allow argv options anywhere on command line
Reported by: | mukappa | Owned by: | nobody |
---|---|---|---|
Component: | Core (Management commands) | Version: | dev |
Severity: | Keywords: | ||
Cc: | Triage Stage: | Unreviewed | |
Has patch: | yes | Needs documentation: | no |
Needs tests: | no | Patch needs improvement: | no |
Easy pickings: | no | UI/UX: | no |
Description
I don't like having to remember exactly where --settings=xxx
goes.
Attachments (1)
Change History (4)
by , 16 years ago
Attachment: | argvorder.diff added |
---|
comment:1 by , 16 years ago
Resolution: | → invalid |
---|---|
Status: | new → closed |
comment:2 by , 16 years ago
from http://www.python.org/doc/2.5.2/lib/module-optparse.html the following command lines are all equivalent
<yourscript> -f outfile --quiet <yourscript> --quiet --file outfile <yourscript> -q -foutfile <yourscript> -qfoutfile
I think that implies
$ python manage.py --settings=settings shell
and
$ python manage.py shell --settings=settings
are equivalent.
but for manage.py (and django-admin.py)
$ python manage.py --settings=settings shell Unknown command: '--settings=settings'
manage.py cares where its options are, but I don't see where it needs to. I sometimes put an option in the "wrong" place and find it frustrating to have to check the usage.
Thanks.
comment:3 by , 16 years ago
Sorry, my brain saw what it wanted to see, not what was there in the excerpt from the optparse doc.
Nonetheless, optparse allows mixing options anywhere between and around args, and I'll leave it at that.
I don't like bug reports that don't explain what the problem is.