Your message dated Thu, 16 Jun 2016 09:42:46 +0200
with message-id <[email protected]>
and subject line Re: [PKG-Openstack-devel] Bug#827368: openstack-pkg-tools:
/usr/share/openstack-pkg-tools/pkgos_func:pkgos_inifile get - does not work
has caused the Debian Bug report #827368,
regarding openstack-pkg-tools:
/usr/share/openstack-pkg-tools/pkgos_func:pkgos_inifile get - does not work
to be marked as done.
This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.
(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact [email protected]
immediately.)
--
827368: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=827368
Debian Bug Tracking System
Contact [email protected] with problems
--- Begin Message ---
Package: openstack-pkg-tools
Version: 50
Severity: minor
Sourcing /usr/share/openstack-pkg-tools/pkgos_func in the shell and then
trying to use the "get" part of it does not work:
----- s n i p -----
bladeA01b:~# . /usr/share/openstack-pkg-tools/pkgos_func
bladeA01b:~# export PKGOS_VERBOSE=yes
bladeA01b:~# pkgos_inifile get /etc/cinder/cinder.conf DEFAULT enabled_backends
pkgos_inifile: Getting value in
/etc/cinder/cinder.conf:[DEFAULT]/enabled_backends
bladeA01b:~# grep ^enabled_backends /etc/cinder/cinder.conf
enabled_backends = lvm
----- s n i p -----
The "set" part works like a charm though!
-- System Information:
Debian Release: stretch/sid
APT prefers unstable
APT policy: (500, 'unstable')
Architecture: amd64 (x86_64)
Kernel: Linux 3.16.0-4-amd64 (SMP w/16 CPU cores)
Locale: LANG=C, LC_CTYPE=C (charmap=ANSI_X3.4-1968)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)
Versions of packages openstack-pkg-tools depends on:
ii autopkgtest 4.0
ii libxml-xpath-perl 1.36-1
ii madison-lite 0.21
ii pristine-tar 1.34
openstack-pkg-tools recommends no packages.
openstack-pkg-tools suggests no packages.
-- no debconf information
--- End Message ---
--- Begin Message ---
On 06/15/2016 02:11 PM, Turbo Fredriksson wrote:
> Package: openstack-pkg-tools
> Version: 50
> Severity: minor
>
> Sourcing /usr/share/openstack-pkg-tools/pkgos_func in the shell and then
> trying to use the "get" part of it does not work:
>
> ----- s n i p -----
> bladeA01b:~# . /usr/share/openstack-pkg-tools/pkgos_func
> bladeA01b:~# export PKGOS_VERBOSE=yes
> bladeA01b:~# pkgos_inifile get /etc/cinder/cinder.conf DEFAULT
> enabled_backends
> pkgos_inifile: Getting value in
> /etc/cinder/cinder.conf:[DEFAULT]/enabled_backends
> bladeA01b:~# grep ^enabled_backends /etc/cinder/cinder.conf
> enabled_backends = lvm
> ----- s n i p -----
>
> The "set" part works like a charm though!
This is *not* the way the function works. The return value of the
function is the error message. The value of the directive you're
searching for is set in the $RET variable. For example, this would be
the output:
# pkgos_inifile get /etc/cinder/cinder.conf DEFAULT enabled_backends
# echo $RET
lvm
#
And it's looking like to me that the function works perfectly (even
though it's too slow).
On 06/15/2016 03:07 PM, Turbo Fredriksson wrote:
> I had also hoped that this work(ed):
> pkgos_inifile get /etc/cinder/cinder.conf DEFAULT
> to retrieve ALL values in the "DEFAULT" section..
openstack-pkg-tools is *not* a shell helper. Its intention is to be
useful for package maintainers. While I do understand the above could be
useful, it's not something we need at the packaging level.
Cheers,
Thomas Goirand (zigo)
--- End Message ---