5 <section id="example"><title>Examples</title>
6 <section id="exset"><title>Setting Keys</title>
7 <para><prompt>bash$ </prompt><command>kdb set -c "My first key" user/example/key "Some nice value"</command></para>
8 <para><prompt>bash$ </prompt><command>kdb set user:luciana/example/key -- "Some - nice - value with dashes"</command></para>
9 <para><prompt>bash# </prompt><command>KDB_ROOT=user:http/sw/httpd kdb set -u nobody -g http key "Some value"</command></para>
10 <para><prompt>bash$ </prompt><command>kdb set -b image.png -t bin user/example/binaryKey</command></para>
11 <para><prompt>bash$ </prompt><command>kdb set -b file.txt user/example/regularKey</command></para>
12 <para><prompt>bash# </prompt><command>kdb set -t link system/sw/XFree/current system/sw/XFree/handmade</command></para>
14 <section id="exget"><title>Getting Keys</title>
15 <para><prompt>bash$ </prompt><command>KDB_ROOT=user/example kdb get some/key/name</command></para>
16 <para><prompt>bash$ </prompt><command>eval `kdb get -s user/env/env1/PS1`</command></para>
17 <para><prompt>bash$ </prompt><command>KDB_BACKEND=gconf kdb get user/sw/gnome-terminal/global/active_encodings</command></para>
19 <section id="exls"><title>Listing</title>
20 <para><prompt>bash$ </prompt><command>kdb ls -laR user:valeria</command></para>
21 <para><prompt>bash$ </prompt><command>kdb ls -lR system/sw/xorg/current</command></para>
22 <para><prompt>bash$ </prompt><command>KDB_ROOT=system/sw kdb ls -lR xorg</command></para>
23 <para><prompt>bash$ </prompt><command>KDB_BACKEND=fstab kdb ls -Rv system/filesystems</command></para>
24 <para><prompt>bash$ </prompt><command>eval `kdb ls -Rvs user/env/env2`</command></para>
26 <section id="exmisc"><title>Miscelaneous</title>
27 <para><prompt>bash# </prompt><command>kdb ln system/sw/xorg/handmade system/sw/xorg/current</command></para>
28 <para><prompt>bash# </prompt><command>kdb mv system/sw/xorg/current system/sw/xorg/old</command></para>
29 <para><prompt>bash# </prompt><command>kdb rm system/inittab/rc4</command></para>
30 <para><prompt>bash$ </prompt><command>KDB_BACKEND=gconf kdb rm user/gconfKey</command></para>
32 <section id="exxml"><title>XML Import and Export</title>
33 <para><prompt>bash# </prompt><command>kdb export user/sw/app | sed -e 's|/app/|/app2/|g' | kdb import</command></para>
34 <para><prompt>bash# </prompt><command>KDB_ROOT=system/sw kdb export myapp > myappconf.xml</command></para>
35 <para><prompt>bash# </prompt><command>kdb import myappconf.xml</command></para>
36 <para><prompt>bash$ </prompt><command>KDB_BACKEND=gconf kdb export user/sw</command></para>