On Oct 14, 11:49 pm, Jeff Anderson <[EMAIL PROTECTED]> wrote:
> [EMAIL PROTECTED] wrote:
> > Depending on your site's setup, there is a variety of extra manage.py
> > commands that could be available. Is it possible to set up tab
> > completion on these commands? for example:
>
> > ./manage.py syn<tab>
> > => /manage.py syncdb
>
> > If it is not currently supported, how hard would it be to include?
> > Would it use the readline library?
>
> This is already implemented with a bash completion script. I'm not 100%
> sure where in svn it lives, but its there, and it works.
>
> Jeff Anderson
>
>  signature.asc
> < 1KViewDownload

The django_bash_completion script is in the extras directory of the
root Django checkout. Although I think the OP was asking how to get
tab completion for custom manage.py commands.

I've been mucking around with this recently, and keep meaning to file
a patch. My current approach involves getting the shell to run ./
manage.py help and then piping the results through sed, but this isn't
very efficient and doesn't work very well with command-specific
options. I think a better way would be to add some hooks into Django
itself - probably in core.management - to return a list of all
commands, and also provide a way for command authors to declare what
options their commands provide. Although there's a niggling suspicion
that all this might be overkill for a fairly obscure feature...
--
DR.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups 
"Django users" group.
To post to this group, send email to django-users@googlegroups.com
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to