Accepting request 660057 from home:jengelh:branches:Base:System
- Avoid bashisms in scriptlets. OBS-URL: https://build.opensuse.org/request/show/660057 OBS-URL: https://build.opensuse.org/package/show/Base:System/dbus-1?expand=0&rev=271
This commit is contained in:
parent
79c8595d8b
commit
ad77c422a0
@ -1,3 +1,8 @@
|
||||
-------------------------------------------------------------------
|
||||
Wed Dec 19 16:17:39 UTC 2018 - Jan Engelhardt <jengelh@inai.de>
|
||||
|
||||
- Avoid bashisms in scriptlets.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Tue Nov 20 23:37:09 UTC 2018 - eich@suse.com
|
||||
|
||||
|
@ -12,7 +12,7 @@
|
||||
# license that conforms to the Open Source Definition (Version 1.9)
|
||||
# published by the Open Source Initiative.
|
||||
|
||||
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
||||
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
||||
#
|
||||
|
||||
|
||||
|
@ -1,3 +1,8 @@
|
||||
-------------------------------------------------------------------
|
||||
Wed Dec 19 16:17:39 UTC 2018 - Jan Engelhardt <jengelh@inai.de>
|
||||
|
||||
- Avoid bashisms in scriptlets.
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Tue Nov 20 23:37:09 UTC 2018 - eich@suse.com
|
||||
|
||||
|
12
dbus-1.spec
12
dbus-1.spec
@ -12,7 +12,7 @@
|
||||
# license that conforms to the Open Source Definition (Version 1.9)
|
||||
# published by the Open Source Initiative.
|
||||
|
||||
# Please submit bugfixes or comments via http://bugs.opensuse.org/
|
||||
# Please submit bugfixes or comments via https://bugs.opensuse.org/
|
||||
#
|
||||
|
||||
|
||||
@ -229,15 +229,15 @@ getent passwd messagebus >/dev/null || \
|
||||
# removed reletavly soon.
|
||||
|
||||
# Get the current version
|
||||
if [[ "$FIRST_ARG" -gt 1 ]]; then
|
||||
if [ "$FIRST_ARG" -gt 1 ]; then
|
||||
CURRENT_VER=$(/usr/bin/dbus-daemon --version 2>/dev/null| sed 's/^.*[^0-9]\([0-9]*\.[0-9]*\.[0-9]*\).*$/\1/' | head -1)
|
||||
|
||||
# If the current version is or less then 1.10.2 where this change was added then migration needs to be run
|
||||
# The following line will return 1.10.2 if its newer then the current version
|
||||
TEST_VER=$(printf "1.10.2\n$CURRENT_VER" | sort -Vr | head -1)
|
||||
|
||||
if [[ $TEST_VER == "1.10.12" ]]; then
|
||||
if [[ -f /etc/sysconfig/services ]]; then
|
||||
if [ "$TEST_VER" = "1.10.12" ]; then
|
||||
if [ -f /etc/sysconfig/services ]; then
|
||||
cp -a /etc/sysconfig/services %{_backup}
|
||||
else
|
||||
touch %{_backup}
|
||||
@ -281,9 +281,9 @@ export DISABLE_RESTART_ON_UPDATE=yes
|
||||
|
||||
%posttrans
|
||||
# See comments in pre
|
||||
if [[ -s %{_backup} ]]; then
|
||||
if [ -s "%{_backup}" ]; then
|
||||
mv -f %{_backup} /etc/sysconfig/services
|
||||
elif [[ -e %{_backup} ]]; then
|
||||
elif [ -e "%{_backup}" ]; then
|
||||
rm -f /etc/sysconfig/services
|
||||
fi
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user