Improvement of vconftool/buxton_ensure_group 32/37532/1 accepted/tizen/common/20150331.084952 accepted/tizen/mobile/20150401.133325 accepted/tizen/tv/20150403.074438 accepted/tizen/wearable/20150402.123217 submit/tizen_common/20150330.150644 submit/tizen_mobile/20150331.052625 submit/tizen_tv/20150331.052625 submit/tizen_wearable/20150331.052625
authorJosé Bollo <jose.bollo@open.eurogiciel.org>
Mon, 30 Mar 2015 14:44:41 +0000 (16:44 +0200)
committerJosé Bollo <jose.bollo@open.eurogiciel.org>
Mon, 30 Mar 2015 14:44:41 +0000 (16:44 +0200)
This will now allow users that don't has right to
write the label but that has the right to read it
to be able to run the script when the label of the
group is already set to the expected value.

May solve the bug TT-51.

Change-Id: I867e787f7dc0dfea6c8838be71c3cb41d0505cf8
Signed-off-by: José Bollo <jose.bollo@open.eurogiciel.org>
src/vconf-buxton-tool.sh

index b864842..de96da6 100755 (executable)
@@ -160,7 +160,12 @@ buxton_ensure_group() {
   else
     buxton_make_group "$layer" "$group" || return
   fi
-  [[ -z "$label" ]] || buxton_set_label "$layer" "$group" "$label"
+  if [[ -n "$label" ]] && [[ "$label" != "$(buxton_get_label "$layer" "$group")" ]]
+  then
+    buxton_set_label "$layer" "$group" "$label"
+  else
+    info "group $group in layer $layer already has label $label"
+  fi
 }
 
 buxton_ensure_ready() {