Mailinglist Archive: opensuse-buildservice (193 mails)

< Previous Next >
[opensuse-buildservice] Bash completion for osc
  • From: Christian Boltz <opensuse@xxxxxxxxx>
  • Date: Sun, 22 Apr 2007 15:30:09 +0200
  • Message-id: <200704221530.09800@xxxxxxxxxxxxxxx>
Hello,

I just thought that bash completion for osc would be a nice idea ;-)

Basically the following works:

complete -W "`osc help  |
    sed -n '/^  *[a-z]*/ s/^  *\([a-z]*\).*$/\1/p'`" -f osc
(to be put into a script in /etc/bash_completion.d/ or ~/.bashrc)

Disadvantage: it needs some time at login because it always runs osc 
help. The better way is to run osc help only when needed - 
see /etc/bash_completion.d/yast2-completion.sh for a template.
(Any volunteers? ;-)


Regards,

Christian Boltz
-- 
Jedes meiner Postings ist alt genug, um für sich selbst zu sprechen.
Ich übernehme keinerlei Verantwortung für das Verhalten meiner Mails.
---------------------------------------------------------------------
To unsubscribe, e-mail: opensuse-buildservice+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: opensuse-buildservice+help@xxxxxxxxxxxx

< Previous Next >
Follow Ups