Bugzilla – Attachment 26477 Details for
Bug 10003
koha-* scripts (packages) should provide tab-completion in bash
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
Bug 10003: (followup) use sudo to get the instances list
Bug-10003-followup-use-sudo-to-get-the-instances-l.patch (text/plain), 1.68 KB, created by
Jonathan Druart
on 2014-03-20 10:50:31 UTC
(
hide
)
Description:
Bug 10003: (followup) use sudo to get the instances list
Filename:
MIME Type:
Creator:
Jonathan Druart
Created:
2014-03-20 10:50:31 UTC
Size:
1.68 KB
patch
obsolete
>From aa5b64c88d168884058b166222ac564b076ea528 Mon Sep 17 00:00:00 2001 >From: Tomas Cohen Arazi <tomascohen@gmail.com> >Date: Thu, 19 Dec 2013 15:15:19 -0300 >Subject: [PATCH] Bug 10003: (followup) use sudo to get the instances list > >Te only way of using the koha-* commands is using sudo. The only way >to get the list of enabled instances and other insight information of >the instances is through the use of sudo. >This followup makes the tab-completion bash script use sudo for calling >'koha-list' so it can read teh relevant data. > >The drawback of this approach is that the user will be prompted for password >the first time he/she presses the tab key twice (triggering tab-completion). > >I see no problem with that. And is the only option available, apart from the >setuid one. Which I don't like. > >Regards >To+ > >Sponsored-by: Universidad Nacional de Cordoba >Signed-off-by: Dobrica Pavlinusic <dpavlin@rot13.org> > >Signed-off-by: Jonathan Druart <jonathan.druart@biblibre.com> >--- > debian/koha-common.bash-completion | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > >diff --git a/debian/koha-common.bash-completion b/debian/koha-common.bash-completion >index 934e279..b3eeeda 100644 >--- a/debian/koha-common.bash-completion >+++ b/debian/koha-common.bash-completion >@@ -54,9 +54,9 @@ _koha_list_cmd() > substract=`_build_substract_instances` > > if [[ "$substract" != "" ]]; then >- instancelist=$( koha-list $filter | grep -v -x $substract ) >+ instancelist=$( sudo koha-list $filter | grep -v -x $substract ) > else >- instancelist=$( koha-list $filer ) >+ instancelist=$( sudo koha-list $filer ) > fi > > COMPREPLY=( $(compgen -W "$instancelist" -- $cur ) ) >-- >1.7.10.4
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 10003
:
20743
|
22609
|
23701
|
26179
|
26180
|
26476
| 26477