Add a new vconfkey(VCONFKEY_MA_ASSISTANT_DEFAULT)
[platform/core/appfw/vconf-internal-keys.git] / insert_uid_gid.sh
1 #!/bin/bash
2 #--------------------------------------------------------------------
3 #
4 # HOW TO USE
5 #
6 # update a smack rule by putting an input txt file
7 # 0. sudo apt-get install xmlstarlet
8 # 1. edit smackinput.txt
9 # 2. run update_smacktest.sh smackinput.txt
10 #
11 # example)
12 # ./update_smacktest.sh smackinput.txt
13 #
14 # check the result with 'git diff'
15 #--------------------------------------------------------------------
16 filelist=`ls ./data/*.xml`
17
18 for file in $filelist
19 do
20  #xmlstarlet ed --insert --pf  "/vconfkeylists/vconfkey"  --type attr -n uid -v "" $file > $file.temp
21         xmlstarlet ed --insert "/vconfkeylists/vconfkey"  --type attr -n uid -v "" $file > $file.temp
22         #xmlstarlet ed --insert  "/vconfkeylists/vconfkey"  --type attr -n gid -v "6514" $file > $file.temp
23         mv $file.temp $file
24 done